Open jfmartinezm opened 1 year ago
As I wrote an a different issue, this is an excellent idea. I think updating to the latest version of DataTables and utilizing the latest API version would make showing/hiding columns trivial.
There is even documentation on how to accomplish this: https://datatables.net/examples/api/show_hide.html
The big blocker is we have code that relies on the column indexes to function, which is bad.
Depending on the particular configuration of each site, certain columns will never be used (e.g. Lastname/Firstname if the system does not store them, Reserved if reservations are not allowed, etc). It would be nice to be able to select which columns will be shown. It could be set as a system wide setting, or on a per-admin-user basis, although that could be harder to implement.
I tried previoulsy to hide some columns by changing their CSS style with custom Javascript, but on certain cases it would cause issues with table rendering (missing borders, etc).