https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=38666
--- Comment #127 from Andrii Nugged <[email protected]> --- Created attachment 212040 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=212040&action=edit Bug 38666: Reuse model policy for closed stack request controls Let data-driven controls rely on the existing model filters instead of checking EnableClosedStackRequests again in templates. Static navigation and server-side entry guards keep their own checks. Reuse the existing item resultset filter in forced_hold_level while retaining its early disabled return and its existing hold rules. The public hold filters already handle disabled requests before building SQL, so their private condition builder needs no second guard. Test the public filters rather than the private builder. Stored flags, disabled editing policy, queued edits and the handling of existing holds are unchanged. No new policy framework is added. Test plan: Before applying the patch: 1. Apply the existing Bug 38666 series and enable closed stack requests. 2. Prepare a closed stack item and a request using the original plan. 3. View its staff catalogue record and the patron's details. Confirm the closed stack request links and tabs are present. 4. View the staff home page, the OPAC record and the patron's OPAC account. Confirm their closed stack request controls are present. 5. Disable EnableClosedStackRequests. Revisit the same pages and confirm those controls disappear while ordinary holds remain. Apply the patch. After applying the patch: 1. Repeat the same checks with the preference enabled and disabled. 2. Confirm the visible results match those before applying the patch. Automated tests: prove -v t/db_dependent/ClosedStackRequests.t Co-Authored-By: Loontik <[email protected]> -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list -- [email protected] To unsubscribe send an email to [email protected] website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
