@extends('layouts.main') @section('main-container')
@if (Session::has('success')) @endif @if($errors->any()) @endif
Journal
@csrf
Print Excel
Millennium Computers And Networking
Journal For {{ $glcodeName }}
From {{ $start_date}} To {{ $end_date}}
@php $count = 1; $opencashdr = 0; $opencashcr = 0; $openbankdr= 0; $openbankcr= 0; @endphp @php $Total_dr=0; $Total_cr=0; $BlDrAmount=0; $BlCrAmount=0; $MasterBalance=0; @endphp @foreach ($masjournals as $masjournal) @php $DrAmount = $masjournal->DrAmount; $CrAmount = $masjournal->CrAmount; $ttype = $masjournal->ttype; $CrAmount = $masjournal->CrAmount; $Total_dr=$Total_dr+$DrAmount; $Total_cr=$Total_cr+$CrAmount; if(strcmp($ttype,"Dr")==0) { $MasterBalance=$MasterBalance+$masjournal->amount; } else { $MasterBalance=$MasterBalance-$masjournal->amount; } ////////////////////////////////////////// if($MasterBalance>0) { $BlDrAmount=$MasterBalance; $BlCrAmount=0; } else if($MasterBalance<0) { $BlCrAmount=$MasterBalance*-1; $BlDrAmount=0; } else { $BlDrAmount=0; $BlCrAmount=0; } @endphp @endforeach
Entry No Type Date Description JV For Period Transaction
Debit Credit
{{ $masjournal->journalno }} {{ $masjournal->journaltype }} {{ $masjournal->journaldate }} {{ $masjournal->description }} {{ $masjournal->customer_name }} {{ $masjournal->employee }} {{ $masjournal->supplier }} {{ $DrAmount }} {{ $CrAmount }}
Total
@endsection