Bug 38411

Summary: When adding multiple items on receive, mandatory fields are not checked
Product: Koha Reporter: Adolfo Rodríguez Taboada <adolfo.rodriguez>
Component: AcquisitionsAssignee: Adolfo Rodríguez Taboada <adolfo.rodriguez>
Status: Needs Signoff --- QA Contact: Testopia <testopia>
Severity: major    
Priority: P5 - low CC: david
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Bug 38411: Check mandatory item fields when creating several items ordering or receiving.

Description Adolfo Rodríguez Taboada 2024-11-08 15:20:14 UTC
This was fixed Bug #34109 for the case where only one item is added (function addItem)
When adding multiple items, the function addMulti is used and it doesn't check mandatory fields.
Comment 1 Adolfo Rodríguez Taboada 2024-11-08 15:24:15 UTC
Created attachment 174274 [details] [review]
Bug 38411: Check mandatory item fields when creating several items ordering or receiving.

This patch adds a check of mandatory item fields when adding several items

Test plan:
1 We need mandatory subfields for items in the ACQ framework and an open basket configured to create items on order or a closed basket configured to create items on receiving an order
2 In both cases, in the form to create items check that there are mandatory fields.
3 Click the Add multiple items button, write a number and then add.
4 Check that the items have been added.
5 Apply patch, restart services
6 Repeat step 3 Now it doesn't add the items and shows an alert regarding the empty mandatory fields