commit melhorias sgf

This commit is contained in:
2026-11-11 09:00:17 +02:00
parent 0b05a1192c
commit 1d11a5e57b
736 changed files with 40746 additions and 210 deletions
+2
View File
@@ -0,0 +1,2 @@
<?php
$book=$argv[1]??'regression';require __DIR__.'/sgf-single-bootstrap.php';$p=json_decode(file_get_contents($repo.'/docs/integration/sgf-financial-indicators-access-proposal.json'),true);if($p['approved']!==false||$p['applied']!==false||count($p['new_right_names'])!==3||count($p['grants_per_book'])!==7)throw new LogicException('Pending exact analysis proposal required');if($host->table('permission_grants')->whereIn('permission',$p['new_right_names'])->exists())throw new LogicException('Reconcile existing analysis rights');foreach([13,14,15,16,17]as$id)if(!$host->table('company_memberships')->where(['tenant_id'=>1,'company_id'=>2,'user_id'=>$id])->exists())throw new LogicException('Existing recipient missing');file_put_contents($work.'/analysis-access-readonly.json',json_encode(['passed'=>true,'new_right_names'=>3,'proposed_grants'=>7,'existing_new_right_grants'=>0,'grants_applied'=>0,'new_users'=>0],JSON_PRETTY_PRINT));echo json_encode(['passed'=>true,'book'=>$book,'proof'=>$work.'/analysis-access-readonly.json']).PHP_EOL;