@php $logoPath = public_path('images/invoice/' . $invoice_template['logo']); @endphp
@if ($invoice_type == 'a5') @if ($invoice_template['title']) @else @endif @elseif ($invoice_type == 'a4') @endif
{!! $invoice_template['title'] !!}

INVOICE

មានបោះដុំ និងលក់រាយ
នំ ស្ករ និងសំភារះក្មេងលេងគ្រប់ប្រភេទ
{!! $invoice_template['header_text'] !!}
Logo
@if ($invoice_type == 'a4')
Tel

: 089 990 900

: 088 79 90 900

@elseif ($invoice_type == 'a5')
Tel

: 089 990 900

: 088 79 90 900

@endif
@if ($invoice_type == 'a4') @if ($invoice_template['title'])
{{-- company block --}}
វិក័យប័ត្រ
INVOICE
@endif {{-- customer block --}}
{{-- --}}
អតិថិជន: {{ $sale['customer_name'] }}
អាស័យដ្ឋាន: {{ $sale['customer_address'] }}
លេខទូរស័ព្ទ: {{ $sale['customer_phone'] }}
{{-- company block --}}
@if ($sale['seller'] != null) @endif
លេខវិក័យប័ត្រ: {{ $sale['ref_no'] }}
កាលបរិច្ឆេទ: {{ $sale['transaction_date'] }}
អ្នកគិតលុយ: {{ $user }}
អ្នកទីផ្សារ {{ $sale['seller'] }}
@elseif ($invoice_type == 'a5') @if ($invoice_template['title'])
{{-- company block --}}
វិក័យប័ត្រ
INVOICE
@endif {{-- customer block --}}
{{-- --}}
អតិថិជន: {{ $sale['customer_name'] }}
អាស័យដ្ឋាន: {{ $sale['customer_address'] }}
លេខទូរស័ព្ទ: {{ $sale['customer_phone'] }}
{{-- company block --}}
@if ($sale['seller'] != null) @endif
លេខវិក័យប័ត្រ: {{ $sale['ref_no'] }}
កាលបរិច្ឆេទ: {{ $sale['transaction_date'] }}
អ្នកគិតលុយ: {{ $user }}
អ្នកទីផ្សារ {{ $sale['seller'] }}
@endif
@php $sortedSaleLists = collect($sale_lists)->sortBy('id')->values(); @endphp @foreach ($currencies as $index => $item) @endforeach @foreach ($sortedSaleLists as $index => $row) @foreach ($currencies as $index => $item) @if ($item['symbol'] == $row['currency_symbol']) @endif @if ($item['symbol'] != $row['currency_symbol']) @endif @endforeach @endforeach @if (count($sum_qty) === 1) @else @endif @foreach ($currencies as $index => $item) @endforeach @if ($sale['outstanding_amount'] > 0) @if (count($sum_qty) === 1) @else @endif @endif @if ($sale['status'] != 2 && $sale['status'] != 3) @if (count($sum_qty) === 1) @else @endif @foreach ($currencies as $index => $item) @endforeach @if (count($sum_qty) === 1) @else @endif @endif
ល.រ មុខទំនិញ ចំនួន តម្លៃរាយ {{ $item['name'] }}
{{ $index + 1 }} {{ $row['product_variation_name'] }} {{ $row['price'] == 0 ? '(ថែម)' : '' }}
@if ($row['remark'] != null) {{ $row['remark'] }} @endif
{{ App\Helpers\StringHelper::currency($row['qty']) }} {{ $row['unit_type_name'] }} {{ $row['currency_symbol'] }} {{ App\Helpers\StringHelper::currency($row['price']) }} {{ $row['currency_code'] == 'THB' ? 'B' : $row['currency_symbol'] }} {{ App\Helpers\StringHelper::currency($row['total_price']) }} {{ $item['code'] == 'THB' ? 'B' : $item['symbol'] }} 0
ផ្សេងៗ:
{{ $sale['remark'] }}
{!! $invoice_template['term_and_condition'] !!}
@foreach ($sum_qty as $item)
{{ App\Helpers\StringHelper::currency($item['sumQtyByUnitType']) }} {{$item['unit_type_name']}}
@endforeach
@foreach ($sum_qty as $item)
{{ App\Helpers\StringHelper::currency($item['sumQtyByUnitType']) }} {{$item['unit_type_name']}}
@endforeach
សរុប: @foreach ($get_sub_total_sum_by_currency as $i => $obj) @if ($obj['currency_id'] == $item['id']) {{ $item['pdf_symbol'] }} {{ App\Helpers\StringHelper::currency($obj['total_price']) }} @endif @endforeach
ជំពាក់ចាស់: ជំពាក់ចាស់: @foreach ($currencies as $index => $item) @if ($sale['currency_id'] == $item['id']) {{ $item['pdf_symbol'] }} {{ App\Helpers\StringHelper::currency( ($sale['outstanding_amount'] / $sale['sell_out_price']) * $item['sell_out_price'], ) }} @endif @endforeach
សង: សង: @foreach ($payment_history['payment_history_detail'] as $index => $phd) @if ($phd['currency_id'] == $item['id']) {{ $item['pdf_symbol'] }} {{ App\Helpers\StringHelper::currency($phd['total_amount']) }} @endif @endforeach
ជំពាក់: ជំពាក់: {{ $currencies[0]['pdf_symbol'] }} {{ App\Helpers\StringHelper::currency($sale['total_payment'] - $sale['total_paid']) }}
 
{{--

ហត្ថលេខា និង ឈ្មោះអ្នកអតិថិជន

ហត្ថលេខា និង ឈ្មោះអ្នកដឹក

ហត្ថលេខា និង ឈ្មោះអ្នកលក់

{!! $invoice_template['footer_text'] !!}
--}}