<?php /* Smarty version Smarty-3.1.11, created on 2026-04-12 02:19:39
         compiled from "..\views\default\savedailyview\joined_many.html" */ ?>
<?php /*%%SmartyHeaderCode:1279869dae51b6aadc7-84226756%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '1616a311b2c70315f7b0f28a705c57509609c7cc' => 
    array (
      0 => '..\\views\\default\\savedailyview\\joined_many.html',
      1 => 1752437506,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '1279869dae51b6aadc7-84226756',
  'function' => 
  array (
  ),
  'variables' => 
  array (
    'lang_code' => 0,
    'youtubes' => 0,
    'saveData' => 0,
    'save' => 0,
    'usersData' => 0,
    'data' => 0,
    'savedailydate' => 0,
    'message' => 0,
    'dataArr' => 0,
    'netWritten' => 0,
  ),
  'has_nocache_code' => false,
  'version' => 'Smarty-3.1.11',
  'unifunc' => 'content_69dae51c394707_79272283',
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_69dae51c394707_79272283')) {function content_69dae51c394707_79272283($_smarty_tpl) {?><style>
    .myresult {
        -webkit-print-color-adjust: exact;
    }

    .nodata {
        background-color: #72B4EC;
        color: white;
        border-radius: 13px;
        margin: 14px;
        font-size: 24px;
        text-align: center;
        padding: 5px;
    }

    @media print {

        #ResultTable th,
        #ResultTable td {
            padding: 20px !important;
        }
    }
</style>

<div class="row">
    <div class="container <?php if ($_smarty_tpl->tpl_vars['lang_code']->value=='en'){?> gt4-ltr<?php }?>">
        <ol class="breadcrumb">
            <li><a href="#">التقارير</a></li>
            <li><a href="savedailyController.php?do=show">تقرير حركة للخزنه مجمع</a></li>
            <li class="active">عرض التقرير</li>
        </ol>
        <div class="panel panel-default panel-m">
            <!-- Default panel contents -->
            <div class="panel-heading">تقرير حركة للخزنه مجمع
                <a href="<?php echo $_smarty_tpl->tpl_vars['youtubes']->value[118]->url;?>
" target="_blank" class="hidden-print"><img
                        src="../views/default/assets/img/youtube.png" class="pull-left" alt="Youtube"
                        style="width: 2%;"></a>
            </div>
            <div class="panel-body">

                <form class="form-inline hidden-print " action="savedailyController.php?do=joined" method="post">

                    <div class="form-group">
                        <label class="sr-only">الخزنة</label>
                        <select class="select2 wdt300" name="saveId" id="saveid">
                            <option value="-1">اختر خزنة</option>
                            <?php  $_smarty_tpl->tpl_vars['save'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['save']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['saveData']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['save']->key => $_smarty_tpl->tpl_vars['save']->value){
$_smarty_tpl->tpl_vars['save']->_loop = true;
?>
                            <a href="show_ltr.html"></a>
                            <option value="<?php echo $_smarty_tpl->tpl_vars['save']->value['saveid'];?>
"><?php echo $_smarty_tpl->tpl_vars['save']->value['savename'];?>
</option>
                            <?php } ?>
                        </select>

                    </div>
                    <div class="form-group">
                        <label class="sr-only">المستخدم</label>
                        <select class="select2 wdt300" name="userId" id="userId">
                            <option value="-1"> اختر مستخدم </option>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['usersData']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <option value="<?php echo $_smarty_tpl->tpl_vars['data']->value->userid;?>
"><?php echo $_smarty_tpl->tpl_vars['data']->value->employeename;?>
</option>
                            <?php } ?>
                        </select>
                    </div>
                    <div class="form-group">
                        <label class="sr-only">خزن مجمعة </label>
                        <input type="checkbox" class="" name="mergeSaves" checked="checked" value="1">
                    </div>
                    <br />

                    <?php if ($_smarty_tpl->tpl_vars['savedailydate']->value==1){?>
                    <div id="dateTimeDiv">
                        <div class="form-group">
                            <label class="sr-only">من التاريخ</label>
                            <div class="input-group date form_datetime col-md-5" data-date=""
                                data-date-format="yyyy-mm-dd  h:i:s" data-link-field="dtp_input1">
                                <input class="form-control" size="16" type="text" value="" name="from" id="from"
                                    readonly="">
                                <span class="input-group-addon " style="width: 0%;"><span
                                        class=" glyphicon glyphicon-remove col-lg-4"></span></span>
                                <span class="input-group-addon" style="width: 0%;"><span
                                        class="glyphicon glyphicon-th col-lg-4"></span></span>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="sr-only">إلى التاريخ</label>
                            <div class="input-group date form_datetime col-md-5" data-date=""
                                data-date-format="yyyy-mm-dd  h:i:s" data-link-field="dtp_input1">
                                <input class="form-control" size="16" type="text" value="" name="to" id="to"
                                    readonly="">
                                <span class="input-group-addon " style="width: 0%;"><span
                                        class=" glyphicon glyphicon-remove col-lg-4"></span></span>
                                <span class="input-group-addon" style="width: 0%;"><span
                                        class="glyphicon glyphicon-th col-lg-4"></span></span>
                            </div>
                        </div>
                    </div>

                    <div id="dateOnlyDiv">
                        <div class="form-group">
                            <label class="sr-only">من التاريخ</label>
                            <input type="text" class="form-control awdatepicker" autocomplete="off"
                                data-date-format="yyyy-mm-dd" name="from">
                        </div>
                        <div class="form-group">
                            <label class="sr-only">إلى التاريخ</label>
                            <input type="text" class="form-control awdatepicker" autocomplete="off"
                                data-date-format="yyyy-mm-dd" name="to">
                        </div>
                    </div>

                    <div class="form-group">
                        <label class="sr-only">بحث بـ</label>
                        <div class="input-group">
                            <label> <input value="dateOnly" name="search" id="searchdateOnly" type="radio" checked
                                    onclick='localStorage.setItem("search", "dateOnly");
                                    window.location.reload();'>
                                تاريخ</label>
                            <label>
                                <input value="dateTime" name="search" id="searchdateTime" type="radio" onclick='localStorage.setItem("search", "dateTime");
                                        window.location.reload();'>
                                تاريخ ووقت</label>
                        </div>
                    </div>
                    <div class="clearfix"></div>
                    <button type="submit" class="btn btn-primary">بحث</button>
                </form>
                <?php }?>
            </div>

            <div class="clearfix"></div>
            <hr />
            <div class="panel panel-default panel-m">
                <div class="panel-heading"><?php echo $_smarty_tpl->tpl_vars['message']->value;?>
<br/>
                <span class="prntdat panel-heading" style="display: none;">تاريخ الطباعة:  <span class="panel-heading" id="printDate"></span></span>
                </div>

                <?php if (count($_smarty_tpl->tpl_vars['dataArr']->value)>0){?>
                <table class="table table-black" id="ResultTable">
                    <thead>
                        <tr style="text-align:center">
                            <th>البيان</th>
                            <th colspan="2">وارد نقدا</th>
                            <th colspan="2">منصرف نقدا</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">فواتير مبيعات نقديه </td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['payedSellBillVal'];?>
</td>
                            <?php }?>
                            <?php } ?>
                            <td colspan="2" rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
"></td>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['payedSellBillVal'];?>
</td>
                        </tr>
                        <?php }?>
                        <?php } ?>

                        <tr>
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">مصروفات </td>
                            <td colspan="2" rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
"></td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['expensesVal'];?>
</td>
                            <?php }?>
                            <?php } ?>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['expensesVal'];?>
</td>
                        </tr>
                        <?php }?>
                        <?php } ?>

                        <tr>
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">مرتجع بيع </td>
                            <td colspan="2" rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
"></td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['payedRetSellBillVal'];?>
</td>
                            <?php }?>
                            <?php } ?>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['payedRetSellBillVal'];?>
</td>
                        </tr>
                        <?php }?>
                        <?php } ?>

                        <tr>
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">دفعات سداد نقدا </td>
                            <td colspan="2" rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
"></td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['cashPayed'];?>
</td>
                            <?php }?>
                            <?php } ?>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['cashPayed'];?>
</td>
                        </tr>
                        <?php }?>
                        <?php } ?>
                        <tr>
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">دفعات تحصيل اجل </td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['laterPayed'];?>
</td>
                            <?php }?>
                            <?php } ?>
                            <td colspan="2" rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
"></td>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['laterPayed'];?>
</td>
                        </tr>
                        <?php }?>
                        <?php } ?>

                        <tr>
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">رصيد سابق بالخزينة </td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['valueFirstOfPeriod'];?>
</td>
                            <?php }?>
                            <?php } ?>
                            <td colspan="2" rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
"></td>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['valueFirstOfPeriod'];?>
</td>
                        </tr>
                        <?php }?>
                        <?php } ?>

                    </tbody>
                    <tfoot style="background-color:rgb(225, 226, 227)!important;">
                        <tr class="foot">
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">اجمالى الحركات</td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['totalIncome'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['totalEx'];?>
</td>
                            <?php }?>
                            <?php } ?>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['totalIncome'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                            <td><?php echo $_smarty_tpl->tpl_vars['data']->value['totalEx'];?>
</td>
                        </tr>
                        <?php }?>
                        <?php } ?>

                        <tr class="foot">
                            <td rowspan="<?php echo count($_smarty_tpl->tpl_vars['dataArr']->value);?>
">باقى بالخزينة</td>
                            <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                            <?php if ($_smarty_tpl->tpl_vars['data']->iteration==1){?>
                                <?php if ($_smarty_tpl->tpl_vars['data']->value['net']>=0){?>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['net'];?>
</td>
                                    <td></td>
                                    <td></td>
                                <?php }else{ ?>
                                    <td></td>
                                    <td></td>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['net'];?>
</td>
                                <?php }?>
                            <?php }?>
                            <?php } ?>
                        </tr>
                        <?php  $_smarty_tpl->tpl_vars['data'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['data']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['dataArr']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
 $_smarty_tpl->tpl_vars['data']->iteration=0;
foreach ($_from as $_smarty_tpl->tpl_vars['data']->key => $_smarty_tpl->tpl_vars['data']->value){
$_smarty_tpl->tpl_vars['data']->_loop = true;
 $_smarty_tpl->tpl_vars['data']->iteration++;
?>
                        <?php if ($_smarty_tpl->tpl_vars['data']->iteration>1){?>
                        <tr>
                            <?php if ($_smarty_tpl->tpl_vars['data']->value['net']>=0){?>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['net'];?>
</td>
                                    <td></td>
                                    <td></td>
                                <?php }else{ ?>
                                    <td></td>
                                    <td></td>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['savename'];?>
</td>
                                    <td><?php echo $_smarty_tpl->tpl_vars['data']->value['net'];?>
</td>
                                <?php }?>
                        </tr>
                        <?php }?>
                        <?php } ?>
                    </tfoot>
                </table>
                 <?php }else{ ?>
                لا يوجد بيانات
                <?php }?>
                <br />
                <!--class="panel-heading"-->
                <div style="font-size: 14px;"><?php echo $_smarty_tpl->tpl_vars['netWritten']->value;?>
</div>

                <div class="clearfix"></div>
                <hr />
                <div class="hidden-print ">
                    <div class="col-lg-12">
                        <div class="form-group">
                            <div class="col-lg-4">
                                <button type="button"  id="printData" class="btn btn-success pull-right">طباعة</button>
                            </div>
                        </div>
                    </div>
                    <div class="clearfix"></div>
                </div>




                <div class="clearfix"></div>

            </div>
        </div>
        <!--<input id="ddrt" name="ddrt" value="">-->
        
        <script>
            var search = localStorage.getItem("search");
            if (search == "dateTime") {
                $('#searchdateTime').attr('checked', 'checked');
                $('#searchdateOnly').removeAttr('checked');
                //
                $('#dateTimeDiv').show();
                $('#dateOnlyDiv').remove();
            } else {
                $('#searchdateOnly').attr('checked', 'checked');
                $('#searchdateTime').removeAttr('checked');
                //
                $('#dateOnlyDiv').show();
                $('#dateTimeDiv').remove();
            }
            var db = Number(localStorage.getItem("db"));
            if (db == 1) {
                $('#db').attr('checked', 'checked');
            } else {
                $('#db').removeAttr('checked');
            }
            
            $('#printData').on('click',function(){
                var dt = new Date();
                var month =1;
                month += Number(dt.getMonth()) ;
                var time = dt.getDate() +"-"+ month +"-"+ dt.getFullYear() +" "+ dt.getHours() + ":" + dt.getMinutes() + ":" + dt.getSeconds();
                $('#printDate').html(time);
                $('.prntdat').css('display','inline');
                print_Custom('mycustomheader');
                $('.prntdat').css('display','none');

            });
        </script>
        <?php }} ?>