TenantAtlas/app/Services/Inventory/CoverageCapabilitiesResolver.php
ahmido 9c56a2349a feat/047-inventory-foundations-nodes (#51)
Adds Inventory Sync toggle include_foundations (default true) + persistence tests
Adds Coverage “Dependencies” column (/—) derived deterministically from graph_contracts (no Graph calls)
Spec/tasks/checklists updated + tasks ticked off

Co-authored-by: Ahmed Darrazi <ahmeddarrazi@adsmac.local>
Reviewed-on: #51
2026-01-10 20:47:29 +00:00

26 lines
565 B
PHP

<?php
namespace App\Services\Inventory;
class CoverageCapabilitiesResolver
{
public function supportsDependencies(string $type): bool
{
$contracts = config('graph_contracts.types', []);
if (! is_array($contracts)) {
return false;
}
$meta = $contracts[$type] ?? null;
if (! is_array($meta)) {
return false;
}
if (array_key_exists('assignments_list_path', $meta)) {
return true;
}
return ($meta['supports_scope_tags'] ?? false) === true;
}
}