TenantAtlas/apps/platform/app/Support/Tenants/TenantActionContext.php
Ahmed Darrazi 5443dba269
Some checks failed
PR Fast Feedback / fast-feedback (pull_request) Failing after 7m2s
refactor: consolidate internal tenant model naming
2026-05-14 13:09:36 +02:00

36 lines
964 B
PHP

<?php
declare(strict_types=1);
namespace App\Support\Tenants;
use App\Models\ManagedEnvironment;
use App\Models\ManagedEnvironmentOnboardingSession;
use App\Models\User;
final readonly class TenantActionContext
{
public function __construct(
public ManagedEnvironment $tenant,
public TenantLifecycle $lifecycle,
public TenantActionSurface $surface,
public ?User $actor,
public ?int $workspaceId,
public TenantInteractionLane $lane,
public ?ManagedEnvironmentOnboardingSession $relatedOnboardingDraft,
public bool $relatedOnboardingIsResumable,
public bool $hasRelatedOnboardingDraft,
public bool $isArchived,
) {}
public function isOnboardingSurface(): bool
{
return $this->surface->isOnboardingSurface();
}
public function isGenericTenantManagementSurface(): bool
{
return $this->surface->isGenericTenantManagementSurface();
}
}