This patch refactors the copyright clearance confirmation functionality to follow proper separation of concerns by moving business logic from the controller to the model. Changes: - Add set_copyright_clearance_confirmed() method to Koha::ILL::Request - Add get_copyright_clearance_confirmed() method to Koha::ILL::Request - Update controller to use dedicated method instead of direct attribute manipulation - Update staff template to use the new dedicated accessor method - Add comprehensive test coverage for both methods Benefits: - Improved separation of concerns (business logic in model) - Consistency with existing patterns (get_type, get_type_disclaimer_value) - Better reusability and testability - Centralized attribute name management Test plan: 1. Apply patch 2. Run: $ ktd --shell k$ prove t/db_dependent/Koha/ILL/Request.t => SUCCESS: Tests pass! New methods work correctly 3. Test ILL copyright clearance workflow still works: - Enable ILLModule - Create HTML customization for ILLModuleCopyrightClearance - Create OPAC ILL request with copyright clearance - Verify confirmation is saved and displayed in staff interface 4. Sign off :-D Signed-off-by: Tomás Cohen Arazi <tomascohen@theke.io> PA amended: Test file name in commit message Signed-off-by: Pedro Amorim <pedro.amorim@openfifth.co.uk> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> |
||
|---|---|---|
| .. | ||
| intranet-tmpl | ||
| opac-tmpl | ||