Summary: | Batch extend due dates tool not working | ||
---|---|---|---|
Product: | Koha | Reporter: | Sara Brown <sbrown> |
Component: | Tools | Assignee: | Nick Clemens (kidclamp) <nick> |
Status: | Needs documenting --- | QA Contact: | Marcel de Rooy <m.de.rooy> |
Severity: | major | ||
Priority: | P5 - low | CC: | blawlor, catrina, emily.lamancusa, fridolin.somers, januszop, lucas, m.de.rooy, nick, phil |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Trivial patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: |
24.11.00,24.05.05
|
|
Circulation function: | |||
Bug Depends on: | 34478 | ||
Bug Blocks: | 36192, 37941 | ||
Attachments: |
Bug 37483: batch extend due dates list is a stateless action
Bug 37483: batch extend due dates list is a stateless action Bug 37483: Use cud-list for extend due dates tool Bug 37483: Use cud-list for extend due dates tool Bug 37483: Use cud-list for extend due dates tool |
Description
Sara Brown
2024-07-25 20:06:09 UTC
Created attachment 169963 [details] [review] Bug 37483: batch extend due dates list is a stateless action Remove cud- from op and submit form as get To test: 1 - Checkout some items to patrons of at least two libraries 2 - Tools -> Batch extend due dates 3 - Select nothing except 'preview' and submit 4 - Blank screen 5 - Apply patch, repeat 6 - It works! 7 - Filter by library and confirm it still works 8 - Sign off! Created attachment 170023 [details] [review] Bug 37483: batch extend due dates list is a stateless action Remove cud- from op and submit form as get To test: 1 - Checkout some items to patrons of at least two libraries 2 - Tools -> Batch extend due dates 3 - Select nothing except 'preview' and submit 4 - Blank screen 5 - Apply patch, repeat 6 - It works! 7 - Filter by library and confirm it still works 8 - Sign off! Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org> This one's a bit messy..."(cud-)list" is sent as the op regardless of whether "Preview results first" is checked or not. If "Preview results first" is not checked, then it is very much a CUD action! (In reply to Emily Lamancusa from comment #3) > This one's a bit messy..."(cud-)list" is sent as the op regardless of > whether "Preview results first" is checked or not. If "Preview results > first" is not checked, then it is very much a CUD action! How about making this the opposite way, i.e. just: --- a/tools/batch_extend_due_dates.pl +++ b/tools/batch_extend_due_dates.pl @@ -46,7 +46,7 @@ my @issue_ids; if ( $op eq 'form' ) { $template->param( view => 'form', ); } -elsif ( $op eq 'list' ) { +elsif ( $op eq 'cud-list' ) { my @categorycodes = $input->multi_param('categorycodes'); my @itemtypecodes = $input->multi_param('itemtypecodes'); Nick, what do you think? In fact, if ! $preview_results then $op = 'cud-modify' (line 141) and the script continues with cud-modify (from line 145). Created attachment 171610 [details] [review] Bug 37483: Use cud-list for extend due dates tool This patch switch the check in the script to 'cud-list' - we use the same form submission if listing for preview or directly updating dates, so this may or may not be a cud- action - assuming it is restores script functionality. See bug 37941 for updating forms to not share actions To test: 1 - Checkout some items to patrons of at least two libraries 2 - Tools -> Batch extend due dates 3 - Select nothing except 'preview' and submit 4 - Blank screen 5 - Apply patch, repeat 6 - It works! 7 - Filter by library and confirm it still works 8 - Sign off! Created attachment 171616 [details] [review] Bug 37483: Use cud-list for extend due dates tool This patch switch the check in the script to 'cud-list' - we use the same form submission if listing for preview or directly updating dates, so this may or may not be a cud- action - assuming it is restores script functionality. See bug 37941 for updating forms to not share actions To test: 1 - Checkout some items to patrons of at least two libraries 2 - Tools -> Batch extend due dates 3 - Select nothing except 'preview' and submit 4 - Blank screen 5 - Apply patch, repeat 6 - It works! 7 - Filter by library and confirm it still works 8 - Sign off! Signed-off-by: Janusz Kaczmarek <januszop@gmail.com> Created attachment 171827 [details] [review] Bug 37483: Use cud-list for extend due dates tool This patch switch the check in the script to 'cud-list' - we use the same form submission if listing for preview or directly updating dates, so this may or may not be a cud- action - assuming it is restores script functionality. See bug 37941 for updating forms to not share actions To test: 1 - Checkout some items to patrons of at least two libraries 2 - Tools -> Batch extend due dates 3 - Select nothing except 'preview' and submit 4 - Blank screen 5 - Apply patch, repeat 6 - It works! 7 - Filter by library and confirm it still works 8 - Sign off! Signed-off-by: Janusz Kaczmarek <januszop@gmail.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Pushed for 24.11! Well done everyone, thank you! Backported to 24.05.x for upcoming 24.05.05 Depends on Bug 34478 not in 23.11.x |