
<style>
    @media print{
        tr > td ,tr > th{
            border: 1px solid black !important ;
        }
    }
</style>
<div class="row">
    <div class="container">

        <ol class="breadcrumb">
            <li><a href="#"> عروض الاسعار</a></li>
            <li><a href="priceoffersController.php?do=show">عروض الاسعار</a></li>
            <li class="active">عروض الاسعار </li>
        </ol>




        <div class="panel panel-default panel-m">
            <!-- Default panel contents -->
            <div class="panel-heading">عروض الاسعار</div>
            <div class="panel-body">


                <div id="outputString" class="alert alert-block alert-success fade in" style="display:none">
                    <button type="button" class="close pull-left" data-dismiss="alert" aria-hidden="true">&times;</button>

                    <p id="outputStringValue">{$outputString}</p>

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



            </div>
            <hr class="hidden-print"/>



            <table class="offersDataTableClass table-black">
                <thead>
                    <tr>
                        <th style="width:50px;">م</th>
                        <th>اسم  العميل</th>
                        <th> اجمالى الفاتورة</th>
                        <th class="noprint">تعديل</th>
                        <th class="noprint">حذف</th>

                    </tr>
                </thead>
                <tbody>



                    {assign var=i value=1}
                    {foreach $alldata as $data}

                    <tr>

                        <td>{$data->id}</td>
                        <td>{$data->clientName}</td>
                        <td>{$data->totalprice}</td>

                        <td class="noprint">
                            <a href="priceoffersController.php?do=edit&id={$data->id}" type="button" class="btn btn-default btn-lg editicon"></a>
                        </td>

                        <td class="noprint">
                            <a href="#" name="dd" type="button" class="btn btn-default btn-lg deleteicon showdeletemsg" data-id="{$data->id}" data-go="priceoffersController.php" ></a>

                        </td>



                    </tr>
                    {capture assign=i}{$i+1}{/capture}
                    {/foreach}


                </tbody>
            </table>





            <div class="clearfix"></div>
            <div class="col-lg-offset-8 col-lg-4" style="margin-top: 10px;" >
                <div class="well well-sm mytotal">
                    <h4 class="text-center" style="color: black !important;font-weight: 600;">الاجمالى  {$total_of_all}</h4>
                </div>
                <div class="well well-sm mytotal">
                    <h4 class="text-center" style="color: black !important;font-weight: 600;">{$arabic_num}</h4>
                </div>
            </div>

            <hr class="hidden-print" />

            <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">طباعة</button>
                        </div>
                    </div>

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






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


        </div>



    </div>

</div>



<!-- Modal -->
<div class="modal fade hidden-print" id="small" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content bg-modal">
            <div class="modal-header">
                <button type="button" class="close pull-left" data-dismiss="modal" aria-hidden="true">&times;</button>
                <h4 class="modal-title">تأكيد حذف هذا العرض</h4>
            </div>
            <div class="modal-body">
                <label>  هل تريد حذف هذا العرض؟</label>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">لا</button>
                <button type="button" class="btn btn-primary deleteit">نعم</button>
            </div>
        </div><!-- /.modal-content -->
    </div><!-- /.modal-dialog -->
</div><!-- /.modal -->

{literal}
<script>
    $('.offersDataTableClass').dataTable({
        "bPaginate": true,
        "bStateSave": true,
        aLengthMenu: [
            [10, 20, 50, 100, -1],
            [10, 20, 50, 100, "All"]
        ],
        iDisplayLength: -1,
        "sDom": 'TCR<"clear">lfrtip',
        "oTableTools": {
            "aButtons": [
                "copy",
                "print",
                {
                    "sExtends": "collection",
                    "sButtonText": "حفظ",
                    "aButtons": ["csv", "xls"]
                }
            ]
        }
    });
    $('.offersDataTableClass td').css("height", "30px");
</script>
{/literal}
