{{ ucwords($global->company_name) }}

{!! nl2br($global->address) !!}
{{ $global->company_phone }}
{{ (is_null($estimate->estimate_number)) ? '#'.$estimate->id : $estimate->estimate_number}}
@lang("modules.estimates.validTill") : {{ $estimate->valid_till->format($global->date_format) }}
@lang('app.status') : {{ __('app.'.$estimate->status) }}
@php $colspan = ($invoiceSetting->hsn_sac_code_show) ? 5 : 4; @endphp

@if($invoiceSetting->hsn_sac_code_show) @endif @foreach($estimate->items as $item) @if($item->type == 'item') @if($invoiceSetting->hsn_sac_code_show) @endif @if(!is_null($item->item_summary)) @endif @endif @endforeach
# @lang("modules.invoices.item") @lang('modules.invoices.hsnSacCode')@lang("modules.invoices.qty") @lang("modules.invoices.unitPrice") ({!! htmlentities($estimate->currency->currency_code) !!}) @lang("modules.invoices.price") ({!! htmlentities($estimate->currency->currency_code) !!})
{{ ++$count }}

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

{{ $item->hsn_sac_code ?? '--' }}{{ $item->quantity }} {{currency_formatter($item->unit_price,'')}} {{currency_formatter($item->amount,'')}}
hsn_sac_code_show) colspan="4" @else colspan="3" @endif style="padding: 0!important;"> @if(!is_null($item->item_summary))

{{ $item->item_summary }}

@endif
@if($discount != 0 && $discount != '') @endif @foreach($taxes as $key=>$tax) @endforeach
@lang("modules.invoices.subTotal"): {{ currency_formatter($estimate->sub_total, '') }}
@lang("modules.invoices.discount"): -{{ currency_formatter($discount, '') }}
{{ strtoupper($key) }}: {{ currency_formatter($tax, '') }}
@lang("modules.invoices.total"): {{ currency_formatter($estimate->total,'')}}

@if (isset($invoice))
{!! nl2br($invoice->note) !!}
{!! nl2br($invoiceSetting->invoice_terms) !!} @endif

@if($estimate->sign)

@lang('modules.estimates.signature') (@lang('app.customers'))

@endif

@lang('app.thanks')!
{{--Custom fields data--}} @if(isset($fields) && count($fields) > 0)

@lang('modules.projects.otherInfo')

@foreach($fields as $field) @endforeach
{{ ucfirst($field->label) }}

@if( $field->type == 'text') {{$invoice->custom_fields_data['field_'.$field->id] ?? '-'}} @elseif($field->type == 'password') {{$invoice->custom_fields_data['field_'.$field->id] ?? '-'}} @elseif($field->type == 'number') {{$invoice->custom_fields_data['field_'.$field->id] ?? '-'}} @elseif($field->type == 'textarea') {{$invoice->custom_fields_data['field_'.$field->id] ?? '-'}} @elseif($field->type == 'radio') {{ !is_null($invoice->custom_fields_data['field_'.$field->id]) ? $invoice->custom_fields_data['field_'.$field->id] : '-' }} @elseif($field->type == 'select') {{ (!is_null($invoice->custom_fields_data['field_'.$field->id]) && $invoice->custom_fields_data['field_'.$field->id] != '') ? $field->values[$invoice->custom_fields_data['field_'.$field->id]] : '-' }} @elseif($field->type == 'checkbox') {{ !is_null($invoice->custom_fields_data['field_'.$field->id]) ? $field->values[$invoice->custom_fields_data['field_'.$field->id]] : '-' }} @elseif($field->type == 'date') {{ !is_null($invoice->custom_fields_data['field_'.$field->id]) ? \Carbon\Carbon::parse($invoice->custom_fields_data['field_'.$field->id])->format($global->date_format) : '--'}} @endif

@endif