Bug 32803 - EnableItemGroups and EnableItemGroupHolds options are wrong
Summary: EnableItemGroups and EnableItemGroupHolds options are wrong
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: System Administration (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low minor (vote)
Assignee: Caroline Cyr La Rose
QA Contact: Jonathan Druart
URL:
Keywords:
Depends on: 24857 24860
Blocks:
  Show dependency treegraph
 
Reported: 2023-02-02 16:49 UTC by Caroline Cyr La Rose
Modified: 2023-12-28 20:43 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.05.00,22.11.04


Attachments
Bug 32803 - EnableItemGroups and EnableItemGroupHolds options are wrong (3.11 KB, patch)
2023-02-02 17:47 UTC, Caroline Cyr La Rose
Details | Diff | Splinter Review
Bug 32803 - EnableItemGroups and EnableItemGroupHolds options are wrong (3.19 KB, patch)
2023-02-06 11:34 UTC, Matt Blenkinsop
Details | Diff | Splinter Review
Bug 32803: EnableItemGroups and EnableItemGroupHolds options are wrong (3.32 KB, patch)
2023-02-23 09:52 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Caroline Cyr La Rose 2023-02-02 16:49:34 UTC
I played around with item groups and now in my About page > System information, I have an error message

System preference 'EnableItemGroups' must be '0' or '1', but is 'no'.

System preference 'EnableItemGroupHolds' must be '0' or '1', but is 'no'.

I think it may be the options in koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref that are yes/no, but should be 1/0?
Comment 1 Caroline Cyr La Rose 2023-02-02 16:53:22 UTC
The installer data (installer/data/mysql/mandatory/sysprefs.sql) and dbrevs (installer/data/mysql/db_revs/220600014.pl and installer/data/mysql/db_revs/220600078.pl) insert 0 for both by default. So I think that part is OK.

It's only when you change them manually in the interface.
Comment 2 Caroline Cyr La Rose 2023-02-02 17:47:18 UTC
Created attachment 146022 [details] [review]
Bug 32803 - EnableItemGroups and EnableItemGroupHolds options are wrong

This patch corrects the options for the EnableItemGroups and
EnableItemGroupHolds system preferences.

To test:
1. Enable EnableItemGroups and EnableItemGroupHolds system preferences
   1.1. Go to Administration > Global system preferences
   1.2. Search for EnableItemGroup (no s, to get both)
   1.3. Enable both EnableItemGroups and EnableItemGroupHolds
   1.4. Click Save all Circulation preferences
2. Go to About Koha > System information
   --> There is a warning message
3. Go to a bibliographic record with at least one item
   --> The item group tab is displayed
4. Create an item group
   4.1. Click New item group
   4.2. Enter a name
   4.3. Click Submit
   4.4. In the Holdings tab, select the item
   4.5. Click on Add/move to item group
   4.6. Click Set item group
5. Place a hold on the item group
   5.1. Click Place hold
   5.2. Search for a patron
   5.3. In the 'Hold next available item from an item group' section, select the item group
   5.4. Click Place hold
   --> Placing a hold is possible
6. Disable EnableItemGroups and EnableItemGroupHolds system preferences
   1.1. Go to Administration > Global system preferences
   1.2. Search for EnableItemGroup (no s, to get both)
   1.3. Disable both EnableItemGroups and EnableItemGroupHolds
   1.4. Click Save all Circulation preferences
7. Go to About Koha > System information
   --> There is a warning message
8. Apply patch
9. Redo steps 1 and 2
   --> There is no warning
10. Redo step 3
   --> The item group tab is displayed
11. Redo steps 4 and 5
   --> Placing a hold is possible
12. Redo steps 6 and 7
   --> There is no warning
Comment 3 Matt Blenkinsop 2023-02-06 11:34:06 UTC
Created attachment 146263 [details] [review]
Bug 32803 - EnableItemGroups and EnableItemGroupHolds options are wrong

This patch corrects the options for the EnableItemGroups and
EnableItemGroupHolds system preferences.

To test:
1. Enable EnableItemGroups and EnableItemGroupHolds system preferences
   1.1. Go to Administration > Global system preferences
   1.2. Search for EnableItemGroup (no s, to get both)
   1.3. Enable both EnableItemGroups and EnableItemGroupHolds
   1.4. Click Save all Circulation preferences
2. Go to About Koha > System information
   --> There is a warning message
3. Go to a bibliographic record with at least one item
   --> The item group tab is displayed
4. Create an item group
   4.1. Click New item group
   4.2. Enter a name
   4.3. Click Submit
   4.4. In the Holdings tab, select the item
   4.5. Click on Add/move to item group
   4.6. Click Set item group
5. Place a hold on the item group
   5.1. Click Place hold
   5.2. Search for a patron
   5.3. In the 'Hold next available item from an item group' section, select the item group
   5.4. Click Place hold
   --> Placing a hold is possible
6. Disable EnableItemGroups and EnableItemGroupHolds system preferences
   1.1. Go to Administration > Global system preferences
   1.2. Search for EnableItemGroup (no s, to get both)
   1.3. Disable both EnableItemGroups and EnableItemGroupHolds
   1.4. Click Save all Circulation preferences
7. Go to About Koha > System information
   --> There is a warning message
8. Apply patch
9. Redo steps 1 and 2
   --> There is no warning
10. Redo step 3
   --> The item group tab is displayed
11. Redo steps 4 and 5
   --> Placing a hold is possible
12. Redo steps 6 and 7
   --> There is no warning

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Comment 4 Jonathan Druart 2023-02-23 09:52:15 UTC
Created attachment 147209 [details] [review]
Bug 32803: EnableItemGroups and EnableItemGroupHolds options are wrong

This patch corrects the options for the EnableItemGroups and
EnableItemGroupHolds system preferences.

To test:
1. Enable EnableItemGroups and EnableItemGroupHolds system preferences
   1.1. Go to Administration > Global system preferences
   1.2. Search for EnableItemGroup (no s, to get both)
   1.3. Enable both EnableItemGroups and EnableItemGroupHolds
   1.4. Click Save all Circulation preferences
2. Go to About Koha > System information
   --> There is a warning message
3. Go to a bibliographic record with at least one item
   --> The item group tab is displayed
4. Create an item group
   4.1. Click New item group
   4.2. Enter a name
   4.3. Click Submit
   4.4. In the Holdings tab, select the item
   4.5. Click on Add/move to item group
   4.6. Click Set item group
5. Place a hold on the item group
   5.1. Click Place hold
   5.2. Search for a patron
   5.3. In the 'Hold next available item from an item group' section, select the item group
   5.4. Click Place hold
   --> Placing a hold is possible
6. Disable EnableItemGroups and EnableItemGroupHolds system preferences
   1.1. Go to Administration > Global system preferences
   1.2. Search for EnableItemGroup (no s, to get both)
   1.3. Disable both EnableItemGroups and EnableItemGroupHolds
   1.4. Click Save all Circulation preferences
7. Go to About Koha > System information
   --> There is a warning message
8. Apply patch
9. Redo steps 1 and 2
   --> There is no warning
10. Redo step 3
   --> The item group tab is displayed
11. Redo steps 4 and 5
   --> Placing a hold is possible
12. Redo steps 6 and 7
   --> There is no warning

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>

JD Amended commit message: * Commit title does not start with 'Bug XXXXX: '
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 5 Tomás Cohen Arazi 2023-03-02 12:39:35 UTC
Pushed to master for 23.05.

Nice work everyone, thanks!
Comment 6 Matt Blenkinsop 2023-03-03 12:13:39 UTC
Nice work everyone!

Pushed to stable for 22.11.x
Comment 7 Lucas Gass 2023-03-10 14:52:34 UTC
Missing dependencies for 22.05, no backport.