Hosting Account Details @php $statusColors = [ 'active' => 'bg-emerald-50 text-emerald-700', 'suspended' => 'bg-red-50 text-red-700', 'pending' => 'bg-amber-50 text-amber-700', 'provisioning' => 'bg-blue-50 text-blue-700', 'failed' => 'bg-red-50 text-red-700', ]; $statusLabels = [ 'active' => 'Active', 'suspended' => 'Suspended', 'pending' => 'Pending Setup', 'provisioning' => 'Setting Up...', 'failed' => 'Setup Failed', ]; $formErrors = $errors ?? new \Illuminate\Support\ViewErrorBag; $addDomainAction = \Illuminate\Support\Facades\Route::has('hosting.panel.domains.add') ? route('hosting.panel.domains.add', $account) : '#'; $panelIndexUrl = \Illuminate\Support\Facades\Route::has('hosting.panel.index') ? route('hosting.panel.index', $account) : '#'; $panelSettingsUrl = \Illuminate\Support\Facades\Route::has('hosting.panel.settings') ? route('hosting.panel.settings', $account) : '#'; $resourceStatusColors = [ 'active' => 'bg-emerald-50 text-emerald-700', 'throttled' => 'bg-amber-50 text-amber-700', 'suspended' => 'bg-red-50 text-red-700', ]; @endphp @php $ownedDomainHosts = collect($ownedDomains)->map(fn ($d) => (string) $d)->all(); $oldDomain = trim((string) old('domain', '')); $initialDomainSource = empty($ownedDomainHosts) ? 'external' : ((string) old('is_owned_domain', '1') === '0' ? 'external' : 'ladill'); $selectedOwned = in_array($oldDomain, $ownedDomainHosts, true) ? $oldDomain : ''; $externalFallback = ! in_array($oldDomain, $ownedDomainHosts, true) ? $oldDomain : ''; @endphp
{{-- Breadcrumb --}} {{-- Expired Account Banner --}} @if ($account->isExpired() && $account->isInGracePeriod())

Hosting Account Expired

Your hosting expired on {{ $account->expires_at->format('M d, Y') }}. Your site is offline but your files are safe. Renew before {{ $account->gracePeriodEndsAt()->format('M d, Y') }} to avoid automatic deletion.

@endif {{-- Pending Setup Banner --}} @if ($account->status === 'pending')

Setting Up Your Hosting

Your hosting account is being set up on our servers. This usually takes 1-2 minutes. Please refresh this page shortly to check the status.

@endif {{-- Provisioning Banner --}} @if ($account->status === 'provisioning')

Provisioning In Progress

We're creating your hosting environment, setting up PHP, and configuring your server. This typically takes 1-3 minutes. Please refresh this page to check progress.

@endif {{-- Failed Setup Banner --}} @if ($account->status === 'failed')

Setup Failed

There was a problem setting up your hosting account. Our team has been notified and will resolve this shortly. If you need immediate assistance, please open a support ticket.

@endif {{-- Hero Card --}}

Hosting Account

{{ $accountLabel ?? ($account->primary_domain ?: $account->username) }} {{ $statusLabels[$account->status ?? 'Pending'] }} {{ ucfirst($account->resource_status ?? 'active') }} resources

Created {{ $account->created_at->format('M d, Y') }} @if ($account->expires_at) · Expires {{ $account->expires_at->format('M d, Y') }} @endif

@if ($account->assignedDurationMonths() && !empty($renewalOptions) && ($account->isExpired() || $account->expires_at?->isBefore(now()->addDays(30)))) @endif @if ($canLinkMoreDomains) @endif
@if (!empty($upsellRecommendations))

Recommended Next Steps

These suggestions are based on how this account is being used right now.

{{ count($upsellRecommendations) }} suggestion{{ count($upsellRecommendations) === 1 ? '' : 's' }}
@foreach ($upsellRecommendations as $recommendation)

{{ $recommendation['title'] }}

{{ $recommendation['message'] }}

{{ $recommendation['type'] === 'plan_upgrade' ? 'Upgrade' : 'Add-on' }}
@if (($recommendation['type'] ?? null) === 'plan_upgrade' && !empty($recommendation['target_product_id']))
@csrf
@elseif (!empty($recommendation['cta_url'])) @endif
@endforeach
@endif {{-- Info Cards Grid --}}
{{-- Account Details Card --}}

Account Details

Username {{ $account->username }}
Node IP {{ $account->node?->ip_address ?? '161.97.138.149' }}
@if ($account->product)
Product {{ $account->product->name }}
@endif
Email Usage {{ $emailUsage['mailbox_count'] }} @if ($emailUsage['free_allowance'] === null) / Unlimited included @else / {{ $emailUsage['free_allowance'] }} included @endif
@if ($emailUsage['extra_count'] > 0)
Extra Emails: {{ $emailUsage['extra_count'] }} x GHS 5 = GHS {{ number_format($emailUsage['extra_total'], 2) }}
@endif
{{-- Resources Card --}}

Resources

@php $diskLimit = max(($account->allocated_disk_gb ?: ($account->product?->disk_gb ?? 10)), 1) * 1073741824; $bandwidthLimit = $account->resource_limits['bandwidth_limit_bytes'] ?? 107374182400; // 100GB default $diskUsed = $account->disk_used_bytes ?? 0; $bandwidthUsed = $account->bandwidth_used_bytes ?? 0; $diskPercent = $diskLimit > 0 ? ($diskUsed / $diskLimit) * 100 : 0; $bandwidthPercent = $bandwidthLimit > 0 ? ($bandwidthUsed / $bandwidthLimit) * 100 : 0; @endphp
Disk Space {{ number_format($diskUsed / 1073741824, 1) }} GB / {{ number_format($diskLimit / 1073741824, 1) }} GB
Bandwidth {{ number_format($bandwidthUsed / 1073741824, 1) }} GB / {{ number_format($bandwidthLimit / 1073741824, 1) }} GB
@if ($account->php_version)
PHP Version {{ $account->php_version }}
@endif
CPU {{ number_format((float) ($account->cpu_usage_percent ?? 0), 1) }}% / {{ $account->cpu_limit_percent ?? '-' }}%
Memory {{ $account->memory_used_mb ?? 0 }} MB / {{ $account->memory_limit_mb ?? '-' }} MB
Processes {{ $account->process_count ?? 0 }} / {{ $account->process_limit ?? '-' }}
Inodes {{ number_format((int) ($account->inode_count ?? 0)) }} / {{ number_format((int) ($account->inode_limit ?? 0)) }}
{{-- Features Card --}}

Features

@php $features = $account->features_enabled ?? []; $defaultFeatures = ['SFTP Access', 'FTP Access', 'Email Accounts', 'MySQL Database']; $displayFeatures = !empty($features) ? $features : $defaultFeatures; @endphp @foreach ($displayFeatures as $feature)
{{ $feature }}
@endforeach
{{-- Health Card --}}

Health

Status {{ ucfirst($account->status ?? 'Unknown') }}
@if ($account->provisioned_at)
Provisioned {{ $account->provisioned_at->format('M d, Y') }}
@endif @if ($account->suspended_at)
Suspended {{ $account->suspended_at->format('M d, Y') }}
@endif @if (!empty($account->suspension_reason))
{{ $account->suspension_reason }}
@endif @if ($account->uploads_restricted)
Uploads are temporarily restricted because the inode limit has been reached.
@endif
{{-- Domain Card --}}

Domains

@if ($canLinkMoreDomains) @endif
@if ($linkedSites->isNotEmpty())
@foreach ($linkedSites as $site)
{{ $site->domain }} @if ($site->type === 'primary') Primary @endif @if ($site->ssl_enabled) SSL @endif

{{ $site->document_root }}

{{ ucfirst($site->status) }}
@endforeach

@if ($maxDomains === -1) {{ $account->domainSitesCount() }} domain {{ $account->domainSitesCount() === 1 ? 'slot' : 'slots' }} in use (unlimited). @else {{ $account->domainSitesCount() }} of {{ $maxDomains }} domain {{ $maxDomains === 1 ? 'slot' : 'slots' }} in use. @endif · {{ $account->subdomainSitesCount() }}{{ $account->maxSubdomainsLimit() === -1 ? '' : ' of '.$account->maxSubdomainsLimit() }} subdomain {{ $account->subdomainSitesCount() === 1 ? 'slot' : 'slots' }} in use.

@elseif ($account->primary_domain && ! \App\Services\Hosting\PlaceholderPrimaryDomainService::isPlaceholderDomain($account->primary_domain))
{{ $account->primary_domain }} Active

Primary domain for this hosting account.

@else

No domain linked

Link a domain to use your hosting account.

@if ($canLinkMoreDomains) @endif
@endif
{{-- Domain Linking Modal --}} {{-- Renewal Duration Modal --}} @if (!empty($renewalOptions)) @endif @include('partials.paystack-sheet') {{-- Control Panel Modal --}}