TenantAtlas/apps/platform/app/Models/TenantConfigurationSupportedScope.php
Ahmed Darrazi 611b19910e
Some checks failed
PR Fast Feedback / fast-feedback (pull_request) Failing after 4m27s
feat: migrate tcm first coverage core cutover
2026-06-25 14:54:31 +02:00

43 lines
1011 B
PHP

<?php
declare(strict_types=1);
namespace App\Models;
use App\Support\TenantConfiguration\CoverageLevel;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class TenantConfigurationSupportedScope extends Model
{
use HasFactory;
protected $guarded = [];
/**
* @return array<string, string>
*/
protected function casts(): array
{
return [
'minimum_coverage_level' => CoverageLevel::class,
'included_resource_types' => 'array',
'allow_beta' => 'boolean',
'allow_graph_fallback' => 'boolean',
'customer_claims_allowed' => 'boolean',
'is_active' => 'boolean',
'metadata' => 'array',
];
}
/**
* @param Builder<self> $query
* @return Builder<self>
*/
public function scopeActive(Builder $query): Builder
{
return $query->where('is_active', true);
}
}