<?php /* Smarty version Smarty-3.1.11, created on 2024-03-16 00:14:49
         compiled from "../views/default/productcardview/show.html" */ ?>
<?php /*%%SmartyHeaderCode:54806388765f4c85965da09-74532994%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '2f5322e8613f20634eb5bebcd6e6f024b759ec42' => 
    array (
      0 => '../views/default/productcardview/show.html',
      1 => 1693253994,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '54806388765f4c85965da09-74532994',
  'function' => 
  array (
  ),
  'variables' => 
  array (
    'youtubes' => 0,
    'Programsettingdata' => 0,
    'storeData' => 0,
    'store' => 0,
    'Usergroupdata' => 0,
    'storedetailData' => 0,
    'message' => 0,
    'quantityOfFirstPeriod' => 0,
    'productquantity' => 0,
    'totalStoreReportTypeOneData' => 0,
    'totalStoreReportTypeZeroData' => 0,
    'x' => 0,
    'storedetail' => 0,
  ),
  'has_nocache_code' => false,
  'version' => 'Smarty-3.1.11',
  'unifunc' => 'content_65f4c85976a255_43637729',
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_65f4c85976a255_43637729')) {function content_65f4c85976a255_43637729($_smarty_tpl) {?><style>
    .myresult {
        -webkit-print-color-adjust: exact;
    }
</style>

<div class="row">
    <div class="container">
        <ol class="breadcrumb">
            <li><a href="#">التقارير</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[73]->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="productcardController.php?do=show" method="post">
                    <input type="hidden" name="searchvalue" id="searchvalue" value="<?php echo $_smarty_tpl->tpl_vars['Programsettingdata']->value->searchvalue;?>
"/>
                    <div class="form-group">

                        <label class="sr-only" style="width:40px">المنتج</label>
                        <input type="hidden" class="select2product wdt300"  name="productId" id="productId" data-placeholder="اختر منتج"  />
                    </div>

                    <br/>

                    <div class="form-group">
                        <label class="sr-only">المخزن</label>
                        <select class="select2 wdt300"  name="storeId" id="storeId" >
                            <option value="-1">اختر مخزن</option>



                            <?php  $_smarty_tpl->tpl_vars['store'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['store']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['storeData']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['store']->key => $_smarty_tpl->tpl_vars['store']->value){
$_smarty_tpl->tpl_vars['store']->_loop = true;
?>




                            <option value="<?php echo $_smarty_tpl->tpl_vars['store']->value->storeId;?>
"><?php echo $_smarty_tpl->tpl_vars['store']->value->storeName;?>
</option>


                            <?php } ?>



                        </select>
                    </div>

                    <br/>
                    <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>

                    <br />


                    <?php if ($_smarty_tpl->tpl_vars['Usergroupdata']->value->hideBillPrices!=1){?>
                    <div class="form-group">
                        <label class="sr-only">نوع السعر</label>&nbsp;&nbsp;
                        <input name="productBuyPrice" type="checkbox" value="1" />&nbsp;
                        <label>شراء</label>
                        &nbsp;&nbsp;
                        <input name="productSellUnitPrice" type="checkbox" value="1" />&nbsp;<label>بيع</label>
                        &nbsp;&nbsp;

                        <input name="productSellAllPrice" type="checkbox" value="1" />&nbsp;<label>جمله</label>&nbsp;&nbsp;
                        <input name="productSellHalfPrice" type="checkbox" value="1" />&nbsp;<label>نصف جمله</label>&nbsp;&nbsp;
                    </div>
                    <br />
                    <?php }?>
                    <button type="submit" class="btn btn-primary">بحث</button>
                </form>
            </div>
            <?php ob_start();?><?php echo count($_smarty_tpl->tpl_vars['storedetailData']->value);?>
<?php $_tmp1=ob_get_clean();?><?php if ($_tmp1>0){?>
            <div class="panel panel-default panel-m">
                <!-- Default panel contents -->
                <div class="panel-heading">
                    <table class="table table-black">
                        <thead>
                            <tr>
                                <th>معلومات عن المنتج</th>
                                <th>رصيد اول مدة</th>
                                <th>الكمية الحالية</th>
                                <th>مجموع كل المنصرف</th>
                                <th>مجموع كل الوارد</th>
                            </tr>
                        </thead>

                        <tbody>
                            <tr>
                                <th><?php echo $_smarty_tpl->tpl_vars['message']->value;?>
</th>
                                <th><?php echo $_smarty_tpl->tpl_vars['quantityOfFirstPeriod']->value->productbefore;?>
</th>
                                <th><?php echo $_smarty_tpl->tpl_vars['productquantity']->value;?>
</th>
                                <th><?php echo $_smarty_tpl->tpl_vars['totalStoreReportTypeOneData']->value->productquantity;?>
</th>
                                <th><?php echo $_smarty_tpl->tpl_vars['totalStoreReportTypeZeroData']->value->productquantity;?>
</th>
                            </tr>
                        </tbody>

                    </table>

                </div>
                <div class="panel-body">
                    <hr/>
                    <?php ob_start();?><?php echo count($_smarty_tpl->tpl_vars['storedetailData']->value);?>
<?php $_tmp2=ob_get_clean();?><?php if ($_tmp2>0){?>

                    <?php }?>
                    <table class="table table-black">
                        <thead>
                            <tr>
                                <th>الرقم</th>
                                <th>التاريخ</th>
                                <th>البيان</th>
                                <th>المخزن</th>
                                <th>رصيد</th>
                                <th>الوارد</th>
                                <th>المنصرف</th>
                                <!--th>الملاحظات</th-->
                            </tr>
                        </thead>
                        <tbody>
                            <?php $_smarty_tpl->tpl_vars['x'] = new Smarty_variable(1, null, 0);?>
                            <?php  $_smarty_tpl->tpl_vars['storedetail'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['storedetail']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['storedetailData']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['storedetail']->key => $_smarty_tpl->tpl_vars['storedetail']->value){
$_smarty_tpl->tpl_vars['storedetail']->_loop = true;
?>
                            <tr>
                                <td><?php echo $_smarty_tpl->tpl_vars['x']->value;?>
</td>
                                <td><?php echo $_smarty_tpl->tpl_vars['storedetail']->value->storereportdate;?>
</td>
                                <td><?php echo $_smarty_tpl->tpl_vars['storedetail']->value->processname;?>
</td>




                                <td>
                                    <?php  $_smarty_tpl->tpl_vars['store'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['store']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['storeData']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['store']->key => $_smarty_tpl->tpl_vars['store']->value){
$_smarty_tpl->tpl_vars['store']->_loop = true;
?>
                                    <?php if ($_smarty_tpl->tpl_vars['store']->value->storeId==$_smarty_tpl->tpl_vars['storedetail']->value->storeid){?>
                                    <?php echo $_smarty_tpl->tpl_vars['store']->value->storeName;?>

                                    <?php }?>
                                    <?php } ?>
                                </td>


                                <td><?php echo $_smarty_tpl->tpl_vars['storedetail']->value->productbefore;?>
</td>
                                <td>
                                    <?php ob_start();?><?php echo $_smarty_tpl->tpl_vars['storedetail']->value->storereporttype;?>
<?php $_tmp3=ob_get_clean();?><?php if ($_tmp3==0){?>
                                    <?php echo $_smarty_tpl->tpl_vars['storedetail']->value->productquantity;?>

                                    <?php }?></td>
                                <td>
                                    <?php ob_start();?><?php echo $_smarty_tpl->tpl_vars['storedetail']->value->storereporttype;?>
<?php $_tmp4=ob_get_clean();?><?php if ($_tmp4==1){?>
                                    <?php echo $_smarty_tpl->tpl_vars['storedetail']->value->productquantity;?>

                                    <?php }?>
                                </td>

                            </tr>
                            <?php $_smarty_tpl->_capture_stack[0][] = array('default', 'x', null); ob_start(); ?><?php echo $_smarty_tpl->tpl_vars['x']->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>

                    <?php }?>
                    <div class="clearfix"></div>
                    <hr />
                    <?php ob_start();?><?php echo count($_smarty_tpl->tpl_vars['storedetailData']->value);?>
<?php $_tmp5=ob_get_clean();?><?php if ($_tmp5>0){?>
                    <div  class="noprint">
                        <div class="col-lg-12">
                            <div class="form-group">
                                <div class="col-lg-4">
                                    <button type="button" onclick="print_Custom('mycustomheader');" class="btn btn-success pull-right hidden-print">طباعة</button>
                                </div>
                            </div>
                        </div>
                        <div class="clearfix"></div>
                    </div>
                    <?php }?>
                    <div class="clearfix"></div>
                </div>
            </div>
        </div>
<?php }} ?>