ok
Direktori : /home2/selectio/www/wedding-info-new/admin/ |
Current File : /home2/selectio/www/wedding-info-new/admin/employee_details.php |
<?php include('header.php'); ?> <link rel="stylesheet" href="https://cdn.datatables.net/1.13.7/css/dataTables.bootstrap5.min.css"> <link rel="stylesheet" href="https://cdn.datatables.net/buttons/2.4.2/css/buttons.bootstrap5.min.css"> <div class="page-wrapper"> <div class="page-content"> <div class="card"> <div class="card-body"> <div class="table-responsive"> <table id="example9" class="table table-striped table-bordered" style="width:100%"> <thead> <tr> <th> ID</th> <th> Employer Category</th> <th> Position</th> <th> Site</th> <th> Designation</th> <th> Phone</th> <th> Join Date</th> <th> First Name</th> <th> Middle Name</th> <th> Last Name</th> <th> Date of Birth</th> <th> Age</th> <th> Gender</th> <th> Blood Type</th> <th> Marital Status</th> <th> PAN</th> <th> Religion</th> <th> Aadhar Number</th> <th> Office Email</th> <th> Personal Email</th> <th> Bank Name</th> <th> Bank Account</th> <th> Emergency Contact Name</th> <th> Emergency Contact Adddress</th> <th> Relation</th> <th> Emergency Contact Phone </th> <th>Status</th> <th>Action</th> <th>Verified Status</th> </tr> </thead> <tbody> </tbody> <tfoot> <tr> <th> ID</th> <th> Employer Category</th> <th> Position</th> <th> Site</th> <th> Designation</th> <th> Phone</th> <th> Join Date</th> <th> First Name</th> <th> Middle Name</th> <th> Last Name</th> <th> Date of Birth</th> <th> Age</th> <th> Gender</th> <th> Blood Type</th> <th> Marital Status</th> <th> PAN</th> <th> Religion</th> <th> Aadhar Number</th> <th> Office Email</th> <th> Personal Email</th> <th> Bank Name</th> <th> Bank Account</th> <th> Emergency Contact Name</th> <th> Emergency Contact Adddress</th> <th> Relation</th> <th> Emergency Contact Phone </th> <th>Status</th> <th>Action</th> <th>Verified Status</th> </tr> </tfoot> </table> </div> </div> </div> </div> </div> <script src="https://code.jquery.com/jquery-3.7.0.js"></script> <script src="https://cdn.datatables.net/1.13.7/js/jquery.dataTables.min.js"></script> <script src="https://cdn.datatables.net/1.13.7/js/dataTables.bootstrap5.min.js"></script> <script src="https://cdn.datatables.net/buttons/2.4.2/js/dataTables.buttons.min.js"></script> <script src="https://cdn.datatables.net/buttons/2.4.2/js/buttons.bootstrap5.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.10.1/jszip.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/pdfmake.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/vfs_fonts.js"></script> <script> function delete_branch(id) { var result = confirm("Confirm want to delete this File Details?"); if (result) { $.ajax({ type: 'POST', url: 'api/delete.php', data: { type: 'delete_branch', delete_id: id }, success: function(response) { console.log(response); getDatas(); } }); } } function getDatas() { // var banks = $('#banks').val(); var dataTable = $('#example9').DataTable({ "processing": true, "order": [ [0, 'asc'] ], "serverSide": true, "destroy": true, "ajax": { url: "data-tables/employee/employee-datatable.php", // json datasource data: { type: 'get_customer_table', // banks: banks }, type: "post", // method , by default get error: function() { // error handling $(".example9-error").html(""); $("#example9").append('<tbody class="example9-error"><tr><th colspan="3">No data found in the server</th></tr></tbody>'); $("#example9_processing").css("display", "none"); } } }); } $(document).ready(function() { getData(); function getData() { // var banks = $('#banks').val(); var dataTable = $('#example9').DataTable({ "processing": true, "order": [ [0, 'asc'] ], "serverSide": true, "destroy": true, dom: 'Bfrtip', lengthMenu: [ [10, 25, 50, -1], ['10 rows', '25 rows', '50 rows', 'Show all'] ], buttons: [ { extend: 'pageLength', className: 'btn-sm' }, { extend: 'copyHtml5', className: 'btn-sm', exportOptions: { columns: ':visible' } }, { extend: 'excelHtml5', className: 'btn-sm', exportOptions: { columns: ':visible' } }, { extend: 'csvHtml5', className: 'btn-sm', orientation: 'landscape', pageSize: 'LEGAL', exportOptions: { columns: ':visible' } }, { extend: 'pdfHtml5', className: 'btn-sm', orientation: 'landscape', pageSize: 'LEGAL', exportOptions: { columns: ':visible' } }, { extend: 'colvis', className: 'btn-sm' } ], "ajax": { url: "data-tables/employee-datatable.php", // json datasource data: { type: 'get_customer_table', // banks: banks }, type: "post", // method , by default get error: function() { // error handling $(".example9-error").html(""); $("#example9").append('<tbody class="example9-error"><tr><th colspan="3">No data found in the server</th></tr></tbody>'); $("#example9_processing").css("display", "none"); } } }); } $('#banks').change(function() { getData(); }); }); </script> <!--alliance-list-data-table.php--> <?php include('footer.php'); ?> <script> function disable(id) { alert('hello' + id); $.ajax({ type: 'GET', data: { id: id }, // Correct syntax for passing data url: 'modal/employee/employee-status.php', success: function (response) { // Remove any existing modal before appending a new one $('#myModal').remove(); // Append the modal content to the body $('body').append(response); // Show the modal $('#myModal').modal('show'); }, error: function () { // Handle error cases if needed console.error('Failed to load modal content.'); } }); } // Use event delegation for dynamically added elements $('body').on('click', '.close', function () { $('#myModal').modal('hide'); }); function edit(id){ window.location.href = 'new_employee.php?id=' + id; } </script>