Bug 37873 - Unable to delete user from routing list or preview/print routing list slip
Summary: Unable to delete user from routing list or preview/print routing list slip
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Serials (show other bugs)
Version: Main
Hardware: All All
: P5 - low major
Assignee: CJ Lynce
QA Contact: Martin Renvoize (ashimema)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-09 20:03 UTC by Chip Halvorsen
Modified: 2024-11-14 14:37 UTC (History)
8 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Fixes a regression that prevented recipients from being deleted from a routing list, as well as resolving issues with previewing routing lists.
Version(s) released in:
24.11.00,24.05.04
Circulation function:


Attachments
Bug 37873: Unable to delete user from routing list or preview/print routing list slip (10.35 KB, patch)
2024-09-10 18:13 UTC, CJ Lynce
Details | Diff | Splinter Review
Bug 37873: Unable to delete user from routing list or preview/print routing list slip (10.40 KB, patch)
2024-09-10 20:40 UTC, Olivier Vezina
Details | Diff | Splinter Review
Bug 37873: Unable to delete user from routing list or preview/print routing list slip (10.47 KB, patch)
2024-09-13 11:47 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review
Bug 37873: [24.05.x] Unable to delete user from routing list or preview/print routing list slip (10.34 KB, patch)
2024-09-24 15:13 UTC, CJ Lynce
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Chip Halvorsen 2024-09-09 20:03:10 UTC
We are unable to remove users from serials routing lists after the 24.05 upgrade. Clicking the delete button does nothing. Possibly related to CSRF changes.
Comment 1 CJ Lynce 2024-09-10 16:49:55 UTC
I verified this is present on main as well. 

While troubleshooting, I also found that the "Save and preview slip" button was not previewing the slip. Also, using the "Print list" button from the Serial collection information screen was display the standard staff interface headers when trying to print the slip.

I will have a patch up for this later today.
Comment 2 CJ Lynce 2024-09-10 18:13:26 UTC
Created attachment 171278 [details] [review]
Bug 37873: Unable to delete user from routing list or preview/print routing list slip

This patch restores the ability to delete a recipient from a serials routing list.
It also fixes the slip preview when using the "Save and preview slip", and removes
	the koha staff intranet head from the slip when using 'Print list' from the
	Serial collection information screen.

To test:
1) Login to the staff client.
2) Open the Serials module.
3) + New subscription to add a new serial.
4) Create a new subscription.
	a) Search for a record (I searched for 'dog') and chose that record.
	b) Under 'When receiving this serial', select 'Create an item record'
	c) Under the 'Item type' dropdown, select anything.
	d) Click Next -> (and confirm the popup).
	e) Select any 'First issue date'.
	f) Select any 'Frequency'.
	g) Enter a number larger than 5 in the 'Subscription length'.
	h) Select any 'Subscription start date'.
	i) Select your favorite numbering pattern.
	j) Verify your prediction pattern using "Test prediction pattern".
	k) Click "Save subscription".
5) On the 'Subscription details' screen, click "Receive".
6) Under the first volume, click "Add item" then "Save".
7) Repeat step 6 to receive one more issue.
8) On the 'Serial collection information' page click "+ Create routing list"
9) Click "+ Add recipients".
10) Search for and add several recipients.
11) Click "Close" to exit the 'Add recipients' page.
12) Click "Delete" next to any recipient.
	*Note that the recipient is not deleted.
13) Click "Save" on the 'Modify routing list for ...' page.
14) Click "Save and preview routing slip" button.
	*Note you are redirected to the Subscription details page, but no routing
	slip preview appears.
15) Click "Serial collection" from the left-side menu.
16) Click "Print list" on either of the issues you previously received.
	*Note the routing slip includes the staff intranet header, menu, etc.

17) Apply patch.
18) Return to the 'Serial collection information' screen for your subscription.
19) Click "Edit routing list".
20) Repeat steps 12-16 and verify the issues are fixed.
	-"Delete" button works to remove a recipient from a list.
	-"Save and preview routing list" button pops-up a preview before redirecting.
	-"Print list" pops-up a vanilla routing list to print.

Sponsored-by: Westlake Porter Public Library
Comment 3 Olivier Vezina 2024-09-10 20:40:22 UTC
Created attachment 171292 [details] [review]
Bug 37873: Unable to delete user from routing list or preview/print routing list slip

This patch restores the ability to delete a recipient from a serials routing list.
It also fixes the slip preview when using the "Save and preview slip", and removes
	the koha staff intranet head from the slip when using 'Print list' from the
	Serial collection information screen.

To test:
1) Login to the staff client.
2) Open the Serials module.
3) + New subscription to add a new serial.
4) Create a new subscription.
	a) Search for a record (I searched for 'dog') and chose that record.
	b) Under 'When receiving this serial', select 'Create an item record'
	c) Under the 'Item type' dropdown, select anything.
	d) Click Next -> (and confirm the popup).
	e) Select any 'First issue date'.
	f) Select any 'Frequency'.
	g) Enter a number larger than 5 in the 'Subscription length'.
	h) Select any 'Subscription start date'.
	i) Select your favorite numbering pattern.
	j) Verify your prediction pattern using "Test prediction pattern".
	k) Click "Save subscription".
5) On the 'Subscription details' screen, click "Receive".
6) Under the first volume, click "Add item" then "Save".
7) Repeat step 6 to receive one more issue.
8) On the 'Serial collection information' page click "+ Create routing list"
9) Click "+ Add recipients".
10) Search for and add several recipients.
11) Click "Close" to exit the 'Add recipients' page.
12) Click "Delete" next to any recipient.
	*Note that the recipient is not deleted.
13) Click "Save" on the 'Modify routing list for ...' page.
14) Click "Save and preview routing slip" button.
	*Note you are redirected to the Subscription details page, but no routing
	slip preview appears.
15) Click "Serial collection" from the left-side menu.
16) Click "Print list" on either of the issues you previously received.
	*Note the routing slip includes the staff intranet header, menu, etc.

17) Apply patch.
18) Return to the 'Serial collection information' screen for your subscription.
19) Click "Edit routing list".
20) Repeat steps 12-16 and verify the issues are fixed.
	-"Delete" button works to remove a recipient from a list.
	-"Save and preview routing list" button pops-up a preview before redirecting.
	-"Print list" pops-up a vanilla routing list to print.

Sponsored-by: Westlake Porter Public Library
Signed-off-by: Olivier V <olivier.vezina@inLibro.com>
Comment 4 Martin Renvoize (ashimema) 2024-09-13 11:47:01 UTC
Created attachment 171446 [details] [review]
Bug 37873: Unable to delete user from routing list or preview/print routing list slip

This patch restores the ability to delete a recipient from a serials routing list.
It also fixes the slip preview when using the "Save and preview slip", and removes
	the koha staff intranet head from the slip when using 'Print list' from the
	Serial collection information screen.

To test:
1) Login to the staff client.
2) Open the Serials module.
3) + New subscription to add a new serial.
4) Create a new subscription.
	a) Search for a record (I searched for 'dog') and chose that record.
	b) Under 'When receiving this serial', select 'Create an item record'
	c) Under the 'Item type' dropdown, select anything.
	d) Click Next -> (and confirm the popup).
	e) Select any 'First issue date'.
	f) Select any 'Frequency'.
	g) Enter a number larger than 5 in the 'Subscription length'.
	h) Select any 'Subscription start date'.
	i) Select your favorite numbering pattern.
	j) Verify your prediction pattern using "Test prediction pattern".
	k) Click "Save subscription".
5) On the 'Subscription details' screen, click "Receive".
6) Under the first volume, click "Add item" then "Save".
7) Repeat step 6 to receive one more issue.
8) On the 'Serial collection information' page click "+ Create routing list"
9) Click "+ Add recipients".
10) Search for and add several recipients.
11) Click "Close" to exit the 'Add recipients' page.
12) Click "Delete" next to any recipient.
	*Note that the recipient is not deleted.
13) Click "Save" on the 'Modify routing list for ...' page.
14) Click "Save and preview routing slip" button.
	*Note you are redirected to the Subscription details page, but no routing
	slip preview appears.
15) Click "Serial collection" from the left-side menu.
16) Click "Print list" on either of the issues you previously received.
	*Note the routing slip includes the staff intranet header, menu, etc.

17) Apply patch.
18) Return to the 'Serial collection information' screen for your subscription.
19) Click "Edit routing list".
20) Repeat steps 12-16 and verify the issues are fixed.
	-"Delete" button works to remove a recipient from a list.
	-"Save and preview routing list" button pops-up a preview before redirecting.
	-"Print list" pops-up a vanilla routing list to print.

Sponsored-by: Westlake Porter Public Library
Signed-off-by: Olivier V <olivier.vezina@inLibro.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 5 Martin Renvoize (ashimema) 2024-09-13 11:48:21 UTC
Thanks for the fix here..

Passing QA
Comment 6 Katrin Fischer 2024-09-13 14:12:05 UTC
Pushed for 24.11!

Well done everyone, thank you!
Comment 7 Lucas Gass (lukeg) 2024-09-23 20:38:13 UTC
Doesn't apply cleanly to 24.05.x, please rebase
Comment 8 CJ Lynce 2024-09-24 15:13:24 UTC
Created attachment 171944 [details] [review]
Bug 37873: [24.05.x] Unable to delete user from routing list or preview/print routing list slip

This patch restores the ability to delete a recipient from a serials routing list.
It also fixes the slip preview when using the "Save and preview slip", and removes
	the koha staff intranet head from the slip when using 'Print list' from the
	Serial collection information screen.

To test:
1) Login to the staff client.
2) Open the Serials module.
3) + New subscription to add a new serial.
4) Create a new subscription.
	a) Search for a record (I searched for 'dog') and chose that record.
	b) Under 'When receiving this serial', select 'Create an item record'
	c) Under the 'Item type' dropdown, select anything.
	d) Click Next -> (and confirm the popup).
	e) Select any 'First issue date'.
	f) Select any 'Frequency'.
	g) Enter a number larger than 5 in the 'Subscription length'.
	h) Select any 'Subscription start date'.
	i) Select your favorite numbering pattern.
	j) Verify your prediction pattern using "Test prediction pattern".
	k) Click "Save subscription".
5) On the 'Subscription details' screen, click "Receive".
6) Under the first volume, click "Add item" then "Save".
7) Repeat step 6 to receive one more issue.
8) On the 'Serial collection information' page click "+ Create routing list"
9) Click "+ Add recipients".
10) Search for and add several recipients.
11) Click "Close" to exit the 'Add recipients' page.
12) Click "Delete" next to any recipient.
	*Note that the recipient is not deleted.
13) Click "Save" on the 'Modify routing list for ...' page.
14) Click "Save and preview routing slip" button.
	*Note you are redirected to the Subscription details page, but no routing
	slip preview appears.
15) Click "Serial collection" from the left-side menu.
16) Click "Print list" on either of the issues you previously received.
	*Note the routing slip includes the staff intranet header, menu, etc.

17) Apply patch.
18) Return to the 'Serial collection information' screen for your subscription.
19) Click "Edit routing list".
20) Repeat steps 12-16 and verify the issues are fixed.
	-"Delete" button works to remove a recipient from a list.
	-"Save and preview routing list" button pops-up a preview before redirecting.
	-"Print list" pops-up a vanilla routing list to print.

Sponsored-by: Westlake Porter Public Library
Comment 9 CJ Lynce 2024-09-24 15:15:17 UTC
Rebased for 24.05.x
Comment 10 Lucas Gass (lukeg) 2024-09-24 15:17:51 UTC
Thanks CJ! Backported to 24.05. for upcoming 24.05.04
Comment 11 Fridolin Somers 2024-10-21 12:50:48 UTC
CUD not in 23.11.x
Comment 12 David Nind 2024-11-10 18:23:19 UTC
Bug fix, no change to UI, no changes required to the documentation.