From 06036d41c42b29c9277d03356af4cc1c5773573b Mon Sep 17 00:00:00 2001 From: venkateswaran ubuntu Date: Mon, 4 Sep 2023 12:35:09 +0530 Subject: [PATCH] susee --- app/Views/members_list.php | 10 ++++++++++ app/Views/transactions_list.php | 12 ------------ 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/app/Views/members_list.php b/app/Views/members_list.php index bfe2766..7f5fa57 100644 --- a/app/Views/members_list.php +++ b/app/Views/members_list.php @@ -153,6 +153,9 @@ $(document).on('click','.transaction',function(){ text: 'PDF', customize: function(doc) { // You can further customize the PDF here if needed + doc.content[1].table.body.forEach(function(row) { + row.splice(0, 1); // Remove the first column (ID column) + }); } }, { @@ -161,17 +164,24 @@ $(document).on('click','.transaction',function(){ text: 'Print', customize: function(win) { // You can further customize the print output here if needed + $(win.document.body).find('table').find('th:first, td:first').remove(); } }, { extend: 'copy', text: 'Copy', // Set the title for the Copy button titleAttr: 'Copy', // Set the tooltip for the Copy button + exportOptions: { + columns: ':not(:first-child)' // Exclude the first column (ID column) + } }, { extend: 'csv', text: 'CSV', // Set the title for the CSV button title: 'Members', // Set your custom print title here + exportOptions: { + columns: ':not(:first-child)' // Exclude the first column (ID column) + } } ] }); diff --git a/app/Views/transactions_list.php b/app/Views/transactions_list.php index 4b82ba8..9310eb8 100644 --- a/app/Views/transactions_list.php +++ b/app/Views/transactions_list.php @@ -159,34 +159,22 @@ $(document).on('click','.order_details',function(){ title: 'Transactions', // Set your custom PDF title here text: 'PDF', customize: function(doc) { - doc.content[1].table.body.forEach(function(row) { - row.splice(0, 1); // Remove the first column (ID column) - }); } }, { extend: 'print', title: 'Transactions', // Set your custom print title here text: 'Print', - customize: function(win) { - $(win.document.body).find('table').find('th:first, td:first').remove(); - } }, { extend: 'copy', text: 'Copy', // Set the title for the Copy button titleAttr: 'Copy', // Set the tooltip for the Copy button - exportOptions: { - columns: ':not(:first-child)' // Exclude the first column (ID column) - } }, { extend: 'csv', text: 'CSV', // Set the title for the CSV button title: 'Transactions', // Set your custom print title here - exportOptions: { - columns: ':not(:first-child)' // Exclude the first column (ID column) - } } ], "language": {