https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41439 --- Comment #73 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- Created attachment 210769 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=210769&action=edit Bug 41439: (follow-up) Do not reset hidden columns when saving an existing rule With the columns split in tabs, adding a rule for a patron category and item type that already has a rule (for example setting holds on the Holds tab for a rule whose checkouts were set on the Checkouts tab) replaced the existing rule with the empty inputs of the columns that are not shown, so their values were silently reset (e.g. to unlimited). * When no rule is being edited, look for the existing rule of the selected patron category and item type, and repopulate the hidden columns from it as is done for the rule being edited. A new combination is unchanged. * The hidden columns of the edit row were looked up with the first input or select of the cell. For Hard due date that is the comparison select, so the date was never restored. Use the same lookup as clicking Edit. * The date pickers of hidden columns are not in the DOM, so setting them threw an error that stopped the submission handler before the columns were shown again. Show all the columns first, then repopulate the ones that were hidden. To test: 1. Apply the patches, enable ArticleRequests and set UseRecalls to staff or opac_and_staff 2. Go to Administration > Circulation and fine rules 3. On the Checkouts tab, set 'Current checkouts allowed' to 10 for All / All and save 4. On the Holds tab, set 'Holds allowed (total)' to 5 for All / All and save 5. Confirm on the Checkouts tab that 'Current checkouts allowed' is still 10 6. Repeat with a hard due date set on the Due dates tab, and confirm it is kept when saving from the Holds tab, with and without clicking Edit first 7. Add a rule for a patron category and item type that has no rule yet from one tab and confirm the other columns are left at their defaults Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> -- You are receiving this mail because: You are watching all bug changes.