@php $request = request(); $is_official = $request->is_official; $is_combined = (empty($is_official) || $is_official == 'combine') ; if($is_combined){ $brought_forward = $brought_forward + $brought_forward_unofficial; } $currency_code = $transaction->systemSettingCurrency(); $show_official_tag = !empty($is_official) && $is_official != 'combine'; $show_official = ($is_official == 'official' || $is_official == 'separate' || $is_official == 'combine' || empty($is_official)); $show_unofficial = ($is_official == 'unofficial' || $is_official == 'separate'); $hide_columns = request()->get('hide_columns',[]); $total_colspan = 10 - count(array_filter($hide_columns, function($cond) { return $cond != 'custom_particulars'; })); @endphp
{{ config('settings.company_name') }}
{{ config('settings.address_1') }}
{{ $heading }}
@if ($search_by['from']) {{__('lang.from')}} {{ $transaction->date_format($search_by['from']) }} @endif Till @if ( $search_by['to']) {{__('lang.from')}} {{ $transaction->date_format($search_by['to']) }} @endif @if ( !$search_by['to'] || !$search_by['to']) {{ $transaction->date_format(now()) }} @endif
@if(!in_array('registration_no',$hide_columns)) @endif @if(!in_array('instrument_no',$hide_columns)) @endif @if(!in_array('reference_no',$hide_columns)) @endif @if(!in_array('mode_of_payment',$hide_columns)) @endif @if(!in_array('payee_name',$hide_columns)) @endif @if($show_official) @endif @if($show_unofficial) @endif @if($show_official) @endif @if($show_unofficial) @endif @php $grand_dr = 0; $grand_cr = 0; $grand_dr_unofficial = 0; $grand_cr_unofficial = 0; $grand_balance = $brought_forward; $grand_balance_unofficial = $brought_forward_unofficial; $bf_colspan = $total_colspan + 2; if($is_official=='separate'){ $bf_colspan = $total_colspan + 4; } @endphp @if($show_official) @endif @if($show_unofficial) @endif @if(count($transactions)==0) @endif @foreach ($transactions as $transaction) @php $transaction_detail = Transaction::getTransactionDetails($transaction,$hide_columns); if($transaction->get_actual_received->status != "Void") { $route = $transaction_detail->route; } else { $route = "#"; } $voucher_date = $transaction->voucher_date; if($date_type == 'cheque_date'){ $voucher_date = $transaction->cheque_date; } $voucher_no = $transaction->voucher_no; $registration_no = '-'; $sell = $transaction_detail->sell ?? null; $branch = $transaction->branch->name; $instrument_no = $transaction->cheque_number; $reference_no = $transaction_detail->ref_no ?? null; $mode_of_payment = $transaction_detail->mode_of_payment ?? null; $particulars = $transaction_detail->particulars ?? null; $particulars = $particulars ? $particulars : $transaction->particulars; $payee_name = $transaction_detail->payee_name ?? null; $dr = $transaction->dr; $cr = $transaction->cr; $dr_unofficial = 0; $cr_unofficial = 0; if($transaction->is_official == 0 && !$is_combined){ $dr = 0; $cr = 0; $dr_unofficial = $transaction->dr; $cr_unofficial = $transaction->cr; } $balance = $grand_balance + $dr -$cr; $balance_unofficial = $grand_balance_unofficial + $dr_unofficial -$cr_unofficial; $grand_dr += $dr; $grand_cr += $cr; $grand_dr_unofficial += $dr_unofficial; $grand_cr_unofficial += $cr_unofficial; $grand_balance = $balance; $grand_balance_unofficial = $balance_unofficial; @endphp @if(!in_array('registration_no',$hide_columns)) @endif @if(!in_array('instrument_no',$hide_columns)) @endif @if(!in_array('reference_no',$hide_columns)) @endif @if(!in_array('mode_of_payment',$hide_columns)) @endif @if(!in_array('payee_name',$hide_columns)) @endif @if($show_official) @endif @if($show_unofficial) @endif @if($show_official) @endif @if($show_unofficial) @endif @endforeach @if($show_official) @endif @if($show_unofficial) @endif @if($show_official) @endif @if($show_unofficial) @endif
{{ $common->head_code_with_parent_code($head->id) }} {{ $head->name }} ({{ ucwords($head->reference_type) }})
{{__('lang.s_no')}} {{$date_type == 'cheque_date' ? __('lang.cheque') : __('lang.voucher')}} {{__('lang.date')}} {{__('lang.voucher_no')}}{{__('lang.registration_no')}}{{__('lang.project')}}{{__('lang.instrument_no')}}{{__('lang.reference_no')}}{{__('lang.mode_of_payment')}}{{__('lang.particulars')}}{{__('lang.payee_name')}} {{__('lang.dr')}} {{ $currency_code }} @if($show_official_tag)
({{__('lang.official')}}) @endif
{{__('lang.cr')}} {{ $currency_code }}@if($show_official_tag)
({{__('lang.official')}}) @endif
{{__('lang.dr')}} {{ $currency_code }}
({{__('lang.unofficial')}})
{{__('lang.cr')}} {{ $currency_code }}
({{__('lang.unofficial')}})
{{__('lang.balance')}} {{ $currency_code }} @if($show_official_tag)
({{__('lang.official')}}) @endif
{{__('lang.balance')}} {{ $currency_code }}
({{__('lang.unofficial')}})
Balance B/F    {{ Transaction::isNegative($brought_forward) }}{{ Transaction::isNegative($brought_forward_unofficial) }}
No Transactions
{{ $loop->iteration }} {{ Transaction::date_format($voucher_date)}} {{$voucher_no}} @if($sell) {{ $sell->registration_no }}
({{$sell->customer->name}})
@else - @endif
{{$branch}}{{$instrument_no}}{{$reference_no}}{{$mode_of_payment}}{!! $particulars !!}{{$payee_name}}{{Transaction::isNegative($dr)}} {{Transaction::isNegative($cr)}}{{Transaction::isNegative($dr_unofficial)}} {{Transaction::isNegative($cr_unofficial)}}{{Transaction::isNegative($balance)}}{{Transaction::isNegative($balance_unofficial)}}
{{__('lang.total')}}{{ Transaction::isNegative($grand_dr) }} {{ Transaction::isNegative($grand_cr) }}{{ Transaction::isNegative($grand_dr_unofficial) }} {{ Transaction::isNegative($grand_cr_unofficial) }}{{ Transaction::isNegative($grand_balance) }}{{ Transaction::isNegative($grand_balance_unofficial) }}