@extends('layout.layout') @section('content') @include('components.alert')
Invoice Details
Back to List
Upedia
10062 Al Ahli Bank Building, Main Carrefour Street,
Zahraa Al Maadi, Cairo, Egypt
Invoice {{ $studentInvoice->invoice_number }}
Invoice Date: {{ $studentInvoice->created_at->format('Y-m-d') }}
Student Information

Name: {{ $studentInvoice->student->first_name ?? '' }} {{ $studentInvoice->student->last_name ?? '' }}

Email: {{ $studentInvoice->student->email ?? 'Not available' }}

@if ($studentInvoice->product) Product Details @else Course Details @endif
@if ($studentInvoice->product) @else @endif @if ($studentInvoice->product) @else @endif @if (!$studentInvoice->product) @endif
ProductLevelDateStart Date End Date @if ($studentInvoice->staff_scheduled?->staff) {{ $studentInvoice->staff_scheduled->staff->department->name ?? '' }} @else no teachers found @endif Price
{{ $studentInvoice->product?->name_en ?? ($studentInvoice->levels?->name_en ?? '') }} {{ $studentInvoice->staff_scheduled?->start_date ?? '' }} {{ $studentInvoice->staff_scheduled?->end_date ?? '' }} @if ($studentInvoice->staff_scheduled?->staff) {{ $studentInvoice->staff_scheduled->staff->first_name ?? '' }} {{ $studentInvoice->staff_scheduled->staff->last_name ?? '' }} @else @endif {{ number_format($studentInvoice->total_price, 2) }}
Transactions
@forelse ($studentInvoice->transaction as $index => $transaction) @empty @endforelse
# Transaction Date Payment Method Amount Transaction Img Reason Status
{{ $index + 1 }} {{ $transaction->created_at->format('Y-m-d H:i') }} {{ $transaction->payment_type }} {{ $transaction->amount }} @if ($transaction->transaction_img) Transaction Image @else No image @endif {{$transaction->reason ?? "--"}} @if ($transaction->status == 'paid') Paid @elseif ($transaction->status == 'pending') Pending @else Rejected @endif
No transactions found for this invoice
@if ($studentInvoice->discount_plan_id)
Pricing Plan Details
Discount Plan:
Total Price:
Discount:
Discount Amount:
{{ $studentInvoice->discount_plan->name_en ?? '' }}
{{ number_format($studentInvoice->total_price, 2) }}
@if ($studentInvoice->discount_plan_type == 'fixed')
{{ number_format($studentInvoice->discount_plan_price, 2) }}
{{ number_format($studentInvoice->total_price, 2) - number_format($studentInvoice->discount_plan_price, 2) }}
@elseif ($studentInvoice->discount_plan_type == 'percentage')
{{ number_format($studentInvoice->discount_plan_price, 0) }}%
{{ number_format($studentInvoice->total_price * $studentInvoice->discount_plan_price / 100, 2) }}
@else
0
@endif
@endif
@if ($studentInvoice->promocode_id)
Promocode Details
Promocode:
Total Price:
Discount:
Discount Amount:
{{ $studentInvoice->promocode->code ?? '' }}
@if ($studentInvoice->discount_plan_id)
{{ number_format($studentInvoice->total_price * $studentInvoice->discount_plan_price / 100, 2) }}
@else
{{ number_format($studentInvoice->total_price, 2) }}
@endif
@if ($studentInvoice->promocode_type == 'fixed') {{ number_format($studentInvoice->promocode_price, 2) }} @elseif ($studentInvoice->promocode_type == 'percentage') {{ number_format($studentInvoice->promocode_price, 0) }}% @else 0 @endif
{{ number_format($studentInvoice->net_price, 2) }}
@endif
Final Total: {{ number_format($studentInvoice->net_price, 2) }}
@endsection