
<div class="row">
    <div class="container">
        <ol class="breadcrumb">
            <li><a href="#">خصائص عامة</a></li>
            <li><a href="#">الموردين</a></li>
            <li class="active">معالجة عجز مورد</li>
        </ol>
        <div class="panel panel-default panel-m">
            <!-- Default panel contents -->
            <div class="panel-heading" style="padding:5px 15px 15px">
                <h3 class="panel-title" style="display: inline-block;">عرض معالجات عجز الموردين <br />
                    {if $message != ""}
                    {$message}
                    {/if}</h3>
                <a href="{$youtubes[10]->url}" target="_blank" class="hidden-print"><img src="../views/default/assets/img/youtube.png" class="pull-left" alt="Youtube" style="width: 2%;"></a>
                <a href="supplierDeficitController.php" class="hidden-print"><input type="button" style="margin-left: 12px" id="submit"  class="btn btn-primary pull-left " value="إضافة جديد"/></a>
            </div>

            <div class="panel-body">
                <form class="form-inline  hidden-print" action="supplierDeficitController.php?do=show" method="post">
                    <div class="form-group">
                        <label class="sr-only">اختر مورد</label>
                        <select data-placeholder="اختر مورد" class="select2 wdt100" name="supplierid" id="supplierid" onchange="this.form.submit();">
                            <option value="-1"></option>

                            {foreach $supplierSearchData as $supplierSearch}


                            <option value="{$supplierSearch->supplierid}">{$supplierSearch->suppliername}</option>


                            {/foreach}

                        </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" id="datepicker_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" id="datepicker_to" >
                    </div>

                    <button type="submit" class="btn btn-primary">بحث</button>
                </form>
            </div>
            <hr/>
            <table class="table table-black dataTableClass">
                <thead>
                    <tr>
                        <th>اسم المورد</th>
                        <th>اسم العملية</th>
                        <th>تاريخ العملية</th>
                        <th>الدين قبل</th>
                        <th>القيمة المتغيرة</th>
                        <th>الدين بعد</th>
                        <th>التعليق</th>
                        <th>المستخدم</th>
                    </tr>
                </thead>
                <tbody>

                    {foreach $supplierdebtchangeData as $supplierdebtchange}

                    {if {$supplierdebtchange->supplierdebtchangetype} eq 1}
                    <tr class="danger"> {elseif {$supplierdebtchange->supplierdebtchangetype} eq 0}

                    <tr> {/if}
                        <td>{$supplierdebtchange->suppliername}</td>
                        <td>{$supplierdebtchange->processname}</td>
                        <td>{$supplierdebtchange->supplierdebtchangedate}</td>
                        <td>{$supplierdebtchange->supplierdebtchangebefore}</td>
                        <td>{$supplierdebtchange->supplierdebtchangeamount}</td>
                        <td>{$supplierdebtchange->supplierdebtchangeafter}</td>
                        <td>{$supplierdebtchange->comment}</td>
                        <td>{$supplierdebtchange->employeename}</td>
                    </tr>

                    {/foreach}
                </tbody>

            </table>
            <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" onclick="print_Custom('mycustomheader');" class="btn btn-success pull-right">طباعة</button>
                        </div>
                    </div>
                </div>
                <div class="clearfix"></div>
            </div>
            <div class="clearfix"></div>
        </div>

    </div>
</div>
