<!--**********************************Table expense Start***********************************-->
<div class="tab-pane fade" id="Pending" role="tabpanel" aria-labelledby="Pending-tab">
    <table class="table card-table display mb-4 dataTablesCard text-black text-center" id="example4">
                <thead>
                    <tr>

                        <tr>
                            <th>رقم القسيمة</th>
                            <th>العميل</th>
                            <th>الكمية</th>
                            <th>النوع</th>
                            <th>الحالة</th>
                            <th>العمليات</th>
                            </tr>
                        </thead>
                        <tbody>
                            <?php if(isset($coupons)): ?>
                                <?php $__currentLoopData = $coupons; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $coupon): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                <?php if($coupon->status == 1): ?>
                                <tr>
                                    <td><span>00000<?php echo e($coupon->id); ?>#</span></td>
                                    <td><span class="text-nowrap"><a href="<?php echo e(route('clintCoupons',$coupon->clint_id)); ?>"><?php echo e($coupon->clint->name); ?></a></span></td>
                                    <td><span><?php echo e($coupon->quantity . ' لتر'); ?></span></td>
                                    <td><span class="text-nowrap">
                                        <?php if(isset($coupon->type)): ?>
                                            <?php if($coupon->type==0): ?>
                                                بترول
                                            <?php else: ?>
                                                ديزل
                                            <?php endif; ?>
                                        <?php endif; ?>
                                    </span>
                                </td>
                        <?php if($coupon->status == 0): ?>
                        <td><span class="badge badge-dark light">غير مطبوعة</span></td>
                        <td>
                            <div class="dropdown dropstart">
                                <a href="javascript:void(0);" class="btn-link" data-bs-toggle="dropdown" aria-expanded="false">
                                    <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
                                        <path d="M12 13C12.5523 13 13 12.5523 13 12C13 11.4477 12.5523 11 12 11C11.4477 11 11 11.4477 11 12C11 12.5523 11.4477 13 12 13Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 6C12.5523 6 13 5.55228 13 5C13 4.44772 12.5523 4 12 4C11.4477 4 11 4.44772 11 5C11 5.55228 11.4477 6 12 6Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 20C12.5523 20 13 19.5523 13 19C13 18.4477 12.5523 18 12 18C11.4477 18 11 18.4477 11 19C11 19.5523 11.4477 20 12 20Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                    </svg>
                                </a>
                                <div class="dropdown-menu">
                                    <button type="button"  value=""
                                        <?php $__currentLoopData = $registries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $registry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <?php if($coupon->id == $registry->operation_id): ?>
                                                data-id="<?php echo e($registry->operation_id); ?>"
                                            <?php endif; ?>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                        class="registry update dropdown-item"
                                        href="update"><i class="bi bi-pencil-square text-success ms-3"></i>
                                        سجل العمليات
                                    </button>
                                    <a class="dropdown-item" href="<?php echo e(route('printCoupon',$coupon->id)); ?>"><i class="las la-print  scale5 ms-3"></i>طباعة</a>
                                    <button type="button"  value="" data-id="<?php echo e($coupon->id); ?>"
                                        data-status="<?php echo e($coupon->status); ?>" data-title="القسيمة"
                                        data-route='<?php echo e(route('updateCoupon')); ?>'
                                        data-accounter_id="<?php echo e($coupon->accountant_id); ?>"
                                        data-sender_name="<?php echo e($coupon->clint->name); ?>"
                                        data-quantity="<?php echo e($coupon->quantity); ?>"
                                        data-type="<?php echo e($coupon->type); ?>" class=" edit update dropdown-item"
                                        href="update"><i class="bi bi-pencil-square text-success ms-3"></i>
                                        تعديل
                                    </button>
                                </div>
                            </div>
                        </td>
                        <?php elseif($coupon->status == 1): ?>
                        <td><span class="badge badge-warning light">مصروفة</span></td>
                        <td>
                            <div class="dropdown dropstart">
                                <a href="javascript:void(0);" class="btn-link" data-bs-toggle="dropdown" aria-expanded="false">
                                    <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
                                        <path d="M12 13C12.5523 13 13 12.5523 13 12C13 11.4477 12.5523 11 12 11C11.4477 11 11 11.4477 11 12C11 12.5523 11.4477 13 12 13Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 6C12.5523 6 13 5.55228 13 5C13 4.44772 12.5523 4 12 4C11.4477 4 11 4.44772 11 5C11 5.55228 11.4477 6 12 6Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 20C12.5523 20 13 19.5523 13 19C13 18.4477 12.5523 18 12 18C11.4477 18 11 18.4477 11 19C11 19.5523 11.4477 20 12 20Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                    </svg>
                                </a>
                                <div class="dropdown-menu">
                                    <button type="button"  value=""
                                        <?php $__currentLoopData = $registries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $registry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <?php if($coupon->id == $registry->operation_id): ?>
                                                data-id="<?php echo e($registry->operation_id); ?>"
                                            <?php endif; ?>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                        class="registry update dropdown-item"
                                        href="update"><i class="bi bi-pencil-square text-success ms-3"></i>
                                        سجل العمليات
                                    </button>
                                    <button type="button" value="" data-id="<?php echo e($coupon->id); ?>"
                                        data-is_active="<?php echo e($coupon->status); ?>" data-title="القسيمة"
                                        data-route='<?php echo e(route('cancelClintCoupon',$coupon->id)); ?>' class="toggle dropdown-item"
                                        href="toggle "><i
                                            class="las las la-times-circle text-danger scale5 ms-3"></i>
                                        تعليق
                                    </button>
                                    
                                    <a class="dropdown-item" href="<?php echo e(route('showClintCoupon',$coupon->id)); ?>"><i class="las la-info-circle scale5 ms-3"></i>عرض</a>
                                </div>
                            </div>
                        </td>
                        <?php elseif($coupon->status == 2): ?>
                        <td><span class="badge badge-success light">مستلمة</span></td>
                        <td>
                            <div class="dropdown dropstart">
                                <a href="javascript:void(0);" class="btn-link" data-bs-toggle="dropdown" aria-expanded="false">
                                    <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
                                        <path d="M12 13C12.5523 13 13 12.5523 13 12C13 11.4477 12.5523 11 12 11C11.4477 11 11 11.4477 11 12C11 12.5523 11.4477 13 12 13Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 6C12.5523 6 13 5.55228 13 5C13 4.44772 12.5523 4 12 4C11.4477 4 11 4.44772 11 5C11 5.55228 11.4477 6 12 6Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 20C12.5523 20 13 19.5523 13 19C13 18.4477 12.5523 18 12 18C11.4477 18 11 18.4477 11 19C11 19.5523 11.4477 20 12 20Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                    </svg>
                                </a>
                                <div class="dropdown-menu">
                                    <button type="button"  value=""
                                        <?php $__currentLoopData = $registries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $registry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <?php if($coupon->id == $registry->operation_id): ?>
                                                data-id="<?php echo e($registry->operation_id); ?>"
                                            <?php endif; ?>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                        class="registry update dropdown-item"
                                        href="update"><i class="bi bi-pencil-square text-success ms-3"></i>
                                        سجل العمليات
                                    </button>
                                    <a class="dropdown-item" href="<?php echo e(route('showClintCoupon',$coupon->id)); ?>"><i class="las la-info-circle scale5 ms-3"></i>عرض</a>
                                    <a class="dropdown-item" href="<?php echo e(route('printSpentOfOneCoupon',$coupon->id)); ?>"><i class="las la-print scale5 ms-3"></i>طباعة سند الاستلام</a>
                                </div>
                            </div>
                        </td>
                        <?php elseif($coupon->status == 3): ?>
                        <td><span class="badge badge-danger light">معلقة من المدير</span></td>
                        <td>
                            <div class="dropdown dropstart">
                                <a href="javascript:void(0);" class="btn-link" data-bs-toggle="dropdown" aria-expanded="false">
                                    <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
                                        <path d="M12 13C12.5523 13 13 12.5523 13 12C13 11.4477 12.5523 11 12 11C11.4477 11 11 11.4477 11 12C11 12.5523 11.4477 13 12 13Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 6C12.5523 6 13 5.55228 13 5C13 4.44772 12.5523 4 12 4C11.4477 4 11 4.44772 11 5C11 5.55228 11.4477 6 12 6Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                        <path d="M12 20C12.5523 20 13 19.5523 13 19C13 18.4477 12.5523 18 12 18C11.4477 18 11 18.4477 11 19C11 19.5523 11.4477 20 12 20Z" stroke="#575757" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path>
                                    </svg>
                                </a>
                                <div class="dropdown-menu">
                                    <button type="button"  value=""
                                        <?php $__currentLoopData = $registries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $registry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <?php if($coupon->id == $registry->operation_id): ?>
                                                data-id="<?php echo e($registry->operation_id); ?>"
                                            <?php endif; ?>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                        class="registry update dropdown-item"
                                        href="update"><i class="bi bi-pencil-square text-success ms-3"></i>
                                        سجل العمليات
                                    </button>
                                    <button type="button" value="" data-id="<?php echo e($coupon->id); ?>"
                                        data-is_active="-1" data-title="القسمة"
                                        data-route='<?php echo e(route('activeCoupon',$coupon->id)); ?>'
                                        class="toggle dropdown-item" href="toggle "><i
                                            class="las la-check-circle text-success scale5 ms-3"></i>تفعيل
                                    </button>
                                    
                                    <a class="dropdown-item" href="<?php echo e(route('showClintCoupon',$coupon->id)); ?>"><i class="las la-info-circle scale5 ms-3"></i>عرض</a>
                                </div>
                            </div>
                        </td>
                        <?php endif; ?>


                    </tr>
                    <?php endif; ?>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                    <?php endif; ?>











                </tbody>
            </table>
    </div>
    <!--**********************************Table expense End***********************************-->
<?php /**PATH C:\Users\Nasser\Desktop\petrol_store\resources\views/coupons/tables/expense.blade.php ENDPATH**/ ?>