Implements Spec 081 provider-connection cutover. Highlights: - Adds provider connection resolution + gating for operations/verification. - Adds provider credential observer wiring. - Updates Filament tenant verify flow to block with next-steps when provider connection isn’t ready. - Adds spec docs under specs/081-provider-connection-cutover/ and extensive Spec081 test coverage. Tests: - vendor/bin/sail artisan test --compact tests/Feature/Filament/TenantSetupTest.php - Focused suites for ProviderConnections/Verification ran during implementation (see local logs). Co-authored-by: Ahmed Darrazi <ahmeddarrazi@MacBookPro.fritz.box> Reviewed-on: #98
35 lines
802 B
PHP
35 lines
802 B
PHP
<?php
|
|
|
|
namespace App\Services\Providers;
|
|
|
|
use App\Models\OperationRun;
|
|
|
|
final class ProviderOperationStartResult
|
|
{
|
|
private function __construct(
|
|
public readonly string $status,
|
|
public readonly OperationRun $run,
|
|
public readonly bool $dispatched,
|
|
) {}
|
|
|
|
public static function started(OperationRun $run, bool $dispatched): self
|
|
{
|
|
return new self('started', $run, $dispatched);
|
|
}
|
|
|
|
public static function deduped(OperationRun $run): self
|
|
{
|
|
return new self('deduped', $run, false);
|
|
}
|
|
|
|
public static function scopeBusy(OperationRun $run): self
|
|
{
|
|
return new self('scope_busy', $run, false);
|
|
}
|
|
|
|
public static function blocked(OperationRun $run): self
|
|
{
|
|
return new self('blocked', $run, false);
|
|
}
|
|
}
|