

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

        <ol class="breadcrumb">
            <li><a href="#">المشروعات</a></li>
            <li><a href="projectController.php?do=show"> المشروعات</a></li>

        </ol>




        <div class="panel panel-default panel-m">
            <!-- Default panel contents -->
            <div class="panel-heading">المشروعات
                <a href="{$youtubes[240]->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">


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

            <form class="form-inline hidden-print" method="post" action="projectController.php?do=show">
                    
                     <div class="form-group"  >
                        <label class="sr-only">المشروعات</label>
                            <select class="select2 wdt100" name="projectid" id="projectid" >
                                <option value="-1" >اختر </option>
                                {foreach $alldata as $project}
                                <option value="{$project->id}">{$project->name}</option>
                                {/foreach}
                            </select>
                    </div>

                     {if $Programsettingdata->projectshownew eq 0} 
                    <div class="form-group" >
                         <label class="sr-only">انواع المشروعات</label>
                            <select class="select2 wdt100" name="projectkindid" id="projectkindid" >
                                <option value="-1">اختر</option>
                                {foreach $allprojectkind as $projectkind}
                                <option value="{$projectkind->projectkindid}">{$projectkind->projectkindname}</option>
                                {/foreach}
                            </select>
                    </div>
                    <div class="form-group" style="    margin-left: 30px;">
                        <label class="sr-only"> تم تصميم البانر </label>
                        <br>
                          <input type="radio"  name="bannerdesigned" value="1">
                          <label >نعم </label>
                          <input type="radio"  name="bannerdesigned" value="2">
                          <label >لا</label>
                    </div>
                    <div class="form-group">
                        <label class="sr-only"> حالة المشروع </label>
                        <br>
                          <input type="radio"  name="projectsuit" value="1">
                          <label >تم </label>
                          <input type="radio"  name="projectsuit" value="2">
                          <label >تحت التنفيذ</label>
                          <input type="radio"  name="projectsuit" value="3">
                          <label >لم يبدا بعد</label>
                    </div>
                    {/if} 
                   

                    <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>
                    <button type="submit" class="btn btn-primary hidden-print">بحث</button>
                </form>
            <hr/>



            <table class="table table-black">
                <thead>
                    <tr>
                        <th style="width:50px;">م</th>
                        <th>اسم المشروع</th>
                        {if $Programsettingdata->projectshownew == 0} 
                        <th>نوع المشروع</th>
                        <th>تم تصميم البانر</th>
                        <th>حالة المشروع</th>
                        <th>تاريخ الاضافه</th>
                        <th>تاريخ الانتهاء</th>
                       {/if} 
                        <th> اجمالى التعاقد</th>
                        <th class="noprint">تعديل</th>
                        <th class="noprint">انهاء</th>
                        <th class="noprint">حذف</th>
                    </tr>
                </thead>
                <tbody>



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

                    <tr {if $data->finish eq 1} class="danger" {/if}>

                        <td>{$i}</td>
                        <td>{$data->name}</td>
                        {if $Programsettingdata->projectshownew eq 0} 
                        <td>{$data->projectkindname}</td>
                        <td>{if $data->bannerdesigned == 1} نعم  {else if $data->bannerdesigned == 2}  لا {/if}</td>
                        <td>{if $data->projectsuit == 1} تم   {else if $data->projectsuit == 2}  تحت التنفيذ  {else if $data->projectsuit == 3} لم يبدا بعد {/if}</td>
                        <td>{$data->addeddate}</td>
                        <td>{$data->expirydate}</td>
                        {/if}
                        <td>{$data->totalcontract}</td>

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



                        <td class="noprint">
                            {if $data->finish eq 0}
                            <a href="#" name="dd" type="button" class="btn btn-default btn-lg deleteicon showfinishmsg" data-id="{$data->id}" data-go="projectController.php" ></a>
                            {else}
                            -----
                            {/if}
                        </td>

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

                            {else}
                            -----
                            {/if}
                        </td>



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


                </tbody>
            </table>





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


            <hr />

            <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" 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 -->





<!-- Modal -->
<div class="modal fade" id="finishsmall" 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 finishit">نعم</button>
            </div>
        </div><!-- /.modal-content -->
    </div><!-- /.modal-dialog -->
</div><!-- /.modal -->
