diff --git a/app/Views/UserList.php b/app/Views/UserList.php index 0adae2ad..141b3c50 100755 --- a/app/Views/UserList.php +++ b/app/Views/UserList.php @@ -341,6 +341,62 @@ table.dataTable tbody td { +first_name ?? ''))); + $ul_col_max_len[1] = max($ul_col_max_len[1], mb_strlen((string) ($row->email ?? ''))); + $ul_col_max_len[2] = max($ul_col_max_len[2], mb_strlen((string) ($row->mobile ?? ''))); + $ul_col_max_len[3] = max($ul_col_max_len[3], mb_strlen((string) ($row->user_role ?? ''))); + $statusLabel = (($row->is_active ?? 0) == 1) ? 'Active' : 'In-Active'; + $ul_col_max_len[4] = max($ul_col_max_len[4], mb_strlen($statusLabel)); + $ul_col_max_len[5] = max($ul_col_max_len[5], 4); + } +} +$ul_col_min_px = array_fill(0, $ul_col_count, 80); +$ul_col_max_px = array_fill(0, $ul_col_count, 360); +$ul_col_min_px[0] = 72; +$ul_col_max_px[0] = 280; +$ul_col_min_px[5] = 72; +$ul_col_max_px[5] = 96; +$ul_col_width_px = nhance_dt_column_widths_px($ul_header_labels, $ul_col_max_len, $ul_col_min_px, $ul_col_max_px); +?> + + <'col-sm-9'B>>" + // "<'row'<'col-sm-12'tr>>" + // "<'row'<'col-sm-5'i><'col-sm-7'p>>", @@ -1083,8 +1139,15 @@ table.dataTable tbody td { $(this).addClass('active'); loadPartner(); }); - } - }); + }, + columnDefs: [ + + { targets: , width: 'px' }, + + ] + })); + nhanceListDataTableAfterInit(); + nhanceListDataTableBindAdjust(table); function applyBottomRowDropup() { if (!table) return; @@ -1109,12 +1172,12 @@ table.dataTable tbody td { // IMPORTANT — DataTables draw event REF: TTS table.on('draw.dt', function () { - let rowCount = $('#scroll-horizontal-datatable').DataTable().rows({ filter: 'applied' }).count(); + let rowCount = table.rows({ filter: 'applied' }).count(); if (rowCount <= 2) { - $('.dataTables_scrollBody').css('overflow', 'inherit'); + $('#user-table_wrapper .dataTables_scrollBody').css('overflow', 'inherit'); } else { - $('.dataTables_scrollBody').css('overflow', 'auto'); + $('#user-table_wrapper .dataTables_scrollBody').css('overflow', 'auto'); } }); diff --git a/app/Views/batch_list.php b/app/Views/batch_list.php index 9e5f256b..96d441b0 100755 --- a/app/Views/batch_list.php +++ b/app/Views/batch_list.php @@ -266,7 +266,7 @@ for ($i = 0; $i < $batch_col_count; $i++) { ?> - + diff --git a/app/Views/bds_dump_file_list.php b/app/Views/bds_dump_file_list.php index 2d314fb9..b56448fa 100644 --- a/app/Views/bds_dump_file_list.php +++ b/app/Views/bds_dump_file_list.php @@ -45,7 +45,7 @@ ?> - + diff --git a/app/Views/business_team_list.php b/app/Views/business_team_list.php index 3a91bf1e..7172fd1b 100644 --- a/app/Views/business_team_list.php +++ b/app/Views/business_team_list.php @@ -202,7 +202,7 @@ $row){ ?> - + diff --git a/app/Views/cd_master_list.php b/app/Views/cd_master_list.php index 81f68346..1314066a 100755 --- a/app/Views/cd_master_list.php +++ b/app/Views/cd_master_list.php @@ -46,15 +46,15 @@ $cdm_col_width_px = nhance_dt_column_widths_px($cdm_header_labels, $cdm_col_max_ + -
+
@@ -84,7 +169,7 @@
- +
@@ -109,7 +194,7 @@ ?> - + @@ -524,11 +609,13 @@ $(document).ready(function() { - $('#tickets-table').DataTable({ + nhanceListDataTableBeforeInit(); + var nhFileListTable = $('#file-list-table').DataTable(nhanceMergeListDataTableOptions({ - dom: "<'row'<'col-sm-7'f><'col-sm-5 text-right'B>>" + // Filter left, buttons right + dom: "<'row'<'col-sm-7'f><'col-sm-5 text-right'B>>" + "<'row'<'col-sm-12'tr>>" + - "<'row align-items-center'<'col-5 text-start'i><'col-7 d-flex justify-content-end align-items-center'<'me-2'l>p>>", lengthMenu: [[10, 20, 50, 100], [10, 20, 50, 100]], + "<'row align-items-center'<'col-5 text-start'i><'col-7 d-flex justify-content-end align-items-center'<'me-2'l>p>>", + lengthMenu: [[10, 20, 50, 100], [10, 20, 50, 100]], buttons: [ { extend: 'collection', @@ -574,19 +661,15 @@ emptyTable: '
No Data found
' }, paging: true, - }); + columnDefs: [ + + { targets: , width: 'px' }, + + ], + })); + nhanceListDataTableAfterInit(); + nhanceListDataTableBindAdjust(nhFileListTable); - setTimeout(function () { - const dt = $('#tickets-table').DataTable(); - dt.columns.adjust().draw(false); - }, 0); - - }); - - $(window).on('resize', function () { - if ($.fn.DataTable.isDataTable('#tickets-table')) { - $('#tickets-table').DataTable().columns.adjust(); - } }); \ No newline at end of file diff --git a/app/Views/frontend_content_list.php b/app/Views/frontend_content_list.php index b0b38da8..695feb65 100644 --- a/app/Views/frontend_content_list.php +++ b/app/Views/frontend_content_list.php @@ -90,7 +90,7 @@ $fec_col_width_px = nhance_dt_column_widths_px($fec_header_labels, $fec_col_max_ $row) { ?> - + diff --git a/app/Views/import_export.php b/app/Views/import_export.php index 84fe0c7c..191ae6ed 100755 --- a/app/Views/import_export.php +++ b/app/Views/import_export.php @@ -1,3 +1,4 @@ + +
@@ -30,7 +89,7 @@
-->
S.No
+ id="insurer-list-table"> @@ -71,10 +130,8 @@ \ No newline at end of file + diff --git a/app/Views/tpa_list.php b/app/Views/tpa_list.php index c369c606..8b17f04c 100755 --- a/app/Views/tpa_list.php +++ b/app/Views/tpa_list.php @@ -1,3 +1,23 @@ + +
@@ -50,7 +108,7 @@
-->
Name 
+ id="tpa-list-table"> @@ -87,7 +145,10 @@
Name