<div class="modal-header">
    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
        <span aria-hidden="true">&times;</span></button>
    <div class="container-fluid banner">
    </div>

    <h4 class="modal-title">ٹرپ #
        <span class="badge" id="receivedAcTripNo">{{ $trip->id }}</span>
        گاڑی:
        <span class="badge badge-color2" id="receivedAcVeh">{{ $trip->vehicle->vehicle_no }}</span>
        تاریخ:
        <span class="badge badge-color3"
              id="receivedAcDates">{{ date('F j,Y', strtotime($trip->starting_date)) }}</span>
        میں ایڈجسمنٹس
    </h4>
</div>
<div class="modal-body">

    <div class="row mt-3">
        <div class="col-md-12">
            <h3 class="text-center"> ٹرپ # {{ $trip->id }} میں ایڈجسمنٹس</h3>
        </div>
        <div class="col-md-12">
            <hr>
            <table class="table table-bordered" id="received-details-table">
                <thead>
                <tr class="bg-info text-center">
                    <th>#</th>
                    <th>پیمنٹ قسم</th>
                    <th>تاریخ</th>
                    <th>رقم</th>
                    <th>نوٹ</th>
                </tr>

                </thead>
                <tbody>
                @forelse ($adjustments as $adjustment)
                    <tr class=" text-center">
                        <td>{{ $loop->iteration }}</td>
                        <td>
                            @if($adjustment->payment_type == 'on_account')
                                ON ACCOUNT ({{ $adjustment->broker->name }})
                            @elseif($adjustment->payment_type == 'bank')
                                BANK ( {{$adjustment->bank->name}} )
                            @else
                                CASH
                            @endif
                        </td>
                        <td>{{ date('F j, Y', strtotime($adjustment->date)) }}</td>
                        <td>{{ number_format($adjustment->amount, 0) }}</td>
                        <td>{{ $adjustment->description }}</td>
                    </tr>
                @empty
                    <tr class="text-center">
                        <td colspan="6">No Data Available</td>
                    </tr>
                @endforelse
                </tbody>
            </table>
        </div>
    </div>
</div>
