Bug 39930

Summary: Saved configuration states on tables cause extra columns to show
Product: Koha Reporter: Jason Robb <jrobb>
Component: Staff interfaceAssignee: Bugs List <koha-bugs>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: trivial    
Priority: P5 - low CC: david, gmcharlt, mteal, roman.dolny
Version: Main   
Hardware: All   
OS: All   
GIT URL: Change sponsored?: ---
Patch complexity: --- Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:

Description Jason Robb 2025-05-16 21:36:06 UTC
This is hard to replicate but I did come across it on main in ktd.

When "Save configuration state on page change" is enabled for a table, after an amount of time or some undetermined action, the table settings seem to go wonky.

On the issues table at circ/circulation.pl for example, the grouping breaks and the sort_order and todays_or_previous_checkouts get revealed where they should be perma-hidden:

Table showing columns that shouldn't be there: https://snipboard.io/TYL3Oe.jpg
Table settings for that table: https://snipboard.io/kU7Tiw.jpg
Column settings from local storage: https://snipboard.io/6aS8e4.jpg

The steps that led to this were:
1. Set AlwaysLoadCheckoutsTable syspref to Do
2. Check out an item (39999000018516) to a patron (42)
3. Close the tab for a while (I didn't log out, just closed then reopened a few hours later)
4. Pull up the patron, extra mysterious columns have appeared

This isn't isolated to the checkouts table, as we've come across it with saved reports and other tables that get saved states as well.

Unchecking the save state box seems to avoid the problem.
Comment 1 mteal 2025-06-24 17:34:51 UTC
We saw this in Acquisitions. When we search for Orders for a particular vendor, it shows a list of baskets. If you click on and open a basket, it correctly displays the orders table with the columns reflecting what is set up in Configuration.
If you back arrow to get back to your list and select another basket, the columns remain correct.
However, while you have a basket open, if you click on "Reopen basket", the Orders table displays with ALL the columns, even the ones selected to hide. From that point on, it continues to show all the columns no matter what baskets I pull up. You have to log out of Koha and back in to get the columns to reset back to what's in Configuration. 
Unchecking Save configuration state on page change prevents the problem from happening.