@extends('layouts.admin.app') @section('title', translate('Trip Details')) @section($trip->trip_status) active @endsection @push('css_or_js') @endpush @section('content')

{{translate('Trip ID')}} # {{ $trip->id }} @if ($trip->edited) {{ translate('messages.edited') }} @endif

{{ translate('Placed on') }} {{ \App\CentralLogics\Helpers::time_date_format($trip?->created_at) }} @if ($trip->scheduled)
{{ translate('Schedule At') }} {{ \App\CentralLogics\Helpers::time_date_format($trip?->schedule_at) }} @endif
{{translate('Provider')}} : {{ $trip?->provider?->name }}
{{translate('Trip Type')}} : {{ translate($trip->trip_type) }} ({{ $trip->scheduled ? translate('messages.scheduled') : translate('messages.Instant') }})
@if ($trip->trip_type == 'hourly') {{translate('Total ')}} {{ translate('Hour')}} : {{ $trip->estimated_hours }} {{ translate('hrs') }} @else {{translate('Total ')}} {{ translate('KM') }} : {{ $trip->distance }} {{ translate('KM') }} @endif
@if($trip->trip_status == 'pending' && $is_deleted != 1) @endif $trip->id])}}"> {{translate('Print invoice')}}
@php $statusClasses = [ 'pending' => 'badge--pending-1', 'completed' => 'badge--accepted', 'canceled' => 'badge--cancel', 'ongoing' => 'badge--pending', 'payment_failed' => 'badge--cancel', ]; $badgeClass = $statusClasses[$trip->trip_status] ?? 'badge--accepted'; @endphp {{translate('Trip Status')}} : {{ translate($trip->trip_status) }}
{{translate('Payment status')}} : {{ translate($trip->payment_status) }}
@if ($trip->payment_method)
{{translate('Payment method')}} : {{ translate($trip->payment_method ?? 'cash payment') }}
@endif
@if(!empty($trip->trip_note))
{{translate('Note')}}: {{ $trip->trip_note }}
@endif
@php $subtotal = 0; @endphp @foreach($trip?->trip_details as $detail) @php $subtotal += $detail->calculated_price; @endphp @endforeach

{{translate('Trip Fare')}}
{{ \App\CentralLogics\Helpers::format_currency($subtotal) }}
{{ translate('Subtotal') }} @if ($trip->tax_status == 'included') ({{ translate('messages.TAX_Included') }}) @endif
{{ \App\CentralLogics\Helpers::format_currency($subtotal) }}
{{translate('discount')}}
-{{ \App\CentralLogics\Helpers::format_currency($trip->discount_on_trip)}}
{{translate('Coupon discount')}}
-{{ \App\CentralLogics\Helpers::format_currency($trip->coupon_discount_amount)}}
@if ($trip->ref_bonus_amount > 0)
{{translate('Referral_Discount')}}
-{{ \App\CentralLogics\Helpers::format_currency($trip->ref_bonus_amount)}}
@endif @if ($trip->tax_status == 'excluded')
{{translate('Vat/tax')}}
+{{ \App\CentralLogics\Helpers::format_currency($trip->tax_amount)}}
@endif
{{ \App\CentralLogics\Helpers::get_business_data('additional_charge_name')??\App\CentralLogics\Helpers::get_business_data('additional_charge_name')??translate('messages.additional_charge') }}
+ {{ \App\CentralLogics\Helpers::format_currency($trip->additional_charge) }}
{{translate('Total')}}
{{ \App\CentralLogics\Helpers::format_currency($trip->trip_amount)}}
@php $tripDrivers = $trip?->vehicle_identity->whereNotNull('vehicle_driver_id'); $tripVehicles = $trip?->vehicle_identity->whereNotNull('vehicle_identity_id')->count(); $driverCount = $tripDrivers->count() @endphp
@if($trip->trip_status != 'completed' || $trip->payment_status != 'paid' )
{{ translate('trip_setup') }}
@if($trip->trip_status != 'completed')
@endif
@if($driverCount <= 0 && $tripVehicles > 0) @endif
@endif @if($driverCount > 0)
{{translate('Driver List')}}
@if(!in_array($trip->trip_status, ['pending', 'completed', 'canceled'])) @endif
@foreach($tripDrivers as $driverDetails) @endforeach
@endif

  • {{ translate('Home') }}: {{ $trip->pickup_location['location_name'] }}
  • {{ $trip->destination_location['location_name'] }}
{{ translate('messages.Customer_Info') }}
@if ($trip->is_guest == 1) {{ translate('Guest_user') }} @endif
@if ($trip->customer)
Image Description
{{ $trip->customer->fullName }}
{{ $trip?->customer?->trips?->count() }} {{ translate('messages.trip') }}
{{ $trip?->customer?->phone }}
{{ $trip?->customer?->email }}
@elseif($trip?->user_info['contact_person_name'])
Image Description
{{ $trip?->user_info['contact_person_name'] }}
{{ $trip?->user_info['contact_person_number'] }}
{{ $trip?->user_info['contact_person_email'] }}
@else
{{ translate('messages.Guest_user') }}
@endif
@endsection @push('script_2') @endpush