IMMREX7

aku nok ndi : /home/spdtg/www/schoolmis/resources/views/schools/north/transaction/
File Up :
aku nok ndi : /home/spdtg/www/schoolmis/resources/views/schools/north/transaction/print_receipt.blade.php

<!DOCTYPE html>
<html>
    <head>
        <!-- <meta charset="utf-8"> -->
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <title>School MIS</title>
        <!-- Tell the browser to be responsive to screen width -->
        <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
        <meta name="csrf-token" content="{{ csrf_token() }}">
        <style type="text/css">
            @page {
                header: page-header;
                footer: page-footer;
                margin-top: 20pt;
                margin-bottom: 10px;
            }
            section{

            }
            body {
                font-family: 'examplefont', sans-serif;
            }	
        </style>
    </head>

    <body>
        <!--<htmlpageheader name="page-header" >-->
        <table class="table">
            <tbody>
                <tr>
                    <th style="vertical-align: middle;text-align: center; width: 30%; padding: 0px; "><img src="{{ asset('storage/schools/'.$school->idSchool.'/'.$school->schoolLogo)}}" height="90" width="90"></th>
                    <td style="vertical-align: middle;text-align: center; width: 36%; padding: 0px; ">
                        <strong>{{$school->schoolName}}</strong><br>
                        {{$school->street}} {{$school->landmark}} {{$school->subArea}} {{$school->area}} <br>
                        {{$school->city}}  {{$school->state->stateName}}<br>
                        <strong>Contact No : {{$school->mobile}}</strong><br>
                        <strong>Email : {{$school->email}}</strong><br>
                        @if($transaction->paymentMode == 'Online') <strong>Transaction ID @else Receipt No : @endif{{$transaction->receiptNo}}</strong><br>
                    </td>
                </tr>
            </tbody>
        </table>
        <!--</htmlpageheader>-->
        <section>
            <div class="content">
                <table border="1" style="width:100% ;border-collapse: collapse;overflow: wrap;">
                    <thead>
                        <tr style="border: 1px solid black;">
                            <th style="border: 1px solid black;">Date</th>
                            <th style="border: 1px solid black;">Name</th>
                            <th style="border: 1px solid black;">Class</th>
                            <th style="border: 1px solid black;">Section</th>
                            <th style="border: 1px solid black;">Enrollment No.</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>{{$transaction->paymentDate}}</td>
                            <td>{{$student->firstName}}  {{$student->middleName}}  {{$student->lastName}}</td>
                            <td>{{$student->classM->className}}</td>
                            <td>{{$student->section->sectionName}}</td>
                            <td>{{$student->ecNo}}</td>
                        </tr>
                    </tbody>
                </table>
                <p></p>
                <table border="1" style="width:100% ;border-collapse: collapse;overflow: wrap;">
                    <thead>
                        <tr style="border: 1px solid black;">
                            <th style="border: 1px solid black;">Particular</th>
                            <th style="border: 1px solid black;">Fee</th>
                            <th style="border: 1px solid black;">Fee Paid</th>
                            <th style="border: 1px solid black;">Discount</th>
                            <th style="border: 1px solid black;">Penalty</th>
                        </tr>
                    </thead>
                    <tbody>
                      
                       @foreach($demands  as $id)
                        <?php
                            $det=\App\NorthFeeHead::where('idFeehead',$id->isParent)->first();
                            
                            $idType=$det->idType;
                            
                            if($idType=='fee'){
                            $feepaid_details = DB::table('student_transaction_details')
                                        ->join('northfeeheads','student_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select('headerName','northfeeheads.amount','northfeeheads.discount','student_transaction_details.amountPaid')
                                        ->where('student_transaction_details.idTransaction','=',$transaction->idTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->get();
                            }elseif($idType=='bus'){
                                $feepaid_details = DB::table('bus_transaction_details')
                                        ->join('northfeeheads','bus_transaction_details.idBusFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select('headerName','northfeeheads.amount','northfeeheads.discount','bus_transaction_details.amountPaid')
                                        ->where('bus_transaction_details.idBusTransaction','=',$transaction->idBusTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->get();
                            }elseif($idType=='hostel'){
                                $feepaid_details = DB::table('hostel_transaction_details')
                                        ->join('northfeeheads','hostel_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select('headerName','northfeeheads.amount','northfeeheads.discount','hostel_transaction_details.amountPaid')
                                        ->where('hostel_transaction_details.idHostelTransaction','=',$transaction->idHostelTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->get();
                            }
                            
                            if($idType=='fee'){
                            $feepaid = DB::table('student_transaction_details')
                                        ->join('northfeeheads','student_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select(DB::raw('SUM(student_transaction_details.amountPaid) as total'),DB::raw('SUM(student_transaction_details.discount) as discount'))
                                        ->where('student_transaction_details.idTransaction','=',$transaction->idTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->first(); 
                            }elseif($idType=='bus'){
                                $feepaid = DB::table('bus_transaction_details')
                                        ->join('northfeeheads','bus_transaction_details.idBusFeehead','=','northfeeheads.idFeehead')
                                        ->select(DB::raw('SUM(bus_transaction_details.amountPaid) as total'),DB::raw('SUM(bus_transaction_details.discount) as discount'))
                                        ->where('bus_transaction_details.idBusTransaction','=',$transaction->idBusTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->first();
                            }elseif($idType=='hostel'){
                                $feepaid = DB::table('hostel_transaction_details')
                                        ->join('northfeeheads','hostel_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->select(DB::raw('SUM(hostel_transaction_details.amountPaid) as total'),DB::raw('SUM(hostel_transaction_details.discount) as discount'))
                                        ->where('hostel_transaction_details.idHostelTransaction','=',$transaction->idHostelTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->first();
                            }
                        ?>
                        <tr>
                            <th>{{$det->demandName}}</th>
                            <td><b>{{$det->amount}}</b></td>
                            <td><b>{{$feepaid->total}}</b></td>
                            <td><b>{{$feepaid->discount}}</b></td>
                            <td><b>0.00</b></td>
                        </tr>
                                @foreach($feepaid_details as $fd)
                                    <tr>
                                        <td>{{$fd->headerName}}</td>
                                        <td>{{$fd->amount}}</td>
                                        <td>{{$fd->amountPaid}}</td>
                                        <td>{{$fd->discount}}</td>
                                        <td>0.00</td>
                                    </tr>
                                @endforeach
                        @endforeach

                        <tr>
                            <td colspan="2">Remarks: Fee Paid By  : <strong>{{$transaction->paymentMode}}</strong><br>
                                @if($transaction->paymentMode == 'Cheque' || $transaction->paymentMode =='DD')
                                Cheque/DD No. :  {{$transaction->chequeNo}}<br>
                                Cheque/DD Date : {{$transaction->chequeDate}}<br>
                                Bank Name : {{$transaction->bank->bankName or ''}}<br>
                                Amount : {{$transaction->totalPaid}}<br>
                                @endif
                                
                                <?php $excess  = \App\ExcessTransaction::where('idTransaction','=',$transaction->idTransaction)->first();?>
                                
                                <br>@if($excess) Excess Amount Paid :  {{$excess->excessAmount}}@endif
                            </td>
                            <td colspan="3">Fee Rs.: 
                                {{figToWord($transaction->totalPaid)}} <br> 
                            </td>
                       
                    </tbody>
                </table>
                <p>This is computer Generated Receipt.</p>
                <hr>

                <table class="table">
                    <tbody>
                        <tr>
                            <th style="vertical-align: middle;text-align: center; width: 30%; padding: 0px; "><img src="{{ asset('storage/schools/'.$school->idSchool.'/'.$school->schoolLogo)}}" height="90" width="90"></th>
                            <td style="vertical-align: middle;text-align: center; width: 36%; padding: 0px; ">
                                <strong>{{$school->schoolName}}</strong><br>
                                {{$school->street}} {{$school->landmark}} {{$school->subArea}} {{$school->area}} <br>
                                {{$school->city}}  {{$school->state->stateName}}<br>
                                <strong>Contact No : {{$school->mobile}}</strong><br>
                                <strong>Email : {{$school->email}}</strong><br>
                                @if($transaction->paymentMode == 'Online') <strong>Transaction ID @else Receipt No : @endif{{$transaction->receiptNo}}</strong><br>
                            </td>
                        </tr>
                    </tbody>
                </table>
                <table border="1" style="width:100% ;border-collapse: collapse;overflow: wrap;">
                    <thead>
                        <tr style="border: 1px solid black;">
                            <th style="border: 1px solid black;">Date</th>
                            <th style="border: 1px solid black;">Name</th>
                            <th style="border: 1px solid black;">Class</th>
                            <th style="border: 1px solid black;">Section</th>
                            <th style="border: 1px solid black;">Enrollment No.</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>{{$transaction->paymentDate}}</td>
                            <td>{{$student->firstName}}  {{$student->middleName}}  {{$student->lastName}}</td>
                            <td>{{$student->classM->className}}</td>
                            <td>{{$student->section->sectionName}}</td>
                            <td>{{$student->ecNo}}</td>
                        </tr>
                    </tbody>
                </table>
                <p></p>
                <table border="1" style="width:100% ;border-collapse: collapse;overflow: wrap;">
                    <thead>
                        <tr style="border: 1px solid black;">
                            <th style="border: 1px solid black;">Particular</th>
                            <th style="border: 1px solid black;">Fee</th>
                            <th style="border: 1px solid black;">Fee Paid</th>
                            <th style="border: 1px solid black;">Discount</th>
                            <th style="border: 1px solid black;">Penalty</th>
                        </tr>
                    </thead>
                    <tbody>
                        @foreach($demands  as $id)
                        <?php
                            $det=\App\NorthFeeHead::where('idFeehead',$id->isParent)->first();
                            
                            $idType=$det->idType;
                            
                            if($idType=='fee'){
                            $feepaid_details = DB::table('student_transaction_details')
                                        ->join('northfeeheads','student_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select('headerName','northfeeheads.amount','northfeeheads.discount','student_transaction_details.amountPaid')
                                        ->where('student_transaction_details.idTransaction','=',$transaction->idTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->get();
                            }elseif($idType=='bus'){
                                $feepaid_details = DB::table('bus_transaction_details')
                                        ->join('northfeeheads','bus_transaction_details.idBusFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select('headerName','northfeeheads.amount','northfeeheads.discount','bus_transaction_details.amountPaid')
                                        ->where('bus_transaction_details.idBusTransaction','=',$transaction->idBusTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->get();
                            }elseif($idType=='hostel'){
                                $feepaid_details = DB::table('hostel_transaction_details')
                                        ->join('northfeeheads','hostel_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select('headerName','northfeeheads.amount','northfeeheads.discount','hostel_transaction_details.amountPaid')
                                        ->where('hostel_transaction_details.idHostelTransaction','=',$transaction->idHostelTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->get();
                            }
                            
                            if($idType=='fee'){
                            $feepaid = DB::table('student_transaction_details')
                                        ->join('northfeeheads','student_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->join('headers','northfeeheads.idHeader','=','headers.idHeader')
                                        ->select(DB::raw('SUM(student_transaction_details.amountPaid) as total'),DB::raw('SUM(student_transaction_details.discount) as discount'))
                                        ->where('student_transaction_details.idTransaction','=',$transaction->idTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->first(); 
                            }elseif($idType=='bus'){
                                $feepaid = DB::table('bus_transaction_details')
                                        ->join('northfeeheads','bus_transaction_details.idBusFeehead','=','northfeeheads.idFeehead')
                                        ->select(DB::raw('SUM(bus_transaction_details.amountPaid) as total'),DB::raw('SUM(bus_transaction_details.discount) as discount'))
                                        ->where('bus_transaction_details.idBusTransaction','=',$transaction->idBusTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->first();
                            }elseif($idType=='hostel'){
                                $feepaid = DB::table('hostel_transaction_details')
                                        ->join('northfeeheads','hostel_transaction_details.idFeehead','=','northfeeheads.idFeehead')
                                        ->select(DB::raw('SUM(hostel_transaction_details.amountPaid) as total'),DB::raw('SUM(hostel_transaction_details.discount) as discount'))
                                        ->where('hostel_transaction_details.idHostelTransaction','=',$transaction->idTransaction)
                                        ->where('northfeeheads.isParent','=',$det->idFeehead)
                                        ->first();
                            }       
                        ?>
                        <tr>
                            <th>{{$det->demandName}}</th>
                            <td><b>{{$det->amount}}</b></td>
                            <td><b>{{$feepaid->total}}</b></td>
                            <td><b>{{$feepaid->discount}}</b></td>
                            <td><b>0.00</b></td>
                        </tr>
                                @foreach($feepaid_details as $fd)
                                    <tr>
                                        <td>{{$fd->headerName}}</td>
                                        <td>{{$fd->amount}}</td>
                                        <td>{{$fd->amountPaid}}</td>
                                        <td>{{$fd->discount}}</td>
                                        <td>0.00</td>
                                    </tr>
                                @endforeach
                        @endforeach
                        

                        <tr>
                            <td colspan="2">Remarks: Fee Paid By  : <strong>{{$transaction->paymentMode}}</strong><br>
                                @if($transaction->paymentMode == 'Cheque' || $transaction->paymentMode =='DD')
                                Cheque/DD No. :  {{$transaction->chequeNo}}<br>
                                Cheque/DD Date : {{$transaction->chequeDate}}<br>
                                Bank Name : {{$transaction->bank->bankName or ''}}<br>
                                Amount : {{$transaction->totalPaid}}<br>
                                @endif
                                
                                <?php $excess  = \App\ExcessTransaction::where('idTransaction','=',$transaction->idTransaction)->first();?>
                                
                                <br>@if($excess) Excess Amount Paid :  {{$excess->excessAmount}}@endif
                            </td>
                            <td colspan="3">Fee Rs.: 
                                {{figToWord($transaction->totalPaid)}} <br> 
                            </td>
                        </tr>
                       
                    </tbody>
                </table>
            </div>
        </section>
    <htmlpagefooter name="page-footer" >
    </htmlpagefooter>

</body>
</html>

Copyright © 2021 - 2025 IMMREX7