@extends('layouts.app') @section('title', 'Service #' . $order->id) @section('content') {{-- ── Page Header ── --}}

Service #{{ $order->iperium_service_id ?? $order->id }}

Service details & payment information

{{ $order->service_type === 'community_fibre' ? 'Community Fibre' : 'NBN' }}
{{-- ── Service Details ── --}}

Service Details

@if($order->service_type === 'nbn') @endif @if($order->isSubscription() && $order->next_billing_date) @endif
Service Type {{ $order->service_type === 'community_fibre' ? 'Community Fibre' : 'NBN' }}
Status {{ ucfirst($order->status_label) }}
Customer Type{{ $order->customer_type }}
Current Provider{{ $order->current_provider ?? '—' }}
Full Name{{ $order->site_contact_name }}
Contact Number{{ $order->site_contact_number }}
Email{{ $order->site_contact_email }}
Date of Birth{{ $order->date_of_birth ? \Carbon\Carbon::parse($order->date_of_birth)->format('d/m/Y') : '—' }}
ABN{{ $order->abn ?? '—' }}
Registered Company Name{{ $order->registered_company_name ?? '—' }}
AVC ID{{ $order->avc_id ?? '—' }}
Existing NTD{{ $order->has_ntd === true ? 'Yes' : ($order->has_ntd === false ? 'No' : '—') }}
Address{{ $order->service_address_display ?: '—' }}
LOC{{ $order->loc ?? '—' }}
Service Activation{{ $order->asap ? 'ASAP' : ($order->service_activation_date ? \Carbon\Carbon::parse($order->service_activation_date)->format('d/m/Y') : '—') }}
NTD ID{{ $order->ntd_id ?? '—' }}
Port{{ $order->port ?? '—' }}
Copper Pair ID{{ $order->copper_pair_id ?? '—' }}
Product{{ $order->product_display_name }}
Product Price {{ $order->product_price !== null ? '$' . number_format($order->product_price, 2) : '—' }}{{ $order->isSubscription() ? ' / month' : '' }}
Router Add-on @if($order->router_status) Included @else Not Included @endif
Payment Type {{ $order->isSubscription() ? 'Monthly subscription' : 'One-time' }}
Next Billing Date{{ $order->next_billing_date->format('d/m/Y') }}
{{-- ── Manage Subscription ── --}} @if($order->isSubscription())

Subscription

Manage your billing cycle, update payment method, or view past invoices.

Manage subscription & invoices
@endif {{-- ── Router Add-on Details ── --}} @if($order->router_status)

Router Add-on

Router shipping fee and payment details for your service.

{{-- Router Add-on Payment History --}}

Router Payment History

@if(isset($paymentHistories) && $paymentHistories->where('order_id', $order->id)->where('type', 'router_charge')->count() > 0)
@foreach($paymentHistories->where('order_id', $order->id)->where('type', 'router_charge') as $routerPayment) @endforeach
Date Amount Status Link
{{ $routerPayment->created_at->format('d/m/Y') }} @if($routerPayment->amount < 1000) {{-- If amount is less than 1000, it's likely stored in dollars, convert to cents --}} ${{ number_format($routerPayment->amount, 2) }} {{ strtoupper($routerPayment->currency) }} @else {{-- Normal cents to dollars conversion --}} {{ $routerPayment->formatted_amount }} {{ strtoupper($routerPayment->currency) }} @endif {{ ucfirst($routerPayment->status) }} @if($routerPayment->invoice_hosted_url) View Invoice @endif @if($routerPayment->invoice_pdf_url || $routerPayment->stripe_invoice_id) Download PDF @endif
@else
No router payment history found
@endif
@endif {{-- ── Stripe Payment Details ── --}} @if($order->stripe_payment_intent_id || $order->stripe_charge_id || $order->stripe_amount !== null)

Stripe Payment Details

@if($order->stripe_amount !== null) @endif @if($order->stripe_currency) @endif @if($order->stripe_status) @endif
Product{{ $order->product_display_name }}
Amount {{ number_format($order->stripe_amount / 100, 2) }} {{ strtoupper($order->stripe_currency ?? 'aud') }}
Currency{{ strtoupper($order->stripe_currency) }}
Payment Status {{ ucfirst(str_replace('_', ' ', $order->stripe_status)) }}
@endif {{-- ── NBN Service Details ── --}} @if($order->nbn_service_profile || $order->ipv4_allocation)

Service Details (NBN)

NBN Service Profile{{ $order->nbn_service_profile ?? '—' }}
IPv4 Allocation{{ $order->ipv4_allocation ?? '—' }}
@endif {{-- ── PPPoE Details ── --}} @if($order->pppoe_username || $order->pppoe_password) @endif {{-- ── Notes & Activity log (public notes only — same layout as admin Activity) ── --}} @if($order->publicServiceNotes && $order->publicServiceNotes->isNotEmpty())

Notes & Activity log

Activity

@foreach($order->publicServiceNotes as $pnote) @php $mod = $pnote->source === \App\Models\OrderServiceNote::SOURCE_STATUS_CHANGE ? 'status' : ($pnote->source === \App\Models\OrderServiceNote::SOURCE_IPERIUM_SYNC ? 'sync' : 'manual'); $authorLabel = $pnote->source === \App\Models\OrderServiceNote::SOURCE_IPERIUM_SYNC ? 'Iperium sync' : ($pnote->source === \App\Models\OrderServiceNote::SOURCE_STATUS_CHANGE ? 'Status update' : ($pnote->author?->name ?? 'Support')); @endphp
{{ $pnote->created_at->format('d-m-Y | h:i:s A') }} Public @if($pnote->is_high_priority)High priority@endif
{{ $authorLabel }}
{!! nl2br(e($pnote->body)) !!}
@endforeach
@endif {{-- ── Back Button ── --}}
Back to My Services
{{-- Router Payment Details Modal --}} @endsection @push('styles') @endpush @push('scripts') @endpush