@if ($business->logo_image) logo @endif

{{ $business->business_name }}

{{ $business->address }}
{{ $business->email_id }}    {{ $business->web_link }}   {{ $business->contact_no }}

Est : {{ $estimation->estimation_number }}

Estimation

Date: {{ date('d-M-Y', strtotime($estimation->estimation_date)) }}


Name : {{ $estimation->customer?->name }} Plate No. : {{ $estimation->customerVehicle ? $estimation->customerVehicle->plate_number:' ' }}
Contact : {{ $estimation->customer?->contact_number }} Emirates : {{ $estimation->customerVehicle->emirates }}
Address : {{ $estimation->customer?->address }} Brand : {{ $estimation->customerVehicle->vehicleBrand->vehicle_brand }}
VIN No. : {{ $estimation->customerVehicle->vin_number }} Model : {{ $estimation->customerVehicle->vehicleModel->vehicle_model }}
TRN : {{ $estimation->t_r_n }} Created By : {{ $estimation->created_by }}
@if (count($estimation->estimationJobDescriptions) > 0)
Customer Complaints
@foreach ($estimation->estimationJobDescriptions as $estimation_detail) @endforeach
Sr. No. Description
{{ $i . '.' }} {{ $estimation_detail->job_description }}
@endif @if (count($estimation->estimationSpareParts) > 0)
Spare Parts
@foreach ($estimation->estimationSpareParts as $estimation_detail) @php $spare_part_gross += $estimation_detail->quantity * $estimation_detail->sp_selling_price; $vat_total = $estimation_detail->quantity * $estimation_detail->sp_selling_price; $subtotal = $estimation_detail->quantity * $estimation_detail->sp_selling_price; if ($estimation->show_vat == 'yes') { $vat_amount = $subtotal * 0.05; $total = $subtotal + $vat_amount; $total_spare_part += $total; $vat_spare_part += $vat_total * 0.05; } else { $total_spare_part += $subtotal; $vat_spare_part = 0; } @endphp @endforeach
Sr. No. Parts Description Unit Price Qty. Amount 5% Vat Net Total
{{ $i . '.' }} {{ $estimation_detail->sparePart->part_description }} {{ $estimation_detail->sp_selling_price }} {{ $estimation_detail->quantity }} {{ $estimation_detail->quantity * $estimation_detail->sp_selling_price }} @if ($estimation->show_vat == 'yes') {{ $estimation_detail->quantity * $estimation_detail->sp_selling_price * 0.05 }} @else {{ 0 }} @endif @if ($estimation->show_vat == 'yes') {{ number_format($estimation_detail->quantity * $estimation_detail->sp_selling_price + $estimation_detail->quantity * $estimation_detail->sp_selling_price * 0.05, 2) }} @else {{ $estimation_detail->quantity * $estimation_detail->sp_selling_price }} @endif

Total Spare Parts : {{ number_format($total_spare_part, 2) }}

@endif @if (count($estimation->estimationServices) > 0)
Services
@foreach ($estimation->estimationServices as $estimation_detail) @php $service_gross += $estimation_detail->s_selling_price * $estimation_detail->s_time; $vat_total = $estimation_detail->s_selling_price * $estimation_detail->s_time ; $subtotal = $estimation_detail->s_selling_price * $estimation_detail->s_time; if ($estimation->show_vat == 'yes') { $vat_amount = $subtotal * 0.05; $total = $subtotal + $vat_amount; $total_service += $total; $vat_service += $vat_total * 0.05; } else { $total_service += $subtotal; $vat_service = 0; } @endphp @endforeach
Sr. No. Work Description Time Selling Price Amount 5% Vat Net Total
{{ $i . '.' }} {{ $estimation_detail->service->service_name }} {{ $estimation_detail->s_time }} {{ $estimation_detail->s_selling_price }} {{ $estimation_detail->s_selling_price * $estimation_detail->s_time }} @if ($estimation->show_vat == 'yes') {{ $estimation_detail->s_selling_price * $estimation_detail->s_time * 0.05 }} @else {{ 0 }} @endif @if ($estimation->show_vat == 'yes') {{ $estimation_detail->s_selling_price * $estimation_detail->s_time + $estimation_detail->s_selling_price * $estimation_detail->s_time * 0.05 }} @else {{ $estimation_detail->s_selling_price * $estimation_detail->s_time }} @endif

Total Services : {{number_format($total_service,2) }}

@endif @if (count($estimation->estimationSubletServices) > 0)
Sublet Service
@foreach ($estimation->estimationSubletServices as $estimation_sublet_service) @php $sublet_gross +=$estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price; $vat_total = $estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price; $subtotal = $estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price ; if ($estimation->show_vat == 'yes') { $vat_amount = $subtotal * 0.05; $total = $subtotal + $vat_amount; $total_sublet_service += $total; $vat_sublet_service += $vat_total * 0.05 ; } else { $total_sublet_service += $subtotal; $vat_sublet_service = 0; } @endphp @endforeach
Sr. No. Sublet Description Time Selling price Amount 5% Vat Net Total
{{ $i . '.' }} {{ $estimation_sublet_service->service->service_name }} {{ $estimation_sublet_service->ss_time }} {{ $estimation_sublet_service->ss_selling_price }} {{ $estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price }} @if ($estimation->show_vat == 'yes') {{ $estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price * 0.05 }} @else {{ 0 }} @endif @if ($estimation->show_vat == 'yes') {{ $estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price + $estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price * 0.05 }} @else {{ $estimation_sublet_service->ss_time * $estimation_sublet_service->ss_selling_price }} @endif

Total Sublet Service Cost: : {{ number_format($total_sublet_service,2 )}}

@endif
Remark :
Total Amount In Words :
@php $total_amount = $total_spare_part + $total_service + $total_sublet_service ; $t_amount = new NumberFormatter('en', NumberFormatter::SPELLOUT); $num = explode('.', $total_amount); // Function to capitalize first letter of each word function capitalizeWords($str) { return ucwords(strtolower($str)); } $dollars_in_words = $t_amount->format($num[0]); $dollars_in_words_capitalized = capitalizeWords($dollars_in_words); $cents_in_words = isset($num[1]) ? $t_amount->format($num[1]) . ' Fils Only' : 'Only'; $cents_in_words_capitalized = capitalizeWords($cents_in_words); @endphp AED {{ $dollars_in_words_capitalized }} {{ $cents_in_words_capitalized }}
Gross Amount AED {{ $spare_part_gross+ $service_gross + $sublet_gross}}
5% VAT {{ number_format( $total_vat,2 ) }}
Net Total AED
{{ number_format( $spare_part_gross+ $service_gross + $sublet_gross + $total_vat, 2) }}