<?php if (isset($component)) { $__componentOriginalfcbcb094a4e25784fc05a845b0fe2686439b0eb5 = $component; } ?>
<?php $component = $__env->getContainer()->make(App\View\Components\AdminPanelLayout::class, []); ?>
<?php $component->withName('admin-panel-layout'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php $component->withAttributes([]); ?>
     <?php $__env->slot('title'); ?>
        لیست سفارشات لغو شده
     <?php $__env->endSlot(); ?>
     <?php $__env->slot('main'); ?>
        <!-- Checked checkbox -->
        <div class="content-header">
            <div class="container-fluid">
                <div class="row mb-2">
                    <div class="col-sm-6">
                        <h1 class="m-0 text-dark">لیست سفارشات لغو شده</h1>
                    </div><!-- /.col -->
                    <div class="col-sm-6">
                        <ol class="breadcrumb float-sm-left">

                            <li class="breadcrumb-item">مدیریت سفارشات خدمات</li>
                            <li class="breadcrumb-item active">لیست سفارشات لغو شده</li>
                        </ol>
                    </div><!-- /.col -->
                </div><!-- /.row -->
            </div><!-- /.container-fluid -->
        </div>
        <section class="content mt-sm-3">
            <div class="card">
                <div class="card-header">
                    <h3 class="card-title">سفارشات لغو شده</h3>
                </div>
                <!-- /.card-header -->
                <div class="card-body p-0">
                    <div class="alert alert-success col-md-11 mx-auto mt-2 d-none" role="alert" id="alertDelUser">
                        سفارش لغو شده با موفقیت حذف گردید
                    </div>
                    <form class="d-flex justify-content-around mt-3 mb-1" action="<?php echo e(route('users.index')); ?>">
                        <div class="form-row align-items-center">
                            <div class="col-4 my-1">
                                <select name="filter" class="custom-select mr-sm-2" id="inlineFormCustomSelect">
                                    <option selected hidden>بر اساس</option>
                                    <option value="id">آیدی</option>
                                </select>
                            </div>
                            <div class="col-4 my-1">
                                <input name="value" type="text" class="form-control" id="inlineFormInputName"
                                       placeholder="مقدار" value="<?php echo e(old('value',request()->value)); ?>">
                            </div>
                            <div class="col-auto my-1 col-4">
                                <button type="submit" class=" btn btn-outline-info">جستجو</button>
                            </div>
                        </div>
                    </form>

                    <div class="tableSection bg-light smSmall p-0 pr-sm-4 pl-sm-4 pt-sm-4 pb-0 table-responsive">
                        <table class="table table-striped text-center ">
                            <thead>
                            <tr>
                                <th scope="col">ردیف</th>
                                <th scope="col">کد رهگیری</th>
                                <th scope="col">درخواست دهنده</th>
                                <th scope="col">بررسی توسط</th>
                                <th scope="col">وضعیت</th>
                                <th scope="col">تاریخ ثبت</th>
                                <th scope="col">عملیات</th>
                            </tr>
                            </thead>
                            <tbody>
                            <?php $__currentLoopData = $cancelOrderServices; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $cancel): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <tr id="tr<?php echo e($cancel->id); ?>">
                                            <th scope="row" class="small"><?php echo e(++$loop->index); ?></th>
                                            <th scope="row" class="small"><?php echo e($cancel->order->code); ?></th>
                                            <th scope="row" class="small"><?php echo app('translator')->get($cancel->role); ?> <?php echo e($cancel->user->id); ?></th>
                                            <td class="small"><?php echo e($cancel->approved_by); ?></td>
                                            <td class="small <?php if($cancel->status == \Mehrab\OrderService\Models\CancelOrdersService::CONTINUE): ?> text-success <?php elseif($cancel->status == \Mehrab\OrderService\Models\CancelOrdersService::FINAL_APPROVAL): ?> text-danger <?php endif; ?>"><?php echo app('translator')->get($cancel->status); ?></td>
                                            <td class="small "><?php echo e($cancel->created_at); ?></td>
                                            <td class="d-flex justify-content-around">

                                                <?php if($cancel->order->operator_id == auth()->id() || $cancel->order->team_leader_id == auth()->id() || $cancel->order->expert_id == auth()->id() || auth()->user()->hasAnyPermission([\Mehrab\RolePermission\Models\Permission::PERMISSION_SUPER_ADMIN,\Mehrab\RolePermission\Models\Permission::PERMISSION_ACCESS_ALL_ORDER_SERVICE])): ?>
                                                <a class="btn btn-sm btn-primary"
                                                   href="<?php echo e(route('order_service.show',$cancel->order->id)); ?>" title="مشاهده">
                                                    <i class="fa fa-eye text-light"></i>
                                                </a>
                                                <?php endif; ?>
                                                <button class="btn btn-sm btn-info" onclick="set_report(<?php echo e($cancel->id); ?>)" data-toggle="modal" data-target="#report"
                                                   href="#" title="مشاهده گزارش">
                                                    <i class="fa fa-newspaper-o text-light"></i>
                                                </button>
                                                <input type="hidden" id="report_<?php echo e($cancel->id); ?>" value="<?php echo e($cancel->description); ?>">

                                            </td>
                                        </tr>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                            </tbody>
                        </table>
                    </div>
                    <?php echo e($cancelOrderServices->appends(request()->query())->links()); ?>

                </div>
                <!-- /.card-body -->
            </div>
            <!-- Modal -->
            <div class="modal fade" id="report" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true">
                <div class="modal-dialog modal-dialog-centered" role="document">
                    <div class="modal-content">
                        <div class="modal-header">
                            <h5 class="modal-title" id="exampleModalLongTitle">گزارش مربوطه</h5>
                            <button type="button" class="close ml-0" data-dismiss="modal" aria-label="Close">
                                <span aria-hidden="true">&times;</span>
                            </button>
                        </div>
                        <div class="modal-body">
                            <p id="report_body">

                            </p>
                        </div>
                        <div class="modal-footer">
                            <button type="button" class="btn btn-secondary" data-dismiss="modal">بستن</button>
                        </div>
                    </div>
                </div>
            </div>
        </section>
     <?php $__env->endSlot(); ?>
    <?php if(session()->get('status') == 'created'): ?>
         <?php $__env->slot('linkScript'); ?>
            <script>
                Swal.fire({
                    icon: 'success',
                    text: 'ایجاد سفارش با موفقیت انجام شد',
                })
            </script>
         <?php $__env->endSlot(); ?>
    <?php endif; ?>
    <?php if(session()->get('status') == 'updated'): ?>
         <?php $__env->slot('linkScript'); ?>
            <script>
                Swal.fire({
                    icon: 'success',
                    text: 'ویرایش سفارش با موفقیت انجام شد',
                })
            </script>
         <?php $__env->endSlot(); ?>
    <?php endif; ?>
 <?php if (isset($__componentOriginalfcbcb094a4e25784fc05a845b0fe2686439b0eb5)): ?>
<?php $component = $__componentOriginalfcbcb094a4e25784fc05a845b0fe2686439b0eb5; ?>
<?php unset($__componentOriginalfcbcb094a4e25784fc05a845b0fe2686439b0eb5); ?>
<?php endif; ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php /**PATH C:\wamp64\www\newer\Modules\Mehrab\OrderService\Providers/../Resources/Views//Admin/CancelOrders/list_cancel_order_services.blade.php ENDPATH**/ ?>
