@php $logoDataUri = null; $faDigits = static fn (int|float|string|null $value): string => \App\Support\PersianTextNormalizer::digits($value); $faNumber = static fn (int|float|string|null $value, int $decimals = 0): string => \App\Support\PersianTextNormalizer::number($value, $decimals); $faMoneyWords = static fn (int|float|string|null $value): string => \App\Support\PersianTextNormalizer::moneyInWords($value); if ($workspace->logo_path && \Illuminate\Support\Facades\Storage::disk('public')->exists($workspace->logo_path)) { $logoFullPath = \Illuminate\Support\Facades\Storage::disk('public')->path($workspace->logo_path); $logoMime = mime_content_type($logoFullPath) ?: 'image/png'; $logoDataUri = 'data:'.$logoMime.';base64,'.base64_encode(file_get_contents($logoFullPath)); } @endphp
|
@fa('پیشفاکتور شماره') {{ $faDigits($quotation->number) }}
@fa('نسخه') {{ $faDigits($quotation->version_no) }}
|
@fa('تاریخ صدور') :{{ $faDigits(jdate($quotation->issue_date)->format('Y/m/d')) }} @if ($quotation->valid_until) @fa('اعتبار تا') :{{ $faDigits(jdate($quotation->valid_until)->format('Y/m/d')) }} @endif |
| @fa('مشخصات فروشنده') | @if ($logoDataUri)
|
@endif
| @fa('نام'): @fa($workspace->name) | @fa('شهر'): @fa($workspace->city) | @fa('تلفن/نمابر'): {{ $faDigits($workspace->phone) }} |
| @fa('کدپستی'): {{ $faDigits($workspace->postal_code) }} | @fa('شماره اقتصادی'): {{ $faDigits($workspace->economic_code) }} | @fa('شماره ثبت'): {{ $faDigits($workspace->registration_number) }} |
| @fa('نشانی'): @fa($workspace->address) | @fa('شناسه ملی'): {{ $faDigits($workspace->national_id) }} | |
| @fa('نام'): @fa(data_get($buyer, 'company_name') ?: data_get($buyer, 'name')) | @fa('شهر'): @fa(data_get($buyer, 'city')) | @fa('تلفن/موبایل'): {{ $faDigits(data_get($buyer, 'phone') ?: data_get($buyer, 'mobile')) }} |
| @fa('کدپستی'): {{ $faDigits(data_get($buyer, 'postal_code')) }} | @fa('شماره اقتصادی'): {{ $faDigits(data_get($buyer, 'economic_code')) }} | @fa('شماره ثبت'): {{ $faDigits(data_get($buyer, 'registration_number')) }} |
| @fa('نشانی'): @fa(data_get($buyer, 'address')) | @fa('شناسه/شماره ملی'): {{ $faDigits(data_get($buyer, 'national_id')) }} | |
| @fa('ردیف') | @fa('کدکالا') | @fa('شرح کالا یا خدمت') | @fa('تعداد') | @fa('واحد') | @fa('مبلغ واحد') | @fa('مبلغ کل') | @fa('مبلغ تخفیف') | @fa('مبلغ پس از تخفیف') | @fa('جمع مالیات') | @fa('مبلغ نهایی') |
|---|---|---|---|---|---|---|---|---|---|---|
| {{ $faDigits($index + 1) }} | {{ $faDigits($item->sku ?: '-') }} | @fa($item->name) | {{ $faNumber($item->qty, 0) }} | @fa($item->unit) | {{ $faNumber($item->unit_price, 0) }} | {{ $faNumber($rawTotal, 0) }} | {{ $faNumber($item->discount_amount, 0) }} | {{ $faNumber($afterDiscount, 0) }} | {{ $faNumber($item->tax_amount, 0) }} | {{ $faNumber($item->line_total, 0) }} |
| @fa('جمع کل') | {{ $faNumber(bcadd($quotation->subtotal, $quotation->discount_total, 2), 0) }} | {{ $faNumber($quotation->discount_total, 0) }} | {{ $faNumber($quotation->subtotal, 0) }} | {{ $faNumber($quotation->tax_total, 0) }} | {{ $faNumber($quotation->total_amount, 0) }} @fa('ریال') | |||||
| @fa('سایر هزینهها') | {{ $faNumber($quotation->other_cost_total, 0) }} | |||||||||
| • | @fa($note->text) |
@fa($quotation->custom_note)
@endif| @fa('مهر و امضاء فروشنده') | @fa('مهر و امضاء خریدار') |