@extends('admin.layouts.main') @section('title', 'Hosting: ' . $hostingAccount->domain) @section('menu', 'Hosting') @section('content')
Account Details
@if($hostingAccount->server && $hostingAccount->username && !in_array($hostingAccount->status, ['terminated', 'cancelled']))
@csrf
Login to Panel @endif Edit
@php $badgeClass = match($hostingAccount->status) { 'active' => 'success', 'pending' => 'warning', 'suspended' => 'danger', 'terminated' => 'dark', 'cancelled' => 'secondary', default => 'secondary', }; @endphp
Domain{{ $hostingAccount->domain }}
Client@if($hostingAccount->user){{ $hostingAccount->user->first_name }} {{ $hostingAccount->user->last_name }}@else N/A @endif
Product{{ $hostingAccount->product?->name ?? 'N/A' }}
Server{{ $hostingAccount->server?->name ?? 'N/A' }}
Package{{ $hostingAccount->package_name ?? 'N/A' }}
Username{{ $hostingAccount->username ?? 'N/A' }}
Dedicated IP{{ $hostingAccount->dedicated_ip ?? 'N/A' }}
Status{{ ucfirst($hostingAccount->status) }}
Server Status{{ $hostingAccount->server_status ?? 'N/A' }}
Last Synced{{ $hostingAccount->last_synced_at?->format('M d, Y H:i') ?? 'Never' }}
@if($hostingAccount->suspension_reason)
Suspension Reason: {{ $hostingAccount->suspension_reason }}
@endif
Billing & Dates
Billing Cycle{{ $hostingAccount->billingCycle?->name ?? 'N/A' }}
Registration Price{{ $hostingAccount->registration_price ? number_format($hostingAccount->registration_price, 2) : 'N/A' }}
Renewal Price{{ $hostingAccount->renewal_price ? number_format($hostingAccount->renewal_price, 2) : 'N/A' }}
Registration Date{{ $hostingAccount->registration_date?->format('M d, Y') ?? 'N/A' }}
Next Due Date{{ $hostingAccount->next_due_date?->format('M d, Y') ?? 'N/A' }}
@if($hostingAccount->cancel_requested)
Cancellation Request
Cancel Type{{ ucfirst(str_replace('_', ' ', $hostingAccount->cancel_type ?? 'N/A')) }}
Requested At{{ $hostingAccount->cancel_request_date?->format('M d, Y H:i') ?? 'N/A' }}
@endif @if($hostingAccount->server && $hostingAccount->username)
Server Actions
@if(in_array($hostingAccount->status, ['terminated', 'cancelled']))
This account has been {{ $hostingAccount->status }}. You can recreate it on the server.
@csrf
@else
@csrf
@csrf
@csrf
@if($hostingAccount->status === 'active')
@csrf
@elseif($hostingAccount->status === 'suspended')
@csrf
@endif @if(in_array($hostingAccount->status, ['active', 'suspended']))
@csrf
@endif
@endif
@else
No server linked. Server actions are unavailable. Set a server via Edit.
@endif
@endsection