
<?php $__env->startSection('content'); ?>
<!-- ==================== Services Start ==================== -->
<section class="services py-80">
    <div class="container">
        <form action="<?php echo e(route('service.filter')); ?>" method="get">
            <div class="search-body">
                <div class="row gy-4">
                    <div class="col-lg-4">
                        <div>
                            <input type="text" class="form--control" name="search" placeholder="<?php echo app('translator')->get('Search by title'); ?>">
                        </div>
                    </div>
                    <div class="col-lg-4">
                        <select class="form-select form--control" name="category">
                            <option value=""><?php echo app('translator')->get('----select categories----'); ?></option>
                            <?php $__currentLoopData = $allCategories; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $category): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <option value="<?php echo e($category->id); ?>"><?php echo e(__($category->name)); ?></option>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

                        </select>
                    </div>
                    <div class="col-lg-4">
                        <div>
                            <button type="submit" class="btn btn--base w-100"><?php echo app('translator')->get('Search'); ?></button>
                        </div>
                    </div>
                </div>
            </div>
        </form>
        <div class="row gy-4">
            <?php $__currentLoopData = $categories; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <div class="col-12">
                <div class="accordion custom--accordion2" id="accordionExample">
                    <div class="accordion-item">
                        <h2 class="accordion-header" id="heading<?php echo e($loop->index); ?>">
                            <button class="accordion-button d-flex align-items-center <?php echo e($loop->index == 0 ? '' : 'collapsed'); ?>" type="button"
                                data-bs-toggle="collapse" data-bs-target="#collapse<?php echo e($loop->index); ?>" aria-expanded="<?php echo e($loop->index == 0 ? 'true': 'false'); ?>">
                                <img src="<?php echo e(getImage(getFilePath('category').'/'.@$item->logo)); ?>" class="icon" alt="<?php echo app('translator')->get('image'); ?>">
                                <?php if(strlen(__(@$item->name)) >40): ?>
                                <?php echo e(substr(__(@$item->name), 0,40).'...'); ?>

                                <?php else: ?>
                                <?php echo e(__(@$item->name)); ?>

                                <?php endif; ?>
                            </button>
                        </h2>
                        <div id="collapse<?php echo e($loop->index); ?>" class="accordion-collapse collapse <?php echo e($loop->index == 0 ? 'show': ''); ?>" aria-labelledby="heading<?php echo e($loop->index); ?>" data-bs-parent="#accordionExample">
                            <div class="accordion-body">
                                <div>
                                    <table class="custom-table">
                                        <thead>
                                            <tr>
                                                <th><?php echo app('translator')->get('ID'); ?></th>
                                                <th><?php echo app('translator')->get('Name'); ?></th>
                                                <th><?php echo app('translator')->get('Rate Per 1K'); ?></th>
                                                <th><?php echo app('translator')->get('Min'); ?></th>
                                                <th><?php echo app('translator')->get('Max'); ?></th>
                                                <th><?php echo app('translator')->get('Action'); ?></th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            <?php $__empty_1 = true; $__currentLoopData = $item->services??[]; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $value): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
                                            <tr>
                                                <td data-label="<?php echo app('translator')->get('ID'); ?>"><?php echo e($value->id); ?></td>
                                                <td data-label="<?php echo app('translator')->get('Name'); ?>" title="<?php echo e($value->name); ?>">
                                                    <?php if(strlen(__($value->name)) >20): ?>
                                                    <?php echo e(substr(__($value->name), 0,20).'...'); ?>

                                                    <?php else: ?>
                                                    <?php echo e(__($value->name)); ?>

                                                    <?php endif; ?>
                                                </td>
                                                <td data-label="<?php echo app('translator')->get('Rate Per 1K'); ?>"><?php echo e($general->cur_sym); ?><?php echo e(formatPrice($value->price)); ?></td>
                                                <td data-label="<?php echo app('translator')->get('Min'); ?>"><?php echo e($value->min); ?></td>
                                                <td data-label="<?php echo app('translator')->get('Max'); ?>"><?php echo e($value->max); ?></td>
                                                <td data-label="<?php echo app('translator')->get('Action'); ?>"><a href="<?php echo e(route('user.service.order',$value->id)); ?>" title="Order Now"><i class="fas fa-cart-arrow-down"></i></a></td>
                                            </tr>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
                                            <tr>
                                                <td class="text-muted text-center" colspan="100%"><?php echo e(__($emptyMessage)); ?></td>
                                            </tr>
                                            <?php endif; ?>
                                        </tbody>
                                    </table>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
        </div>
        <div class="row my-3">
            <div class="col-12">
                <?php if($categories->hasPages()): ?>
                <div class="py-4">
                    <?php echo e(paginateLinks($categories)); ?>

                </div>
                <?php endif; ?>
            </div>
        </div>
    </div>
</section>
<!-- ==================== Services End ==================== -->
<?php $__env->stopSection(); ?>


<?php echo $__env->make($activeTemplate.'layouts.frontend', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/webtechscom/public_html/smm.webtechs.com.ng/application/resources/views/presets/themeTwo/service/service.blade.php ENDPATH**/ ?>