FIX_TABLE_WIDTH_ISSUE
This commit is contained in:
parent
3543c3096c
commit
65b3fc029f
@ -1,16 +1,12 @@
|
||||
<style>
|
||||
|
||||
.table-content.collapse:not(.show) {
|
||||
display: block !important; /* Allows width calculation */
|
||||
height: 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
#allTableContainer {
|
||||
max-width: 100%;
|
||||
overflow-x: auto;
|
||||
display: block;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.btn-custom {
|
||||
background-color: #007bff;
|
||||
color: #fff;
|
||||
@ -2081,40 +2077,23 @@
|
||||
function increaseTableWidth(increaseBy) {
|
||||
|
||||
$('.table-collapsible-bar').each(function() {
|
||||
const $bar = $(this);
|
||||
const wasCollapsed = $bar.hasClass('collapsed');
|
||||
|
||||
// Temporarily show the bar for accurate width calculation
|
||||
if(wasCollapsed) {
|
||||
$bar.css({
|
||||
'display': 'block',
|
||||
'visibility': 'hidden',
|
||||
'position': 'absolute'
|
||||
});
|
||||
}
|
||||
|
||||
const currentWidth = $bar.width();
|
||||
$bar.width(currentWidth + increaseBy);
|
||||
|
||||
// Restore original state
|
||||
if(wasCollapsed) {
|
||||
$bar.css({
|
||||
'display': '',
|
||||
'visibility': '',
|
||||
'position': ''
|
||||
});
|
||||
let currentWidth = ($(this).width());
|
||||
let increaseTableWidth = (currentWidth + increaseBy);
|
||||
if (increaseTableWidth < 1200){
|
||||
increaseTableWidth = 1200+increaseBy
|
||||
}
|
||||
$(this).width(currentWidth + increaseBy);
|
||||
});
|
||||
|
||||
// // // console.log("function called tablewidth increase");
|
||||
$("table").each(function() {
|
||||
const $table = $(this);
|
||||
const currentWidth = $table.width();
|
||||
$table.width(currentWidth + increaseBy);
|
||||
|
||||
// Force layout update for hidden tables
|
||||
$table.parent('.table-content').css('display', 'block');
|
||||
$table.width(currentWidth + increaseBy);
|
||||
$table.parent('.table-content').css('display', '');
|
||||
let currentWidth = ($(this).width());
|
||||
// alert(currentWidth);
|
||||
let increaseTableWidth = (currentWidth + increaseBy);
|
||||
console.log("Table Width increased to ",increaseTableWidth);
|
||||
if (increaseTableWidth < 1200){
|
||||
increaseTableWidth = 1200+increaseBy
|
||||
}
|
||||
$(this).width(increaseTableWidth);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@ -18,7 +18,7 @@
|
||||
"botman/driver-web": "^1.5",
|
||||
"dompdf/dompdf": "^2.0",
|
||||
"firebase/php-jwt": "^6.10",
|
||||
"google/apiclient": "^2.15.0",
|
||||
"google/apiclient": "^2.18",
|
||||
"kreait/firebase-php": "^7.0",
|
||||
"laminas/laminas-escaper": "^2.9",
|
||||
"php-amqplib/php-amqplib": "^2.8",
|
||||
|
||||
Loading…
Reference in New Issue
Block a user