`
- $('#myLargeModalLabel').html("Add Credits For "+$('#empName').val()+" ")
+ $('#myLargeModalLabel').html("Manage Credits For "+$('#empName').val()+" ")
$('#model-table').html(addForm);
$('#bs-example-modal-lg').modal('show');
@@ -333,10 +342,34 @@ $(document).on('change','#packs',function(){
$('#datatable-buttons').DataTable({
"order": [[0, 'desc']], // Set initial sorting to descending on the first column
"dom": 'Bfrtip', // Show export buttons
- // "buttons": ['copy', 'csv', 'excel', 'pdf'], // Enable export options
- // "language": {
- // "search": "Search: " // Customize search label
- // }
+ buttons: [
+ {
+ extend: 'pdfHtml5',
+ title: 'Member Name : (Total Credits : )', // Set your custom PDF title here
+ text: 'PDF',
+ customize: function(doc) {
+ // You can further customize the PDF here if needed
+ }
+ },
+ {
+ extend: 'print',
+ title: 'Member Name : (Total Credits : )', // Set your custom print title here
+ text: 'Print',
+ customize: function(win) {
+ // You can further customize the print output here if needed
+ }
+ },
+ {
+ extend: 'copy',
+ text: 'Copy', // Set the title for the Copy button
+ titleAttr: 'Copy', // Set the tooltip for the Copy button
+ },
+ {
+ extend: 'csv',
+ text: 'CSV', // Set the title for the CSV button
+ title: 'CMember Name : (Total Credits : )', // Set your custom print title here
+ }
+ ]
});
});
@@ -348,6 +381,23 @@ function matchnum(event)
return false;
}
$(document).on('change','.add_or_sub',function(){
+ var selectedValue = $('input[name="add_or_sub"]:checked').val();
+ if (selectedValue === 'sub') {
+
+ $('#method option[value="card"]').hide();
+ $('#method option[value="cash"]').hide();
+ $("#packs option[value='6']").hide();
+ $("#packs option[value='7']").hide();
+ $('#remarks').prop('required', true);
+ } else {
+ $('#method option[value="card"]').show();
+ $('#method option[value="cash"]').show();
+ $('#method option[value="card"]').show();
+ $('#method option[value="cash"]').show();
+ $('#remarks').prop('required', false);
+ }
+
+
if($(this).val() == 'sub')
{
$('#button').html('Deduct');
diff --git a/app/Views/members_list.php b/app/Views/members_list.php
index e3e7c7a..bfe2766 100644
--- a/app/Views/members_list.php
+++ b/app/Views/members_list.php
@@ -146,10 +146,34 @@ $(document).on('click','.transaction',function(){
$('#datatable-buttons').DataTable({
"order": [[0, 'desc']], // Set initial sorting to descending on the first column
"dom": 'Bfrtip', // Show export buttons
- // "buttons": ['copy', 'csv', 'excel', 'pdf'], // Enable export options
- // "language": {
- // "search": "Search: " // Customize search label
- // }
+ buttons: [
+ {
+ extend: 'pdfHtml5',
+ title: 'Members', // Set your custom PDF title here
+ text: 'PDF',
+ customize: function(doc) {
+ // You can further customize the PDF here if needed
+ }
+ },
+ {
+ extend: 'print',
+ title: 'Members', // Set your custom print title here
+ text: 'Print',
+ customize: function(win) {
+ // You can further customize the print output here if needed
+ }
+ },
+ {
+ extend: 'copy',
+ text: 'Copy', // Set the title for the Copy button
+ titleAttr: 'Copy', // Set the tooltip for the Copy button
+ },
+ {
+ extend: 'csv',
+ text: 'CSV', // Set the title for the CSV button
+ title: 'Members', // Set your custom print title here
+ }
+ ]
});
});
diff --git a/app/Views/transactions_list.php b/app/Views/transactions_list.php
index 2b3c623..112ea44 100644
--- a/app/Views/transactions_list.php
+++ b/app/Views/transactions_list.php
@@ -153,7 +153,34 @@ $(document).on('click','.order_details',function(){
$('#datatable-buttons').DataTable({
"order": [[2, 'desc']], // Set initial sorting to descending on the first column
"dom": 'Bfrtip', // Show export buttons
- // "buttons": ['copy', 'csv', 'excel', 'pdf'], // Enable export options
+ buttons: [
+ {
+ extend: 'pdfHtml5',
+ title: 'Transactions', // Set your custom PDF title here
+ text: 'PDF',
+ customize: function(doc) {
+ // You can further customize the PDF here if needed
+ }
+ },
+ {
+ extend: 'print',
+ title: 'Transactions', // Set your custom print title here
+ text: 'Print',
+ customize: function(win) {
+ // You can further customize the print output here if needed
+ }
+ },
+ {
+ extend: 'copy',
+ text: 'Copy', // Set the title for the Copy button
+ titleAttr: 'Copy', // Set the tooltip for the Copy button
+ },
+ {
+ extend: 'csv',
+ text: 'CSV', // Set the title for the CSV button
+ title: 'Transactions', // Set your custom print title here
+ }
+ ],
"language": {
"search": "Search: " // Customize search label
},
diff --git a/app/Views/users_list copy.php b/app/Views/users_list copy.php
index 5fbb39f..0c5e2c6 100644
--- a/app/Views/users_list copy.php
+++ b/app/Views/users_list copy.php
@@ -93,7 +93,34 @@
$('#datatable-buttons').DataTable({
"order": [[0, 'desc']], // Set initial sorting to descending on the first column
"dom": 'Bfrtip', // Show export buttons
- // "buttons": ['copy', 'csv', 'excel', 'pdf'], // Enable export options
+ buttons: [
+ {
+ extend: 'pdfHtml5',
+ title: 'Users', // Set your custom PDF title here
+ text: 'PDF',
+ customize: function(doc) {
+ // You can further customize the PDF here if needed
+ }
+ },
+ {
+ extend: 'print',
+ title: 'Users', // Set your custom print title here
+ text: 'Print',
+ customize: function(win) {
+ // You can further customize the print output here if needed
+ }
+ },
+ {
+ extend: 'copy',
+ text: 'Copy', // Set the title for the Copy button
+ titleAttr: 'Copy', // Set the tooltip for the Copy button
+ },
+ {
+ extend: 'csv',
+ text: 'CSV', // Set the title for the CSV button
+ title: 'Users', // Set your custom print title here
+ }
+ ],
"language": {
"search": "Search: " // Customize search label
}
diff --git a/app/Views/users_list.php b/app/Views/users_list.php
index 5fbb39f..0c5e2c6 100644
--- a/app/Views/users_list.php
+++ b/app/Views/users_list.php
@@ -93,7 +93,34 @@
$('#datatable-buttons').DataTable({
"order": [[0, 'desc']], // Set initial sorting to descending on the first column
"dom": 'Bfrtip', // Show export buttons
- // "buttons": ['copy', 'csv', 'excel', 'pdf'], // Enable export options
+ buttons: [
+ {
+ extend: 'pdfHtml5',
+ title: 'Users', // Set your custom PDF title here
+ text: 'PDF',
+ customize: function(doc) {
+ // You can further customize the PDF here if needed
+ }
+ },
+ {
+ extend: 'print',
+ title: 'Users', // Set your custom print title here
+ text: 'Print',
+ customize: function(win) {
+ // You can further customize the print output here if needed
+ }
+ },
+ {
+ extend: 'copy',
+ text: 'Copy', // Set the title for the Copy button
+ titleAttr: 'Copy', // Set the tooltip for the Copy button
+ },
+ {
+ extend: 'csv',
+ text: 'CSV', // Set the title for the CSV button
+ title: 'Users', // Set your custom print title here
+ }
+ ],
"language": {
"search": "Search: " // Customize search label
}