Hi,
I share with you a solution I found to find the list of hidden and/or shown columns in a neoTable table using a bit of javascript.
For the list of hidden fields and headers:
(Container1 is the container used for viewing the table)
setvar [ContainerName] "Container1"
createemptyarray [hiddenFields]
createemptyarray [hiddenTitles]
beginjs
var tab = $('#'+$App.ContainerName+'neoTable').bootstrapTable('getHiddenColumns');
$.each(tab, function(index, value) {
//alert(value.title+' '+value.field);
$App.hiddenFields[index] = value.field;
$App.hiddenTitles[index] = value.title;
})
endjs
jsalert [hiddenFields]
jsalert [hiddenTitles]
For the list of visible fields and headers:
setvar [ContainerName] "Container1"
createemptyarray [visibleFields]
createemptyarray [visibleTitles]
beginjs
var tab = $('#'+$App.ContainerName+'neoTable').bootstrapTable('getVisibleColumns');
$.each(tab, function(index, value) {
//alert(value.title+' '+value.field);
$App.visibleFields[index] = value.field;
$App.visibleTitles[index] = value.title;
})
endjs
jsalert [visibleFields]
jsalert [visibleTitles]
I hope it helps someone
Greetings
Rocco
Hi,
I share with you a solution I found to find the list of hidden and/or shown columns in a neoTable table using a bit of javascript.
For the list of hidden fields and headers:
(Container1 is the container used for viewing the table)
setvar [ContainerName] "Container1"
createemptyarray [hiddenFields]
createemptyarray [hiddenTitles]
beginjs
var tab = $('#'+$App.ContainerName+'neoTable').bootstrapTable('getHiddenColumns');
$.each(tab, function(index, value) {
//alert(value.title+' '+value.field);
$App.hiddenFields[index] = value.field;
$App.hiddenTitles[index] = value.title;
})
endjs
jsalert [hiddenFields]
jsalert [hiddenTitles]
For the list of visible fields and headers:
setvar [ContainerName] "Container1"
createemptyarray [visibleFields]
createemptyarray [visibleTitles]
beginjs
var tab = $('#'+$App.ContainerName+'neoTable').bootstrapTable('getVisibleColumns');
$.each(tab, function(index, value) {
//alert(value.title+' '+value.field);
$App.visibleFields[index] = value.field;
$App.visibleTitles[index] = value.title;
})
endjs
jsalert [visibleFields]
jsalert [visibleTitles]
I hope it helps someone
Greetings
Rocco
luishp, Gaev and 2 other users have reacted to this post.
luishpGaevsmartmediaPhil78