<?php /* Smarty version Smarty-3.1.11, created on 2025-01-28 21:02:50
         compiled from "../views/default/clientPayedDeptview/autoClientPremium.html" */ ?>
<?php /*%%SmartyHeaderCode:163816204679929da8af563-05995623%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '0aaa533ca7ac7102c747375ad2e777ac09dbe023' => 
    array (
      0 => '../views/default/clientPayedDeptview/autoClientPremium.html',
      1 => 1672089198,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '163816204679929da8af563-05995623',
  'function' => 
  array (
  ),
  'variables' => 
  array (
    'premiumData' => 0,
    'item' => 0,
    'i' => 0,
    'clientnegative' => 0,
    'total' => 0,
  ),
  'has_nocache_code' => false,
  'version' => 'Smarty-3.1.11',
  'unifunc' => 'content_679929da9775f4_91877707',
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_679929da9775f4_91877707')) {function content_679929da9775f4_91877707($_smarty_tpl) {?>
    <div class="col-lg-6">
        <h4><?php echo @PAYED_DEPT_BACK;?>
تفاصيل قسط العميل</h4>
    </div>

    <input type="hidden" name="premiumItr" id="premiumItr" value="1"/>

    <div class="table-responsive">
        <table class="table billtable table-bordered table-black " id="wasteTable">
            <thead>
            <tr>
                <th class="wdt300"> <?php echo @PAYED_DEPT_INSTALLMENTS_DATE;?>
</th>
                <th class="wdt300"><?php echo @PAYED_DEPT_VALUE;?>
</th>
                <th class="wdt300"><?php echo @PAYED_DEPT_WHAT_PAID;?>
</th>
                <th class="wdt300"><?php echo @PAYED_DEPT_RESIDUAL;?>
</th>
                <th class="wdt300"><?php echo @PAYED_DEPT_PAID_UP;?>
</th>
                <!--<th class="wdt50"></th>-->
            </tr>
            </thead>
            <tbody>
            <?php $_smarty_tpl->tpl_vars['i'] = new Smarty_variable(1, null, 0);?>
            <?php  $_smarty_tpl->tpl_vars['item'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['item']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['premiumData']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['item']->key => $_smarty_tpl->tpl_vars['item']->value){
$_smarty_tpl->tpl_vars['item']->_loop = true;
?>
            <?php ob_start();?><?php echo $_smarty_tpl->tpl_vars['item']->value->payed;?>
<?php $_tmp1=ob_get_clean();?><?php if ($_tmp1==1){?>
            <tr class="danger"> <?php }else{?><?php ob_start();?><?php echo $_smarty_tpl->tpl_vars['item']->value->payed;?>
<?php $_tmp2=ob_get_clean();?><?php if ($_tmp2==0){?>
            <tr data-itr="1">
                <?php }}?>

                <td>
                    <input type="text" class="form-control awdatepicker" value="<?php echo $_smarty_tpl->tpl_vars['item']->value->date;?>
" readonly autocomplete="off" data-date-format="yyyy-mm-dd" name="date1" id="date1">
                </td>
                <td>
                    <input type="number" name="Amount1" id="Amount1" min="0" class="form-control countAmount" value="<?php echo $_smarty_tpl->tpl_vars['item']->value->value;?>
" readonly />
                </td>
                <td>
                    <input type="number" name="Whatwaspaid" id="Whatwaspaid" min="0" class="form-control" value="<?php echo $_smarty_tpl->tpl_vars['item']->value->rest;?>
" readonly />
                </td>
                <td>
                    <input type="number" name="rest1" id="rest1" min="0" class="form-control " value="<?php echo $_smarty_tpl->tpl_vars['item']->value->value-$_smarty_tpl->tpl_vars['item']->value->rest;?>
" readonly />
                </td>
                <td class="hidden-print">
                    <input type="text"  <?php if ($_smarty_tpl->tpl_vars['i']->value!=1){?>disabled<?php }?> name="payedDeptCurr" id="payedDeptCurr" value="0"
                           onKeyUp="populateDebtAfter('payedDeptCurr');"
                           class="form-control premiumpayedDeptCurr <?php if ($_smarty_tpl->tpl_vars['clientnegative']->value==1){?>numberinput<?php }else{ ?>positivefloat<?php }?>"
                           placeholder="<?php echo @PAYED_DEPT_PAID_UP;?>
"/>
                    <input type="hidden" name="premiumid" id="premiumid" value="<?php echo $_smarty_tpl->tpl_vars['item']->value->id;?>
"  <?php if ($_smarty_tpl->tpl_vars['i']->value!=1){?>disabled<?php }?>/>
                    <input type="hidden" name="premiumDetailId" id="premiumDetailId" value="<?php echo $_smarty_tpl->tpl_vars['item']->value->premiumclientId;?>
"  <?php if ($_smarty_tpl->tpl_vars['i']->value!=1){?>disabled<?php }?>/>
                    <input type="hidden" name="payedDept" id="payedDept" <?php if ($_smarty_tpl->tpl_vars['i']->value!=1){?>disabled<?php }?>
                           onKeyUp="populateDebtAfter('payedDept');"
                           class="premiumpayedDept <?php if ($_smarty_tpl->tpl_vars['clientnegative']->value==1){?>numberinput<?php }else{ ?>positivefloat<?php }?> form-control"  />
                </td>

            </tr>
            <?php $_smarty_tpl->_capture_stack[0][] = array('default', 'i', null); ob_start(); ?><?php echo $_smarty_tpl->tpl_vars['i']->value+1;?>
<?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]);
if (!empty($_capture_buffer)) {
 if (isset($_capture_assign)) $_smarty_tpl->assign($_capture_assign, ob_get_contents());
 if (isset( $_capture_append)) $_smarty_tpl->append( $_capture_append, ob_get_contents());
 Smarty::$_smarty_vars['capture'][$_capture_buffer]=ob_get_clean();
} else $_smarty_tpl->capture_error();?>
            <?php } ?>
            </tbody>
        </table>

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

        <div class="row">
            <div class="col-lg-12">
                <button type="button" class="btn btn-dark pull-left ft-nor">
                    <?php echo @PAYED_DEPT_INSTALLMENTS_TOTAL;?>
 <span class="badge wht-clo">
                                    <div id='allCost'><?php echo $_smarty_tpl->tpl_vars['total']->value;?>
</div>
                                </span>
                </button>
            </div>
        </div>
    </div>


<?php }} ?>