@includeIf('invoices.pdf.invoice_pdf_css')

@lang('purchase::app.menu.purchaseOrder')

@lang('modules.invoices.billedTo'):
{{ mb_ucwords(company()->company_name) }}
@if ($order->address) {!! nl2br($order->address->address) !!}
@endif {{ company()->company_phone }} @if ($invoiceSetting->show_gst == 'yes' && $order->address)
{{ strtoupper($order->address->tax_name) }}: {{ $order->address->tax_number }} @endif
@lang('modules.invoices.billedFrom'): @if ($order->vendor && $order->vendor->primary_name) {{$order->vendor->primary_name}}
@endif @if ($order->vendor && $order->vendor->email) {{$order->vendor->email}}
@endif @if ($order->vendor && $order->vendor->billing_address) {{$order->vendor->billing_address}}
@endif @if ($order->vendor && $order->vendor->phone) {{$order->vendor->phone}}
@endif

{{ $order->purchase_order_number }}

@lang('modules.orders.orderDate'): {{ $order->purchase_date->translatedFormat(company()->date_format) }}
@lang('app.status'): {{ $order->purchase_status }}
@if ($invoiceSetting->hsn_sac_code_show) @endif @foreach ($order->items as $item) @if ($item->type == 'item') @if ($invoiceSetting->hsn_sac_code_show) @endif @endif @endforeach @if ($invoiceSetting->hsn_sac_code_show) @endif @if ($discount != 0 && $discount != '') @if ($invoiceSetting->hsn_sac_code_show) @endif @endif @foreach ($taxes as $key => $tax) @if ($invoiceSetting->hsn_sac_code_show) @endif @endforeach
# @lang('modules.invoices.item')@lang('app.hsnSac')@lang('modules.invoices.qty') @lang('modules.invoices.unitPrice') @lang('modules.invoices.tax') @lang('modules.invoices.price') ({!! htmlentities($order->currency->currency_code) !!})
{{ ++$count }}

{{ ucfirst($item->item_name) }}

@if (!is_null($item->item_summary))
{!! nl2br(strip_tags($item->item_summary, ['p', 'b', 'strong', 'a'])) !!}
@endif @if ($item->purchaseItemImage)

@endif

{{ $item->hsn_sac_code ? $item->hsn_sac_code : '--' }}

{{ $item->quantity }}
{{ $item->unit->unit_type }}

{{ currency_format($item->unit_price, $order->currency_id, false) }}

{{ strtoupper($item->tax_list) }} {{ currency_format($item->amount, $order->currency_id, false) }}
        @lang('modules.invoices.subTotal') {{ currency_format($order->sub_total, $order->currency_id, false) }}
        @lang('modules.invoices.discount') {{ currency_format($discount, $order->currency_id, false) }}
        {{ mb_strtoupper($key) }} {{ currency_format($tax, $order->currency_id, false) }}
@lang('modules.invoices.total') {{ currency_format($order->total, $order->currency_id, false) }}

@if (!is_null($order->note)) @lang('app.note')
{!! nl2br($order->note) !!}
@endif
@lang('modules.invoiceSettings.invoiceTerms')
{!! nl2br($invoiceSetting->invoice_terms) !!}

@if (isset($taxes) && $invoiceSetting->tax_calculation_msg == 1)

@if ($order->calculate_tax == 'after_discount') @lang('messages.calculateTaxAfterDiscount') @else @lang('messages.calculateTaxBeforeDiscount') @endif

@endif