Viewing file: 871f9417596ff12db11867c597f2b0bc9a61f83a.php (13.27 KB) -rwxrwxr-x Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php $__env->startSection('title',trans('layout.tax_title')); ?>
<?php $__env->startSection('css'); ?>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('main-content'); ?> <div class="row page-titles mx-0"> <div class="col-sm-6 p-md-0"> <div class="welcome-text"> <h4><?php echo e(trans('layout.tax')); ?></h4> <p class="mb-0"></p> </div> </div> <div class="col-sm-6 p-md-0 justify-content-sm-end mt-2 mt-sm-0 d-flex"> <ol class="breadcrumb"> <li class="breadcrumb-item"><a href="#"><?php echo e(trans('layout.home')); ?></a></li> <li class="breadcrumb-item active"><a href="javascript:void(0)"><?php echo e(trans('layout.tax')); ?></a></li> </ol> </div> </div> <!-- row -->
<div class="row"> <div class="col-lg-12"> <div class="card"> <div class="card-header"> <h4 class="card-title"><?php echo e(trans('layout.list')); ?></h4> <div class="pull-right"> <button type="button" class="btn btn-sm btn-primary" data-toggle="modal" data-target="#taxCreateModal"> <?php echo e(trans('layout.create')); ?>
</button> </div> </div> <div class="card-body"> <div class="table-responsive"> <table class="table table-responsive-md"> <thead class="text-center"> <tr> <th><strong><?php echo e(trans('layout.title')); ?></strong></th> <th><strong><?php echo e(trans('layout.amount')); ?></strong></th> <th><strong><?php echo e(trans('layout.type')); ?></strong></th> <th><strong><?php echo e(trans('layout.status')); ?></strong></th> <th><strong><?php echo e(trans('layout.action')); ?></strong></th> </tr> </thead> <tbody class="text-center"> <?php if($taxes->isNotEmpty()): ?> <?php $__currentLoopData = $taxes; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $tax): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <tr> <td><?php echo e($tax->title); ?></td> <td><?php echo e($tax->amount); ?></td> <td><?php echo e($tax->type); ?></td> <td> <?php if($tax->status=='active'): ?> <span class="badge light badge-success"><?php echo e(trans('layout.active')); ?></span> <?php elseif($tax->status=='inactive'): ?> <span class="badge light badge-warning"><?php echo e(trans('layout.inactive')); ?></span> <?php endif; ?> </td> <td> <div class="dropdown"> <button type="button" class="btn btn-success light sharp" data-toggle="dropdown"> <svg width="20px" height="20px" viewBox="0 0 24 24" version="1.1"> <g stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"> <rect x="0" y="0" width="24" height="24"/> <circle fill="#000000" cx="5" cy="12" r="2"/> <circle fill="#000000" cx="12" cy="12" r="2"/> <circle fill="#000000" cx="19" cy="12" r="2"/> </g> </svg> </button> <div class="dropdown-menu"> <button class="dropdown-item edit_tax" type="button" data-id="<?php echo e($tax->id); ?>" data-title="<?php echo e($tax->title); ?>" data-type="<?php echo e($tax->type); ?>" data-amount="<?php echo e($tax->amount); ?>" data-status="<?php echo e($tax->status); ?>" data-action="<?php echo e(route('tax.update', $tax->id)); ?>" data-toggle="modal" data-target="#taxEditModal"> <?php echo e(trans('layout.edit')); ?>
</button> <button class="dropdown-item" type="button" data-message="<?php echo e(trans('layout.message.tax_delete_warning')); ?>" data-action='<?php echo e(route('tax.destroy',[$tax])); ?>' data-input={"_method":"delete"} data-toggle="modal" data-target="#modal-confirm"><?php echo e(trans('layout.delete')); ?></button> </div> </div> </td> </tr> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> <?php else: ?> <tr class="text-center"> <td colspan="5"><strong>No Data Available</strong></td> </tr> <?php endif; ?> </tbody> </table> </div> </div> </div> </div> </div>
<!-- Modal Create --> <?php $__env->startSection('create-modal-id', 'taxCreateModal'); ?> <?php $__env->startSection('create-modal-title', 'Tax Create'); ?> <?php $__env->startSection('create-modal-content-wapper'); ?> <form method="POST" action="<?php echo e(route('tax.store')); ?>"> <?php echo csrf_field(); ?> <div class="modal-body"> <div> <section> <div class="row">
<div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.title')); ?>*</label> <input value="<?php echo e(old('title')); ?>" type="text" name="title" class="form-control" placeholder="Ex: Tax-1" required> </div> </div> <div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.type')); ?>*</label> <select name="type" class="form-control"> <option value="flat"><?php echo e(trans('layout.flat')); ?></option> <option value="percentage"><?php echo e(trans('layout.percentage')); ?></option> </select> </div> </div>
<div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.amount')); ?>*</label> <input value="<?php echo e(old('amount')); ?>" type="text" name="amount" class="form-control" placeholder="Ex: 12" required> </div> </div>
<div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.status')); ?>*</label> <select name="status" class="form-control"> <option value="active"><?php echo e(trans('layout.active')); ?></option> <option value="inactive"><?php echo e(trans('layout.inactive')); ?></option> </select> </div> </div>
</div> </section> </div> </div>
<div class="modal-footer"> <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button> <button type="submit" class="btn btn-primary">Submit</button> </div> </form>
<?php $__env->stopSection(); ?>
<!-- Modal Edit --> <?php $__env->startSection('edit-modal-id', 'taxEditModal'); ?> <?php $__env->startSection('edit-modal-title', 'Tax Edit'); ?> <?php $__env->startSection('edit-modal-content-wapper'); ?> <form method="POST" id="taxFormUpdate"> <?php echo csrf_field(); ?> <?php echo method_field('PUT'); ?> <input type="hidden" name="id" id="edit-tax-id">
<div class="modal-body"> <div> <section> <div class="row">
<div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.title')); ?>*</label> <input value="<?php echo e(old('title')); ?>" type="text" name="title" id="edit-tax-title" class="form-control" placeholder="Ex: Tax-1" required> </div> </div> <div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.type')); ?>*</label> <select name="type" id="edit-tax-type" class="form-control"> <option value="flat"><?php echo e(trans('layout.flat')); ?></option> <option value="percentage"><?php echo e(trans('layout.percentage')); ?></option> </select> </div> </div>
<div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.amount')); ?>*</label> <input value="<?php echo e(old('amount')); ?>" type="text" name="amount" id="edit-tax-amount" class="form-control" placeholder="Ex: 12" required> </div> </div>
<div class="col-lg-6 mb-2"> <div class="form-group"> <label class="text-label"><?php echo e(trans('layout.status')); ?>*</label> <select name="status" id="edit-tax-status" class="form-control"> <option value="active"><?php echo e(trans('layout.active')); ?></option> <option value="inactive"><?php echo e(trans('layout.inactive')); ?></option> </select> </div> </div>
</div> </section> </div> </div>
<div class="modal-footer"> <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button> <button type="submit" class="btn btn-primary">Submit</button> </div> </form>
<?php $__env->stopSection(); ?>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('js'); ?> <script> $(document).on('click', '.edit_tax', function () { const id = $(this).data('id'); const title = $(this).data('title'); const type = $(this).data('type'); const amount = $(this).data('amount'); const status = $(this).data('status'); const action = $(this).data('action');
$('#edit-tax-id').val(id); $('#edit-tax-title').val(title); $('#edit-tax-type').val(type); $('#edit-tax-amount').val(amount); $('#edit-tax-status').val(status); $('#taxFormUpdate').attr('action', action);
$('#taxEditModal').modal('show'); });
</script>
<?php $__env->stopSection(); ?> <?php echo $__env->make('layouts.dashboard', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/picotech/domains/qr.picotech.app/public_html/resources/views/tax/index.blade.php ENDPATH**/ ?>
|