@includeIf('invoices.pdf.invoice_pdf_css')

@lang('app.bill')

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

{{ $purchaseBill->bill_number }}

@lang('purchase::app.menu.billDate'): {{ $purchaseBill->bill_date->translatedFormat(company()->date_format) }}
@lang('app.status'): {{ $purchaseBill->status }}
@if ($invoiceSetting->hsn_sac_code_show) @endif @foreach ($purchaseBill->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($purchaseOrder->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, $purchaseOrder->currency_id, false) }}

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

@if (!is_null($purchaseOrder->note)) @lang('app.note')
{!! nl2br($purchaseOrder->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