@include('includes.app') @include('includes.sidebar') @include('includes.header') @include('includes.toster')
@include('includes.under-loadR-sidebar')
{{-- @include('CRM.crminclude.state-city') --}} {{--
--}}

@can('loadboard_view') @endcan @can('loadboard_view') @endcan
@canexport('print') @endcanexport @canexport('pdf') @endcanexport @canexport('excel') @endcanexport
{{ request()->post_shipment != 'preset' ? 'Load Board List' : 'Post Shipments' }}
@can('loadboard_action') @endcan
@foreach($quotations as $quotation) @php $deliveriesCount = 0; $pickupsCount = 0; @endphp @php $pickupCount = $quotation->rows->flatMap->pickups->count(); @endphp @php $deliveryCount = $quotation->rows->flatMap->deliveries->count(); @endphp @endforeach
Request ID Action Company Name Pickup Location Pickup Date & Time Pickup PO Delivery Location Delivery Date & Time Delivery PO Customer Phone State City Status Bid Limit
#{{ $quotation->quotation_id ?: $quotation->id }} {{ $quotation->customer ? $quotation->customer->company_name : 'N/A' }} @if ($pickupCount == 1) @php $pickup = $quotation->rows->flatMap->pickups->first(); $singlePickupAddress = ($pickup->cities ? $pickup->cities->name . ',' : "") . ($pickup->cities ? $pickup->cities->state_code : "") . ', ' . ($pickup?->countryyyy?->name ?? ''); @endphp {{ $singlePickupAddress }} @elseif ($pickupCount > 1) View Details @else - @endif @if ($pickupCount) @php $pickup = $quotation->rows->flatMap->pickups->first(); $singlePickupTime = ($pickup->time ? \Carbon\Carbon::parse($pickup->time)->format('d M, Y h:iA') : "-"); @endphp {{ $singlePickupTime }} @endif @if ($pickupCount) @php $pickup = $quotation->rows->flatMap->pickups->first(); $singlePickupPo = ($pickup->po ?? "-"); @endphp {{ $singlePickupPo }} @endif @if ($deliveryCount == 1) @php $delivery = $quotation->rows->flatMap->deliveries->first(); $singleDeliveryAddress = ($delivery->cities ? $delivery->cities->name . ',' : "") . ($delivery->cities ? $delivery->cities->state_code : "") . ', ' . ($delivery?->countryyyy?->name ?? ''); @endphp {{ $singleDeliveryAddress }} @elseif ($deliveryCount > 1) View Details @else - @endif @if ($deliveryCount) @php $delivery = $quotation->rows->flatMap->deliveries->first(); $singleDeliveryTime = ($delivery->time ? \Carbon\Carbon::parse($delivery->time)->format('d M, Y h:iA') : "-"); @endphp {{ $singleDeliveryTime }} @endif @if ($deliveryCount) @php $delivery = $quotation->rows->flatMap->deliveries->first(); $singleDeliveryPo = ($delivery->po ?? "-"); @endphp {{ $singleDeliveryPo }} @endif {{ $quotation->customer ? $quotation->customer->phone : 'N/A' }} {{ $quotation->customer->stateDetail->name ?? 'N/A' }} {{ $quotation->customer->cityDetail->name ?? 'N/A' }} @if ($quotation->load_status == 'pending') {{ $quotation->load_status ?? 'Pending' }} @elseif($quotation->load_status == 'published') {{ $quotation->load_status ?? '' }} @endif {{ $quotation->bid_limit ? $quotation->bid_limit : 'N/A' }}
@foreach ($quotations as $quotation)
Load Request #{{ $quotation->id }}
General Information
Customer Type:
{{ $quotation->customer_type ?? 'N/A' }}
Company:
{{ $quotation->customer ? $quotation->customer->company_name : 'N/A' }}
Customer ID:
{{ $quotation->customer ? $quotation->customer->lead_unique_id : 'N/A' }}
Quote Type:
{{ strtolower($quotation->quote_type) == 'multi' ? 'Multi Truck' : ($quotation->quote_type ?? 'N/A') }}
@if(strtolower($quotation->quote_type) == 'multi')
Count of Trucks:
{{ $quotation->truck_count ?? 'N/A' }}
@endif
Employee ID:
{{ $quotation->employee_code ?? "N/A" }}
Mode of Transport:
{{ $quotation->modeofT ? $quotation->modeofT->name : 'N/A' }}
Requested By:
{{ $quotation->requested_by ?? 'N/A' }}
@foreach($quotation->rows as $index => $row)
Row {{ $index + 1 }}
Quantity of Trucks:
{{ $row->quantity ?? 'N/A' }}
Equipment Type:
{{ $row->equipmentRelation ? $row->equipmentRelation->name : 'N/A' }}
@foreach($row->pickups as $pickupIndex => $pickup)
Pickup Locations {{ $pickupIndex + 1 }}
Name:
{{ $pickup->name ?? 'N/A' }}
Email:
{{ $pickup->q_email ?? 'N/A' }}
Phone:
{{ $pickup->q_phone ?? 'N/A' }}
Street:
{{ $pickup->street ?? 'N/A' }}
Country:
{{ $pickup->countryyyy ? $pickup->countryyyy->name : 'N/A' }}
State:
{{ $pickup->states ? $pickup->states->name . ($pickup->cities ? '(' . $pickup->cities->state_code . ')' : '') : 'N/A' }}
City:
{{ $pickup->cities ? $pickup->cities->name : 'N/A' }}
Postal Code:
{{ $pickup->postal_code ?? 'N/A' }}
PO:
{{ $pickup->po ?? 'N/A' }}
Time:
{{ $pickup->time ?? 'N/A' }}
Quantity:
{{ $pickup->quantity ?? 'N/A' }}
Unit:
{{ $pickup->units ?? 'N/A' }}
Weight:
{{ $pickup->weight_value ?? 'N/A' }} {{ $pickup->weight ?? 'N/A' }}
Dimension:
{{ $pickup->dimension_value ?? 'N/A' }} {{ $pickup->dimension ?? 'N/A' }}
Pickup Note:
{{ $pickup->note ?? 'N/A' }}
@endforeach @foreach($row->deliveries as $deliveryIndex => $delivery)
Delivery Locations {{ $deliveryIndex + 1 }}
Name:
{{ $delivery->name ?? 'N/A' }}
Email:
{{ $delivery->q_email ?? 'N/A' }}
Phone:
{{ $delivery->q_phone ?? 'N/A' }}
Street:
{{ $delivery->street ?? 'N/A' }}
Country:
{{ $delivery->countryyyy ? $delivery->countryyyy->name : 'N/A' }}
State:
{{ $delivery->states ? $delivery->states->name . ($delivery->cities ? '(' . $delivery->cities->state_code . ')' : '') : 'N/A' }}
City:
{{ $delivery->cities ? $delivery->cities->name : 'N/A' }}
Postal Code:
{{ $delivery->postal_code ?? 'N/A' }}
PO:
{{ $delivery->po ?? 'N/A' }}
Time:
{{ $delivery->time ?? 'N/A' }}
Quantity:
{{ $delivery->quantity ?? 'N/A' }}
Unit:
{{ $delivery->units ?? 'N/A' }}
Weight:
{{ $delivery->weight_value ?? 'N/A' }} {{ $delivery->weight ?? 'N/A' }}
Dimension:
{{ $delivery->dimension_value ?? 'N/A' }} {{ $delivery->dimension ?? 'N/A' }}
Delivery Note:
{{ $delivery->note ?? 'N/A' }}
@endforeach @if($row->shipping)
Shipping Details
Commodity:
{{ $row->shipping->commodity ?? 'N/A' }}
Currency:
{{ $row->shipping->currency ?? 'N/A' }}
Base Price:
{{ $row->shipping->base_price ?? 'N/A' }}
{{-- @isset($row->shipping->shippingRows) @foreach ($row->shipping->shippingRows as $i => $shippingRow)
Shipping {{ $i + 1 }}
Quantity:
{{ $shippingRow->quantity ?? 'N/A' }}
Units:
{{ $shippingRow->units ?? 'N/A' }}
Weight:
{{ $shippingRow->weight_value ?? 'N/A' }} {{ $shippingRow->weight ?? '' }}
Dimension:
@if(!empty($shippingRow->dimension_value)) @php $dims = explode('*', $shippingRow->dimension_value); $labels = ['L', 'W', 'H']; // labels in order $formatted = []; foreach ($dims as $i => $val) { if (!empty($val) && isset($labels[$i])) { $formatted[] = $val . $labels[$i]; } } @endphp {{ implode(' * ', $formatted) }} @else N/A @endif {{ !empty($shippingRow->dimension) ? ' (' . $shippingRow->dimension . ')' : '' }}
@endforeach @endisset --}}
@endif @foreach($row->warehouses as $warehouseIndex => $warehouse)
Warehouse Details {{ $warehouseIndex + 1 }}
Location:
{{ $warehouse->location->name ?? 'N/A' }}
Price:
{{ $warehouse->amount ?? 'N/A' }}
@endforeach @if($row->additional)
Additional Details
Tarped:
{{ $row->additional->tarped ? 'Yes' : 'No' }}
Team:
{{ $row->additional->team ? 'Yes' : 'No' }}
Hazmat:
@if($row->additional && $row->additional->hazmat) Yes (Class: {{ $row->additional->class ?? 'N/A' }}) @else No @endif
Temperature:
@if($row->additional && $row->additional->temperature) Yes (Value: {{ $row->additional->temperature_value ?? 'N/A' }} {{ $row->additional->temperature_unit ?? '' }}) @else No @endif
Non Stackable:
{{ $row->additional->non_stackable ? 'Yes' : 'No' }}
Bonded:
{{ $row->additional->bonded ? 'Yes' : 'No' }}
Trailer Drop:
{{ $row->additional->trailer_drop ? 'Yes' : 'No' }}
Tailgate Delivery:
{{ $row->additional->tailgate ? 'Yes' : 'No' }}
Residential Delivery:
{{ $row->additional->residential ? 'Yes' : 'No' }}
@endif @endforeach @if($quotation->charges->count())
Charges
@foreach($quotation->charges as $charge)
{{ $charge->type ?? 'N/A' }}
{{ $charge->amount }} ({{ $charge->rate_type }})
@endforeach
@endif @if($quotation->discounts->count())
Discounts
@foreach($quotation->discounts as $discount)
{{ $discount->types ? $discount->types->name : 'N/A' }}
{{ $discount->types ? $discount->types->Amount : 'N/A' }} ({{ $discount->types ? $discount->types->percentage : 'N/A' }})
@endforeach
@endif
Tax & Final Details
GST:
{{ $quotation->gst ? $quotation->gst . '%' : 'N/A' }}
PST:
{{ $quotation->pst ? $quotation->pst . '%' : 'N/A' }}
HST:
{{ $quotation->hst ? $quotation->hst . '%' : 'N/A' }}
QST:
{{ $quotation->qst ? $quotation->qst . '%' : 'N/A' }}
Final Price Before Tax:
{{ ($quotation->pbt ?? 0.00)}}
Final Price:
{{ $quotation->final_price ?? '0.00' }}
Notes:
{{ $quotation->notes ?? 'N/A' }}
Terms & Conditions:
{{ $quotation->term_conditions ? $quotation->term_conditions->name : 'N/A' }}
Special Note:
{{ $quotation->special_note ?? 'N/A' }}
@endforeach
{{-- Fix (Load Request List only): the duplicate jQuery reload above (pre-existing demo-template leftover) resets $.fn, wiping the Select2 plugin that was already attached in includes/app.blade.php. Reattach it here, using the same asset and config already used everywhere else, scoped to only the Company filter on this page. --}} @include('includes.footer')