

<div class="row">
    <div class="container">

        <ol class="breadcrumb">
            <li><a href="#"> مرتجع صرف مواد للمشروع</a></li>
            <li><a href="projectoperationControllerreturn.php?do=show">عرض مرتجع صرف مواد للمشروع </a></li>
            <li class="active">اضافة </li>
        </ol>


        <div class="panel panel-default panel-m">
            <div class="panel-heading">
                <h3 class="panel-title">اضافة مرتجع صرف مواد للمشروع</h3>
            </div>
            <div class="panel-body">

                <input type="hidden" name="searchvalue" id="searchvalue" value="{$Programsettingdata->searchvalue}"/>
                <input type="hidden" name="path" id="path" value="{$path}"/>
                <input name="storenegative" type="hidden" value="{$storenegative}" id="storenegative" />

                {literal}
                <form class="nameToBeChecked form-horizontal" role="form" id="projectoperation_form" action="projectoperationControllerreturn.php?do=add" method="post" >

                    {/literal}


                    <div class="row">
                        <div class="col-lg-8">
                            <div class="form-group">
                                <label class="col-lg-3 control-label">رقم التسلسل</label>
                                <div class="col-lg-4">
                                    <input type="text" name="serialno" id="serialno" class="form-control" placeholder="رقم التسلسل" value="{$serialno}" readonly="" >
                                </div>
                            </div>


                            <div class="form-group">
                                <label class="col-lg-3 control-label"> اسم المخزن</label>
                                <div class="col-lg-4">
                                    <select class="select2 wdt100" name="storeid" id="storeid" required>
                                        {foreach $storeData as $store}
                                        <option value="{$store->storeId}">{$store->storeName}</option>
                                        {/foreach}
                                    </select>
                                </div>
                            </div>

                            <div class="form-group">
                                <label class="col-lg-3 control-label"> المورد </label>
                                <div class="col-lg-4">
                                    <select class="select2 wdt100" name="supplierid" id="supplierid" >
                                        {foreach $supplierData as $supplier}
                                        <option value="{$supplier->supplierid}">{$supplier->suppliername}</option>
                                        {/foreach}
                                    </select>
                                </div>
                            </div>

                        </div>


                        <div class="col-lg-4">
                            <div class="form-group mg-bt5">
                                <label for="clientname" class="col-lg-4 control-label">اسم  المشروع</label>
                                <div class="col-lg-8">
                                    <input type="text" name="projectname" id="project_id"   class="select2product wdt100"  data-placeholder="اختر مشروع" required tabindex="301"/>
                                    <input type="hidden" id="edit_hiddenprojectId" name="edit_hiddenprojectId" value=""  />
                                    <input type="hidden" id="edit_hiddenprojectName" name="edit_hiddenprojectName" value=""  />

                                </div>
                            </div>
                            <!-- end of form-group-->

                        </div>

                        <div class="col-lg-4">
                            <div class="form-group mg-bt5" >
                                <label class="col-lg-4 control-label">تاريخ الفاتورة</label>
                                <div class="col-lg-8">
                                    <input type="text" class="form-control awdatepicker" autocomplete="off"  data-date-format="yyyy-mm-dd" placeholder="تاريخ الفاتورة" required value="{$today}" name="billdate" id="billdate">
                                </div>
                            </div>
                        </div>

                        <div class="col-lg-4">
                            <div class="form-group mg-bt5" >
                                <label class="col-lg-4 control-label">التعليق   </label>
                                <div class="col-lg-8" id="commentproject">
                                </div>
                            </div>
                        </div>
                    </div>


                    <div class="row">
                        <div class="row">
                            <hr/>
                            <div class="col-lg-6">
                                <h4>المنتجات</h4>
                            </div>
                            <div class="col-lg-6">
                                <button type="button" name="addpro_projectoperation" id="addpro_projectoperation" class="btn btn-primary pull-left ft-nor"> اضافة جديد</button>
                            </div>
                        </div>

                        <input type="hidden" name="offerhidden_itr" id="offerhidden_itr" value="1"/>
                        <input type="hidden" name="supervision_type" id="supervision_type" value="2"/>
                        <input type="hidden" name="supervision_amount" id="supervision_amount" value="0"/>
                        <input type="hidden" name="expensestypes" id="expensestypes" value="yes"/>
                        <!-- ======================================Table=============================================================================================== -->

                        <div class="table-responsive bd-gr">
                            <table class="table billtable table-bordered table-black" id="projectoperation_tb">
                                <thead>
                                    <tr>
                                        <th class="wdt120">اسم المنتج</th>
                                        <th class="wdt120"> العدد</th>
                                        <th class="wdt80">السعر</th>
                                        <th class="wdt100n"> الاجمالى</th>
                                        <th class="wdt300n"> نوع المصروف</th>
                                        <th class="wdt100n" id="supervisiontype"> النسبة</th>
                                        <th class="wdt100n"> الاشراف</th>
                                        <th>حذف</th>

                                    </tr>
                                </thead>
                                <tbody>
                                    <tr>
                                        <td style="width:500px;">
                                            <input type="text" name="projectproudctid1" id="project_proudctid1"  required  class="select2product wdt100 clas_offerproduct" data-itr='1'  data-placeholder="اختر منتج" tabindex="301"/>

                                        </td>

                                        <td>
                                            <input type="text" name="productnumber1" id="productnumber1"  required data-itr="1"  class="form-control txt-nonraduis positiveNo calcprice pro_num" value="1" />
                                            <input type="hidden" id="proquqntity1"/>
                                            <!-- <input type="hidden" id="probuyprice1"/> -->
                                        </td>
                                        <td>
                                          
                                            <input type="text" id="probuyprice1" name="probuyprice1"   class="txt-nonraduis pro_num" data-itr="1" />
                                        </td>
                                        <td>
                                             <input type="text" id="totalbuyprice1"  readonly="" class="txt-nonraduis"/>
                                        </td>
                                        <td style="width:200px;">
                                            <input type="text" name="expensestypeid1"   class="wdt100 expensetypeusers" data-itr="1" id="expensetypeuserid1" placeholder="اختر" />
                                            
                                        </td>
                                        <td>
                                            <input type="text" name="supervision_amount1"  data-itr="1"  class="wdt100 csupervisionamount" id="supervision_amount1" placeholder="" />
                                        </td>
                                        <td>
                                            <input type="text" name="supervision1"  data-itr="1"  class="wdt100 csupervision" id="supervision1" placeholder="الاشراف" />
                                        </td>


                                        <td>
                                           <!--  <input type="hidden" id="totalbuyprice1"/> -->
                                            <button type="button" id="remove1" class="projectoperation_remove close flt-none" aria-hidden="true"  >&times;</button>
                                        </td>
                                    </tr>
                                </tbody>
                            </table>
                        </div>
                    </div>
                    <div class="form-group">
                        <button type="button" class="btn btn-primary pull-left ft-nor">
                            اجمالى العدد <span class="badge wht-clo">
                                <div id="div_totalnumber">0</div>
                            </span>
                            <input type="hidden" name="totalpronumber" id="totalpronumber" value="0">
                            <input type="hidden" name="finaltotalprice" id="finaltotalprice" value="0"/>
                            <input type="hidden" name="finalsupervision" id="finalsupervision" value="0">

                        </button>
                        
                        
                    </div>
                    <div class="form-group">
                        <button type="button" class="btn btn-primary pull-left ft-nor">
                         الاجمالى <span class="badge wht-clo">
                                <div id="tfinaltotalprice">0</div>
                            </span>

                        </button>
                        
                        
                    </div>
                    <div class="form-group">
                        <button type="button" class="btn btn-primary pull-left ft-nor">
                            اجمالى الاشراف <span class="badge wht-clo">
                                <div id="tfinalsupervision">0</div>
                            </span>

                        </button>
                        
                        
                    </div>




                    <!-- =================================================   -->

                    <div class="form-group">
                        <div class="col-lg-offset-2 col-lg-4">
                            <input type="submit"   id="offerprice_save" class="btn btn-primary pull-left" value="حفظ">

                        </div>
                    </div>


                </form>
            </div>
        </div>




    </div>
</div>


<input type="hidden" name="searchvalue" id="searchvalue" value="{$Programsettingdata->searchvalue}"/>

<!--{literal}

<script type="text/javascript">
    var name = new Spry.Widget.ValidationTextField("name");
    var sprytextfield1 = new Spry.Widget.ValidationTextField("sprytextfield1", "real");
</script>

{/literal}-->

