<?php $__env->startSection('pageBreadcrumb'); ?> <?php echo $__env->make('layouts.includes.breadcrumb', ['moduleTitle' => __('Schools')], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> <?php $__env->stopSection(); ?>

<?php $__env->startSection('content'); ?>
    <div class="row __sms__datatable">
        <div class="col-md-12">
            <div class="card card-topline-aqua">
                <?php echo $__env->make('layouts.modules.header', ['actionAddNew' => route($moduleName.'.create'), 'title' => __('School').' '.__('List')], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
                <div class="card-body">
                    <div class="table-scrollable">
                        <table id="<?php echo e($moduleName); ?>-table"
                               class="display table table-checkable order-column valign-middle" style="width: 100%">
                            <thead>
                            <tr>
                                <th width="10%"> <?php echo e(__('saasuser::locale.logo')); ?></th>
                                <th width="20%"> <?php echo e(__('locale.name')); ?></th>
                                <th width="15%"> <?php echo e(__('saasuser::locale.domain_alias')); ?></th>
                                <th> <?php echo e(__('locale.address')); ?></th>
                                <th> <?php echo e(__('locale.status')); ?></th>
                                <th width="15%"> <?php echo e(__('locale.actions')); ?></th>
                            </tr>
                            </thead>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('scripts'); ?>

    <script>
        let columnsArray = [
            {data: 'logo', name: 'logo'},
            {data: 'name', name: 'name'},
            {data: 'domain_alias', name: 'domain_alias'},
            {data: 'address', name: 'address'},
            {data: 'status', name: 'status'},
            {data: 'action', name: 'action'}];
        let routeUrl = "<?php echo e(route($moduleName.'.index')); ?>";
        let tableRef = "<?php echo e($moduleName.'-table'); ?>";
        // Run the Datatable
        let table = __commonDatatableListing(tableRef, routeUrl, columnsArray);

        $(function () {
            $('#<?php echo e($moduleName); ?>-table tbody').on('click', 'tr', function (evt) {
                let href = $(this).find("a#view").attr('href');
                let $cell = $(evt.target).closest('td');
                if ($cell.index() != 4 && href) {
                    $(location).attr('href', href);

                }
            });
        });
    </script>
<?php $__env->stopSection(); ?>


<?php echo $__env->make('layouts.master', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /var/www/html/sms/app/Modules/Saasuser/Resources/Views/school/index.blade.php ENDPATH**/ ?>