@extends('layouts.adminapp') @section('content') @section('head',__('lng.Trip')) {{-- Account Group --}}
{{--

{{$Trips->title}}

--}} Back
@php $DTs=0; if($Trips->from) { $DTs = date("d-m-Y",strtotime($Trips->from)); } @endphp

{{$DTs}}

@php $DTs=0; if($Trips->to) { $DTs = date("d-m-Y",strtotime($Trips->to)); } @endphp

{{$DTs}}

{{$Trips->source}}

{{$Trips->destination}}

{{$Trips->accountledger->title}}

{{$Trips->vehicle->title}}

{{$Trips->employee->name}}

{{$Trips->status}}

{{$Trips->trip_estimate !== null ? number_format($Trips->trip_estimate, 2) : ''}}

{{$Trips->advance !== null ? number_format($Trips->advance, 2) : ''}}

@php $average = ($amount* $Trips->vehicle->driver_commission)/100; @endphp

{{ $Trips->driver_amount > 0 ? number_format($Trips->driver_amount, 2) : $average }}

{{--
@php $average = ($Trips->trip_estimate * $Trips->vehicle->driver_commission)/100; @endphp

{{ $average }}

--}}
{{__('lng.TripExpenceTable')}}
{{-- --}} {{__('lng.CreateNew')}}
@php $si=0; $totalAmount = 0;@endphp @foreach($TripExpenses as $TripExpense) @php $totalAmount += $TripExpense->amount; // Add the amount to total @endphp @endforeach
{{__('lng.SiNo')}} {{__('lng.Title')}} {{__('lng.Amount')}} {{__('lng.Narration')}} {{__('lng.Action')}}
{{++$si}} {{$TripExpense->name}} @currency($TripExpense->amount) {{$TripExpense->narration}}
@csrf @method('delete')
Total {{$totalAmount}}
{{-- DRIVER SALARY PAYABLE MODAL --}} {{-- TRIP SETLMENT MODAL --}}
@endsection