<?php $__env->startSection('title','Books'); ?>
<?php echo $__env->make('layouts.datatable', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
<?php $__env->startSection('content'); ?>
<div class="row">
    <div class="col-lg-12">
        <div class="tile">
            <div class="tile-title-w-btn">
                <h3 class="title"><i class="bi bi-list-ul"></i> <?php echo e(__('lang.books')); ?></h3>
                <?php if (app(\Illuminate\Contracts\Auth\Access\Gate::class)->check('books.create')): ?>
                <a href="<?php echo e(route('books.create')); ?>" class="btn btn-primary" title="<?php echo e(__('lang.new_book')); ?>">
                    <i class='bi bi-plus'></i>
                </a>
                <?php endif; ?>
            </div>
            <div class="tile-body">
                <div class="table-responsive">
                    <table class="table table-bordered" id="my-table">
                        <thead class="table-primary">
                            <tr>
                                <th>#</th>
                                <th><?php echo e(__('lang.title')); ?></th>
                                <th><?php echo e(__('lang.category')); ?></th>
                                <th><?php echo e(__('lang.location')); ?></th>
                                <th><?php echo e(__('lang.language')); ?></th>
                                <th><?php echo e(__('lang.author')); ?></th>
                                <th><?php echo e(__('lang.translator')); ?></th>
                                <th><?php echo e(__('lang.publisher')); ?></th>
                                <th><?php echo e(__('lang.isbn')); ?></th>
                                <th><?php echo e(__('lang.price')); ?></th>
                                <th><?php echo e(__('lang.total_qty')); ?></th>
                                <th><?php echo e(__('lang.available_qty')); ?></th>
                                <th><?php echo e(__('lang.action')); ?></th>
                            </tr>
                        </thead>
                        <tbody>
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
<?php $__env->stopSection(); ?>

<?php $__env->startPush('scripts'); ?>

<script type="text/javascript">
    new DataTable('#my-table', {
        processing: true,
        serverSide: true,
        "ordering": false,
        ajax: {
            url: '<?php echo e(route('books.dataTable')); ?>',
        },
        columns: [
            { data: 'id', name: 'id' },
            { data: 'title', name: 'title' },
            { data: 'category', name: 'category' },
            { data: 'location', name: 'location' },
            { data: 'language', name: 'language' },
            { data: 'author', name: 'author' },
            { data: 'translator', name: 'translator' },
            { data: 'publisher', name: 'publisher' },
            { data: 'isbn', name: 'isbn' },
            { data: 'price', name: 'price' },
            { data: 'qty', name: 'qty' },
            { data: 'available_qty', name: 'available_qty' },
            { data: 'action', name: 'action', searchable: false }
        ],
    });

</script>
<?php $__env->stopPush(); ?>
<?php echo $__env->make('layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /var/www/resources/views/book/index.blade.php ENDPATH**/ ?>