Bug 36241

Summary: ILL Batches are broken
Product: Koha Reporter: Pedro Amorim <pedro.amorim>
Component: ILLAssignee: Pedro Amorim <pedro.amorim>
Status: RESOLVED FIXED QA Contact: Martin Renvoize <martin.renvoize>
Severity: critical    
Priority: P5 - low CC: david, fridolin.somers, martin.renvoize, nugged, pedro.amorim, victor
Version: MainKeywords: regression
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.05.00
Bug Depends on: 34478    
Bug Blocks: 36273, 36130, 36249    
Attachments: Bug 36241: Fix wrong cud-search
Bug 36241: Update missing query_type => op in ill-batch.inc
Bug 36241: Fix wrong cud-search
Bug 36241: Update missing query_type => op in ill-batch.inc

Description Pedro Amorim 2024-03-06 09:45:00 UTC
Caused by bash op_must_start_with_cud-perl.sh
Comment 1 Pedro Amorim 2024-03-06 09:57:32 UTC
Created attachment 162808 [details] [review]
Bug 36241: Fix wrong cud-search

This line is supposed to searhc for plugins with the method 'provides_api' which returns a {type => 'search'} entry among others.
This has nothing to do with search vs cud-search from  in forms
Comment 2 Pedro Amorim 2024-03-06 09:57:36 UTC
Created attachment 162809 [details] [review]
Bug 36241: Update missing query_type => op in ill-batch.inc

Test plan:
- Add 'FreeForm' backend and enable ILLModule, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
- Install a metadata enrichment plugin, e.g.:
https://github.com/PTFS-Europe/koha-plugin-api-pubmed/releases
- Add 5 batches, run the following command in kshell:
for x in {1..5}; do echo "INSERT INTO illbatches (name, backend, library_id, status_code, patron_id) VALUES ('$x', 'FreeForm', 'CPL', 'NEW', 52);"; done | koha-mysql kohadev
- Visit ILL batches page:
<INTRA_URL>/cgi-bin/koha/ill/ill-requests.pl?method=batch_list
- Confirm no batches are shown. Apply patch. Repeat.
Comment 3 Martin Renvoize 2024-03-07 08:08:39 UTC
Created attachment 162863 [details] [review]
Bug 36241: Fix wrong cud-search

This line is supposed to searhc for plugins with the method 'provides_api' which returns a {type => 'search'} entry among others.
This has nothing to do with search vs cud-search from  in forms

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 4 Martin Renvoize 2024-03-07 08:08:42 UTC
Created attachment 162864 [details] [review]
Bug 36241: Update missing query_type => op in ill-batch.inc

Test plan:
- Add 'FreeForm' backend and enable ILLModule, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
- Install a metadata enrichment plugin, e.g.:
https://github.com/PTFS-Europe/koha-plugin-api-pubmed/releases
- Add 5 batches, run the following command in kshell:
for x in {1..5}; do echo "INSERT INTO illbatches (name, backend, library_id, status_code, patron_id) VALUES ('$x', 'FreeForm', 'CPL', 'NEW', 52);"; done | koha-mysql kohadev
- Visit ILL batches page:
<INTRA_URL>/cgi-bin/koha/ill/ill-requests.pl?method=batch_list
- Confirm no batches are shown. Apply patch. Repeat.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 5 Martin Renvoize 2024-03-07 08:09:41 UTC
Trivial patch fixes the issue, gong straight for PQA
Comment 6 Katrin Fischer 2024-03-07 15:38:18 UTC
Pushed for 24.05!

Well done everyone, thank you!
Comment 7 Fridolin Somers 2024-04-17 08:45:42 UTC
Depends on Bug 34478 not in 23.11.x