Bug 35292

Summary: Define itemtype specific rules in the UpdateNotForLoanStatusOnCheckOut system preference
Product: Koha Reporter: Lisette Scheer <lisette>
Component: CirculationAssignee: Baptiste Wojtkowski (bwoj) <baptiste.wojtkowski>
Status: Signed Off --- QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: baptiste.wojtkowski, caroline.cyr-la-rose, e.betemps, gmcharlt, kyle.m.hall, stephanie.etallaz, victor
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30403
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25560
GIT URL: Change sponsored?: ---
Patch complexity: Small patch Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Bug 35292: Database changes
Bug 35292: Template changes
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function
Bug 35292: Database changes
Bug 35292: Template changes
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function
Bug 35292: Move tests of UpdateNotforloan together
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout
Bug 35292: Add tests for _updateNotForLoanFromYaml
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest
Bug 35292: Database changes
Bug 35292: Template changes
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function
Bug 35292: Move tests of UpdateNotforloan together
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout
Bug 35292: Add tests for _updateNotForLoanFromYaml
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest
Bug 35292: Database changes
Bug 35292: Template changes
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function
Bug 35292: Move tests of UpdateNotforloan together
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout
Bug 35292: Add tests for _updateNotForLoanFromYaml
Bug 35292: Database changes
Bug 35292: Template changes
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function
Bug 35292: Move tests of UpdateNotforloan together
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout
Bug 35292: Add tests for _updateNotForLoanFromYaml
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest
Bug 35292: Database changes
Bug 35292: Template changes
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function
Bug 35292: Move tests of UpdateNotforloan together
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout
Bug 35292: Add tests for _updateNotForLoanFromYaml
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest
Bug 35292: Database changes
Bug 35292: Template changes
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function
Bug 35292: Move tests of UpdateNotforloan together
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout
Bug 35292: Add tests for _updateNotForLoanFromYaml
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest
Bug 35292: (QA follow-up)

Description Lisette Scheer 2023-11-08 16:11:17 UTC
For parity and more workflow options, adding the same option to the new status that updates not for loan on checkout should also have the ability to limit by item type like Bug 25560 did for check in.
Comment 1 Baptiste Wojtkowski (bwoj) 2024-12-04 16:38:06 UTC
Created attachment 175201 [details] [review]
Bug 35292: Database changes
Comment 2 Baptiste Wojtkowski (bwoj) 2024-12-04 16:38:09 UTC
Created attachment 175202 [details] [review]
Bug 35292: Template changes
Comment 3 Baptiste Wojtkowski (bwoj) 2024-12-04 16:38:11 UTC
Created attachment 175203 [details] [review]
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function

Both sysprefs use the same codebase. Hence the recent upgrades for
UpdateNotForLoanStatusOnCheckOut were not applyied to checkout.
In this patch, we refacto code in order to have them both use the same
function.

Test plan:
Do not apply patch:
1 -  Set UpdateNotForLoanStatusOnCheckin to
2: 0
2 - Set  UpdateNotForLoanStatusOnCheckout to
_ALL_:
 0: 2
3 - Check out a book -> Its notforloan status is set to 2
4 - Check in the book -> Its notforloan status is set to 0, you get a
  notification
6 - APPLY PATCH
7 -  Set UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 -  Set UpdateNotForLoanStatusOnCheckOut to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 - Check out a book -> Its notforloan status is set to 3
9 - Check in the book -> Its notforloan status is set to 0, you get a
10 - Check out a continuing resource -> Its notforloan status is set to 4
11 - Check in a continuing resource -> Its notforloan status is set to 0
11 - Check out another type of resource -> Its notforloan status is set to 2
12 - Check in the document -> Its notforloan status is set to 0
  notification
Comment 4 Baptiste Wojtkowski (bwoj) 2024-12-05 13:40:36 UTC
Removing status needs signoff, need to update the test suite
Comment 5 Baptiste Wojtkowski (bwoj) 2024-12-09 16:35:40 UTC
Created attachment 175316 [details] [review]
Bug 35292: Database changes
Comment 6 Baptiste Wojtkowski (bwoj) 2024-12-09 16:35:42 UTC
Created attachment 175317 [details] [review]
Bug 35292: Template changes
Comment 7 Baptiste Wojtkowski (bwoj) 2024-12-09 16:35:44 UTC
Created attachment 175318 [details] [review]
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function

Both sysprefs use the same codebase. Hence the recent upgrades for
UpdateNotForLoanStatusOnCheckOut were not applyied to checkout.
In this patch, we refacto code in order to have them both use the same
function.

Test plan:
Do not apply patch:
1 -  Set UpdateNotForLoanStatusOnCheckin to
2: 0
2 - Set  UpdateNotForLoanStatusOnCheckout to
_ALL_:
 0: 2
3 - Check out a book -> Its notforloan status is set to 2
4 - Check in the book -> Its notforloan status is set to 0, you get a
  notification
6 - APPLY PATCH
7 -  Set UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 -  Set UpdateNotForLoanStatusOnCheckOut to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 - Check out a book -> Its notforloan status is set to 3
9 - Check in the book -> Its notforloan status is set to 0, you get a
10 - Check out a continuing resource -> Its notforloan status is set to 4
11 - Check in a continuing resource -> Its notforloan status is set to 0
11 - Check out another type of resource -> Its notforloan status is set to 2
12 - Check in the document -> Its notforloan status is set to 0
  notification
Comment 8 Baptiste Wojtkowski (bwoj) 2024-12-09 16:35:47 UTC
Created attachment 175319 [details] [review]
Bug 35292: Move tests of UpdateNotforloan together

Note: These patches have been split for sake of understandability for
review but they should probably be squashed
Comment 9 Baptiste Wojtkowski (bwoj) 2024-12-09 16:35:50 UTC
Created attachment 175320 [details] [review]
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 10 Baptiste Wojtkowski (bwoj) 2024-12-09 16:35:52 UTC
Created attachment 175321 [details] [review]
Bug 35292: Add tests for _updateNotForLoanFromYaml

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 11 Baptiste Wojtkowski (bwoj) 2024-12-09 16:35:55 UTC
Created attachment 175322 [details] [review]
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 12 Emmanuel Bétemps 2025-01-13 10:47:22 UTC
Hi,

I just tried this test but it quickly failed (even before applying the patch)


Steps 1 to 2: ok 

Step 3 : ok in UNIMARC (but I had to erase the space  which stands just before the 2 in UpdateNotForLoanStatusOnCheckout)
but not ok in MARC21, the status is not set to 2

Step 4 : in UNIMARC, the status is not set to 0
(I didn't try in MARC21 because it failed before)


is there anything I missed ?
Comment 13 Stephanie Etallaz 2025-03-19 10:31:14 UTC
Same problem as Emmanuel, open a ticket "Bug 39386"
Comment 14 Baptiste Wojtkowski (bwoj) 2025-03-19 11:07:40 UTC Comment hidden (obsolete)
Comment 15 Baptiste Wojtkowski (bwoj) 2025-03-19 11:11:05 UTC
My precedent comment is still confunsing with both sysprefs, so I edit it :p 

Hi,
Thanks for your attention to this bug,

There was an issue in the test plan, hence it can't work. You need to invert the sysprefs

CORRECTED 1&2:
1 -  Set UpdateNotForLoanStatusOnCheckout to
0: 2
2 - Set  UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0


To explain:
UpdateNotForLoanStatusOnCheckout use the old syntax, which we want to update (the purpose of this patch). It should set the notforloanstatus to anything

UpdateNotForLoanStatusOnCheckin uses the new syntax, it should, for our tests, set the notforloanstatus to something which does not prevent
Comment 16 Victor Grousset/tuxayo 2025-03-28 05:26:35 UTC
Better to fix the test plan in the patch.

When training people to test patches, the least overwhelming strategy I found for now to avoid drowning in tons of comments with many old versions of the test plan, is to go to "Attachments" here in the ticket. And click on the date to jump directly to the current patches.
But it will miss messages like the above.

Which might get buried in more comment so not only beginners risk not getting the issue.
Comment 17 Baptiste Wojtkowski (bwoj) 2025-03-28 08:44:39 UTC
Created attachment 179818 [details] [review]
Bug 35292: Database changes
Comment 18 Baptiste Wojtkowski (bwoj) 2025-03-28 08:44:43 UTC
Created attachment 179819 [details] [review]
Bug 35292: Template changes
Comment 19 Baptiste Wojtkowski (bwoj) 2025-03-28 08:44:46 UTC
Created attachment 179820 [details] [review]
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function

Both sysprefs use the same codebase. Hence the recent upgrades for
UpdateNotForLoanStatusOnCheckOut were not applyied to checkout.
In this patch, we refacto code in order to have them both use the same
function.

Test plan:
Do not apply patch:
1 -  Set UpdateNotForLoanStatusOnCheckout to
0: 2
2 - Set  UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0
3 - Check out a book -> Its notforloan status is set to 2
4 - Check in the book -> Its notforloan status is set to 0, you get a
  notification
6 - APPLY PATCH
7 -  Set UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 -  Set UpdateNotForLoanStatusOnCheckOut to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 - Check out a book -> Its notforloan status is set to 3
9 - Check in the book -> Its notforloan status is set to 0, you get a
10 - Check out a continuing resource -> Its notforloan status is set to 4
11 - Check in a continuing resource -> Its notforloan status is set to 0
11 - Check out another type of resource -> Its notforloan status is set to 2
12 - Check in the document -> Its notforloan status is set to 0
  notification
Comment 20 Baptiste Wojtkowski (bwoj) 2025-03-28 08:44:49 UTC
Created attachment 179821 [details] [review]
Bug 35292: Move tests of UpdateNotforloan together

Note: These patches have been split for sake of understandability for
review but they should probably be squashed
Comment 21 Baptiste Wojtkowski (bwoj) 2025-03-28 08:44:52 UTC
Created attachment 179822 [details] [review]
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 22 Baptiste Wojtkowski (bwoj) 2025-03-28 08:44:55 UTC
Created attachment 179823 [details] [review]
Bug 35292: Add tests for _updateNotForLoanFromYaml

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 23 Baptiste Wojtkowski (bwoj) 2025-03-28 08:44:58 UTC
Created attachment 179824 [details] [review]
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 24 Emmanuel Bétemps 2025-03-31 10:17:15 UTC
A problem occured when I tried to apply the patch

error: sha1 information is lacking or useless (installer/data/mysql/mandatory/sysprefs.sql).
error: could not build fake ancestor
Patch failed at 0001 Bug 35292: Database changes
[33mhint: Use 'git am --show-current-patch=diff' to see the failed patch[m
When you have resolved this problem run "git bz apply --continue".
If you would prefer to skip this patch, instead run "git bz apply --skip".
To restore the original branch and stop patching run "git bz apply --abort".
Patch left in /tmp/Bug-35292-Database-changes-uulcmt0i.patch
Comment 25 Baptiste Wojtkowski (bwoj) 2025-04-01 09:28:28 UTC
Created attachment 180101 [details] [review]
Bug 35292: Database changes
Comment 26 Baptiste Wojtkowski (bwoj) 2025-04-01 09:28:32 UTC
Created attachment 180102 [details] [review]
Bug 35292: Template changes
Comment 27 Baptiste Wojtkowski (bwoj) 2025-04-01 09:28:35 UTC
Created attachment 180103 [details] [review]
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function

Both sysprefs use the same codebase. Hence the recent upgrades for
UpdateNotForLoanStatusOnCheckOut were not applyied to checkout.
In this patch, we refacto code in order to have them both use the same
function.

Test plan:
Do not apply patch:
1 -  Set UpdateNotForLoanStatusOnCheckout to
0: 2
2 - Set  UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0
3 - Check out a book -> Its notforloan status is set to 2
4 - Check in the book -> Its notforloan status is set to 0, you get a
  notification
6 - APPLY PATCH
7 -  Set UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 -  Set UpdateNotForLoanStatusOnCheckOut to
_ALL_:
 0: 2

BK:
 0: 3

CR:
 0: 4

8 - Check out a book -> Its notforloan status is set to 3
9 - Check in the book -> Its notforloan status is set to 0, you get a
10 - Check out a continuing resource -> Its notforloan status is set to 4
11 - Check in a continuing resource -> Its notforloan status is set to 0
11 - Check out another type of resource -> Its notforloan status is set to 2
12 - Check in the document -> Its notforloan status is set to 0
  notification
Comment 28 Baptiste Wojtkowski (bwoj) 2025-04-01 09:28:39 UTC
Created attachment 180104 [details] [review]
Bug 35292: Move tests of UpdateNotforloan together

Note: These patches have been split for sake of understandability for
review but they should probably be squashed
Comment 29 Baptiste Wojtkowski (bwoj) 2025-04-01 09:28:42 UTC
Created attachment 180105 [details] [review]
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 30 Baptiste Wojtkowski (bwoj) 2025-04-01 09:28:45 UTC
Created attachment 180106 [details] [review]
Bug 35292: Add tests for _updateNotForLoanFromYaml

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 31 Baptiste Wojtkowski (bwoj) 2025-04-01 13:15:39 UTC
Created attachment 180181 [details] [review]
Bug 35292: Database changes

bsoletes: 180101 - Bug 35292: Database changes
Comment 32 Baptiste Wojtkowski (bwoj) 2025-04-01 13:15:43 UTC
Created attachment 180182 [details] [review]
Bug 35292: Template changes
Comment 33 Baptiste Wojtkowski (bwoj) 2025-04-01 13:15:46 UTC
Created attachment 180183 [details] [review]
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function

Both sysprefs use the same codebase. Hence the recent upgrades for
UpdateNotForLoanStatusOnCheckOut were not applyied to checkout.
In this patch, we refacto code in order to have them both use the same
function.

Test plan:
Do not apply patch:
1 -  Set UpdateNotForLoanStatusOnCheckout to
0: 2
2 - Set  UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0
3 - Check out a book -> Its notforloan status is set to 2
4 - Check in the book -> Its notforloan status is set to 0, you get a
  notification
6 - APPLY PATCH
7 -  Set UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 -  Set UpdateNotForLoanStatusOnCheckOut to
_ALL_:
 0: 2

BK:
 0: 3

CR:
 0: 4

8 - Check out a book -> Its notforloan status is set to 3
9 - Check in the book -> Its notforloan status is set to 0, you get a
10 - Check out a continuing resource -> Its notforloan status is set to 4
11 - Check in a continuing resource -> Its notforloan status is set to 0
11 - Check out another type of resource -> Its notforloan status is set to 2
12 - Check in the document -> Its notforloan status is set to 0
  notification
Comment 34 Baptiste Wojtkowski (bwoj) 2025-04-01 13:15:49 UTC
Created attachment 180184 [details] [review]
Bug 35292: Move tests of UpdateNotforloan together

Note: These patches have been split for sake of understandability for
review but they should probably be squashed
Comment 35 Baptiste Wojtkowski (bwoj) 2025-04-01 13:15:53 UTC
Created attachment 180185 [details] [review]
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 36 Baptiste Wojtkowski (bwoj) 2025-04-01 13:15:56 UTC
Created attachment 180186 [details] [review]
Bug 35292: Add tests for _updateNotForLoanFromYaml

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 37 Baptiste Wojtkowski (bwoj) 2025-04-01 14:52:12 UTC
Created attachment 180210 [details] [review]
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 38 Baptiste Wojtkowski (bwoj) 2025-04-01 15:27:43 UTC
Created attachment 180212 [details] [review]
Bug 35292: Database changes
Comment 39 Baptiste Wojtkowski (bwoj) 2025-04-01 15:27:47 UTC
Created attachment 180213 [details] [review]
Bug 35292: Template changes
Comment 40 Baptiste Wojtkowski (bwoj) 2025-04-01 15:27:50 UTC
Created attachment 180214 [details] [review]
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function

Both sysprefs use the same codebase. Hence the recent upgrades for
UpdateNotForLoanStatusOnCheckOut were not applyied to checkout.
In this patch, we refacto code in order to have them both use the same
function.

Test plan:
Do not apply patch:
1 -  Set UpdateNotForLoanStatusOnCheckout to
0: 2
2 - Set  UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0
3 - Check out a book -> Its notforloan status is set to 2
4 - Check in the book -> Its notforloan status is set to 0, you get a
  notification
6 - APPLY PATCH
7 -  Set UpdateNotForLoanStatusOnCheckin to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 -  Set UpdateNotForLoanStatusOnCheckOut to
_ALL_:
 2: 0

BK:
 3: 0

CR:
 4: 0

8 - Check out a book -> Its notforloan status is set to 3
9 - Check in the book -> Its notforloan status is set to 0, you get a
10 - Check out a continuing resource -> Its notforloan status is set to 4
11 - Check in a continuing resource -> Its notforloan status is set to 0
11 - Check out another type of resource -> Its notforloan status is set to 2
12 - Check in the document -> Its notforloan status is set to 0
  notification
Comment 41 Baptiste Wojtkowski (bwoj) 2025-04-01 15:27:54 UTC
Created attachment 180215 [details] [review]
Bug 35292: Move tests of UpdateNotforloan together

Note: These patches have been split for sake of understandability for
review but they should probably be squashed
Comment 42 Baptiste Wojtkowski (bwoj) 2025-04-01 15:27:57 UTC
Created attachment 180216 [details] [review]
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 43 Baptiste Wojtkowski (bwoj) 2025-04-01 15:28:00 UTC
Created attachment 180217 [details] [review]
Bug 35292: Add tests for _updateNotForLoanFromYaml

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 44 Baptiste Wojtkowski (bwoj) 2025-04-01 15:28:04 UTC
Created attachment 180218 [details] [review]
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest

Note: These patches have been split for sake of understandability for
review but they should probably be squashe
Comment 45 Emmanuel Bétemps 2025-04-04 12:07:02 UTC
Created attachment 180632 [details] [review]
Bug 35292: Database changes

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Comment 46 Emmanuel Bétemps 2025-04-04 12:07:06 UTC
Created attachment 180633 [details] [review]
Bug 35292: Template changes

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Comment 47 Emmanuel Bétemps 2025-04-04 12:07:10 UTC
Created attachment 180634 [details] [review]
Bug 35292: Have UpdateNotForLoanStatusOnCheckOut and UpdateNotForLoanStatusOnCheckIn use the same function

Both sysprefs use the same codebase. Hence the recent upgrades for
UpdateNotForLoanStatusOnCheckOut were not applyied to checkout.
In this patch, we refacto code in order to have them both use the same
function.

1 -  Set UpdateNotForLoanStatusOnCheckin to
2: 0
2 - Set  UpdateNotForLoanStatusOnCheckout to
_ALL_:
0: 2
3 - Check out a book -> Its notforloan status is set to 2
3b - Check you have 2, 3 and 4 in notforloan, if not add those values with any description
4 - Check in the book -> Its notforloan status is set to 0, you get a
 notification
6 - APPLY PATCH and update database
7 -  Set UpdateNotForLoanStatusOnCheckin to
_ALL_:
2: 0

BK:
3: 0

CR:
4: 0

8 -  Set UpdateNotForLoanStatusOnCheckOut to
_ALL_:
0: 2

BK:
0: 3

CR:
0: 4

8 - Check out a book -> Its notforloan status is set to 3
9 - Check in the book -> Its notforloan status is set to 0, you get a notification
10 - Check out a continuing resource -> Its notforloan status is set to 4
11 - Check in a continuing resource -> Its notforloan status is set to 0
11 - Check out another type of resource -> Its notforloan status is set to 2
12 - Check in the document -> Its notforloan status is set to 0

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Comment 48 Emmanuel Bétemps 2025-04-04 12:07:13 UTC
Created attachment 180635 [details] [review]
Bug 35292: Move tests of UpdateNotforloan together

Note: These patches have been split for sake of understandability for
review but they should probably be squashed

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Comment 49 Emmanuel Bétemps 2025-04-04 12:07:17 UTC
Created attachment 180636 [details] [review]
Bug 35292: Update tests for UpdateNotForloanStatusOnCheckout

Note: These patches have been split for sake of understandability for
review but they should probably be squashe

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Comment 50 Emmanuel Bétemps 2025-04-04 12:07:21 UTC
Created attachment 180637 [details] [review]
Bug 35292: Add tests for _updateNotForLoanFromYaml

Note: These patches have been split for sake of understandability for
review but they should probably be squashe

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Comment 51 Emmanuel Bétemps 2025-04-04 12:07:26 UTC
Created attachment 180638 [details] [review]
Bug 35292: Move tests for UpdateNotForLoanStatusOnCheckin in a subtest

Note: These patches have been split for sake of understandability for
review but they should probably be squashe

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Comment 52 Victor Grousset/tuxayo 2025-04-04 12:33:22 UTC Comment hidden (obsolete)
Comment 53 Victor Grousset/tuxayo 2025-04-04 12:43:13 UTC
I tried to do a one character fix via the bugzilla web interface ("edit attachmement as comment") and it didn't work ^^"
Comment 54 Victor Grousset/tuxayo 2025-04-04 13:27:37 UTC
(1) matches the items'
vs
(1) matches the items


In dbrev vs new db
Comment 55 Baptiste Wojtkowski (bwoj) 2025-04-04 13:44:54 UTC
Created attachment 180646 [details] [review]
Bug 35292: (QA follow-up)

To squash with the main patches