TenantAtlas/apps/platform/app/Support/WorkspaceIsolation/TenantOwnedTables.php
ahmido c44f683aa6 277-stored-reports-surface → platform-dev (#333)
Auto-created PR: committing all local changes and pushing branch `277-stored-reports-surface` to remote.

Please review and adjust the title/description as needed.

Co-authored-by: Ahmed Darrazi <ahmed.darrazi@live.de>
Reviewed-on: #333
2026-05-06 00:04:53 +00:00

58 lines
1.2 KiB
PHP

<?php
declare(strict_types=1);
namespace App\Support\WorkspaceIsolation;
class TenantOwnedTables
{
/**
* @return array<int, string>
*/
public static function all(): array
{
return [...self::firstSlice(), ...self::residual()];
}
public static function contains(string $table): bool
{
return in_array($table, self::all(), true);
}
/**
* @return array<int, string>
*/
public static function firstSlice(): array
{
return [
'policies',
'policy_versions',
'backup_schedules',
'backup_sets',
'restore_runs',
'findings',
'finding_exceptions',
'evidence_snapshots',
'inventory_items',
'entra_groups',
'stored_reports',
'tenant_reviews',
];
}
/**
* @return array<int, string>
*/
public static function residual(): array
{
return [
'backup_items',
'inventory_links',
'entra_role_definitions',
'tenant_permissions',
'finding_exception_decisions',
'finding_exception_evidence_references',
];
}
}