{{$supplier->name??""}}
{{$supplier->tax_number??""}}
{{getCountryCode()}}{{$supplier->phone??""}}

@php $opening_balance = $supplier->opening_balance; $total_purchase = \App\Models\Purchase::where('purchase_type',2)->where('supplier_id',$supplier_id)->sum('total'); $purchase_count = \App\Models\Purchase::where('purchase_type',2)->where('supplier_id',$supplier_id)->count(); $total_paid = \App\Models\SupplierPayment::where('supplier_id',$supplier_id)->sum('paid_amount'); $balance = ($total_purchase+$opening_balance) - $total_paid; @endphp
{{ __('main.opening_balance') }}
{{ getFormattedCurrency($opening_balance)}}
{{ __('main.total_purchases') }}
{{$purchase_count}}
{{ __('main.total_amount') }}
{{getFormattedCurrency($total_purchase)}}
{{ __('main.paid_amount') }}
{{getFormattedCurrency($total_paid)}}
{{ __('main.balance_amount') }}
{{getFormattedCurrency($balance)}}
@if($supplier->email!='')
{{ __('main.email') }}
{{$supplier->email??""}}
@endif @if($supplier->supplier_address!='')
{{ __('main.address') }}
{{$supplier->supplier_address}}
@endif