<?php $__env->startSection('content'); ?>
<style>
    .report-capital.layout-print .table tr td {
        font-size: 14px !important;
    }
</style>
<div class="main-content-wrapper">
    <div class="main-box">
        <div class="main-content">
            <div class="container">
                <div class="page">
                    <div class="row">
                        <div class="report-capital layout-print">
                            <div class="header">
                                <div class="logo">
                                    <img src="<?php echo e(asset('assets/images/logo.png')); ?>" alt="" width="200px">
                                </div>
                                <div style="text-align: center;font-family: 'Khmer OS Muol Light'">
                                    <h2><?php echo e($branch->branch_kh); ?></h2>
									<h2><?php echo e($branch->branch_en); ?></h2>
                                    <h3>Voucher សក្ខីប័ត្រ</h3>
                                </div>
                                <div class="clear"></div>
                                <div class="border-bottom"></div>
                                <div class="voucher-header">
                                    <div class="voucher-header-title">
                                        <label for="">VOUCHER REF#: <?php echo e($data[0]->voucher_ref); ?></label>
                                        <label for="">DATE: <?php echo e(date('d M Y')); ?></label>
                                    </div>
                                </div>
                                <div class="voucher-box">
                                    <div class="voucher-box-left">
                                        <div class="voucher-purpose">
                                            <h5>Purpose of the transaction : គោលបំណងនៃប្រតិបត្តិការ</h5>
                                        </div>
                                        <div class="voucher-purpose-detail">
                                            <p><?php echo e($data[0]->journal_des); ?></p>
                                        </div>
                                    </div>
                                    <div class="voucher-box-right">
                                        <div class="voucher-type">
                                            <h5 class="voucher-title">Voucher Type : Tick ប្រភេទសក្ខីប័ត្រ</h5>
                                        </div>
                                        <div class="voucher-type-list">
                                            <ul class="voucher-list">
                                                <li><input type="checkbox" <?php echo ($data[0]->voucher_type == 1) ? "checked" : "" ?>><span>Cash​ Receipt លុយចូល</span></li>
                                                <li><input type="checkbox" <?php echo ($data[0]->voucher_type == 2) ? "checked" : "" ?>><span>Cash Disbursement លុយចេញ</span></li>
                                                <li><input type="checkbox" <?php echo ($data[0]->voucher_type == 3) ? "checked" : "" ?>><span>Cash Reimbursement ការទូទាត់ប្រាក់វិញ</span></li>
                                                <li><input type="checkbox" <?php echo ($data[0]->voucher_type == 4) ? "checked" : "" ?>><span>Cash Advance បុគ្គលិកយកលុយមុនដើម្បីប្រើប្រាស់</span></li>
                                                <li><input type="checkbox" <?php echo ($data[0]->voucher_type == 5) ? "checked" : "" ?>><span>Advance Settlement ការទូទាត់សាច់ប្រាក់ដែលបានយកមុន</span></li>
                                                <li><input type="checkbox" <?php echo ($data[0]->voucher_type == 6) ? "checked" : "" ?>><span>Journal Entry/Adjustment ការកែតម្រូវ</span></li>
                                            </ul>
                                        </div>
                                    </div>
                                </div>
                                <div class="table">
                                    <table>
                                        <thead>
                                            <tr>
                                                <th>DATE ថ្ងៃខែឆ្នាំ</th>
                                                <th>DESCRIPTION ឈ្មោះគណនី</th>
                                                <th>REF លេខយោង</th>
                                                <th>ACCOUNT # លេខគណន័យ</th>
                                                <th>DEBIT</th>
                                                <th>CREDIT</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            <?php
                                            $total_debit = 0;
                                            $total_credit = 0;
                                            ?>
                                            <?php $__currentLoopData = $data; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $list): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <?php
                                            $total_credit += $list->journal_credit;
                                            $total_debit += $list->journal_debit;
                                            ?>
                                            <tr>
                                                <td><?php echo e($list->journal_paydate); ?></td>
                                                <td><?php echo e($list->acc_name); ?> <?php echo e($list->acc_namekh); ?></td>
                                                <td><?php echo e($list->journal_invoice); ?></td>
                                                <td><?php echo e($list->journal_acccode); ?></td>
                                                <td><?php echo e($list->journal_debit); ?></td>
                                                <td><?php echo e($list->journal_credit); ?></td>
                                            </tr>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                            <tr class="no-border">
                                                <td colspan="4" class="no-border footer-text-right">TOTAL</td>
                                                <td class="double-bb footer-text-right"><?php echo e($total_debit); ?></td>
                                                <td class="double-bb footer-text-right"><?php echo e($total_credit); ?></td>
                                            </tr>
                                        </tbody>

                                    </table>
                                    <div class="make-date">
                                        <p>ធ្វើនៅ​ <strong>ភ្នំពេញ</strong> ថ្ងៃទី <strong><?php echo e(\Globals::date_khmers(date('d-m-Y'))); ?></strong></p>
                                    </div>
                                    <div class="row">
                                        <div class="col-lg-12 col-sm-12 col-xs-12 tt">
                                            <div class="col-lg-4 col-sm-4 col-xs-4">
                                                <p>អ្នកធ្វើបញ្ជី</p>
                                                <p>ថាយ ម៉ាណែល</p>
                                            </div>
                                            <div class="col-lg-4 col-sm-4 col-xs-4">
                                                <p>អ្នកពិនិត្យ</p>
                                                <p>_________________</p>
                                            </div>
                                            <div class="col-lg-4 col-sm-4 col-xs-4">
                                                <p>ឯកភាព</p>
                                                <p>ស៊ីន មុំ យ៉ែន សុខលីន</p>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<style>
    .container {
        width: 420mm !important;
        margin-top: 10px;
    }
    .voucher-box .voucher-box-left,
    .voucher-box-right {
        -webkit-box-flex: 1;
        -moz-box-flex: 1;
        -webkit-flex: 1;
        -ms-flex: 1;
        flex: 1;
    }

    .voucher-box {
        display: -webkit-box;
        display: -moz-box;
        display: -webkit-flexbox;
        display: -ms-flexbox;
        display: -webkit-flex;
        display: flex;
    }

    .voucher-box .voucher-box-left .voucher-purpose {
        height: 30px;
    }

    .voucher-box .voucher-box-left .voucher-purpose-detail {
        border: 1px solid #bbb;
        padding: 1em;
        height: calc(100% - 40px);
        border-right: none;
    }

    .voucher-box .voucher-box-right {
        border: 1px solid #bbb;
    }

    .voucher-box .voucher-box-right .voucher-type .voucher-title {
        padding-top: 10px;
        padding-bottom: 10px;
        text-align: center;
        font-weight: bolder;
    }

    .voucher-box .voucher-box-right .voucher-type-list input {
        width: 10%;
    }

    .voucher-box .voucher-box-right .voucher-type-list .voucher-list {
        padding: 0;
    }

    .footer-text-right {
        text-align: right;
        padding-right: 10% !important;
        font-size: 20px !important;
        font-weight: bold !important;
    }

    .no-border {
        border: none !important;
    }

    .double-bb {
        border-bottom-style: double !important;
        border-bottom-width: 3px !important;
    }

    .voucher-header {
        width: 100%;
    }

    .voucher-header .voucher-header-title {
        text-align: right;
        margin-bottom: 20px;
    }

    @media  print {

        html,
        body {
            width: 450mm !important;
            margin: 0mm 0 0 0 !important;
            background-color: #FFFFFF;
        }
        .voucher-box .voucher-box-left .voucher-purpose-detail {
            border: 1px solid #bbb;
            padding: 1em;
            height: calc(100% - 40px);
            border-right: none;
            height: 147px;
        }
    }
    @page{
        size: landscape !important;
    }

    
</style>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('layouts.print', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>