[Koha-bugs] [Bug 35746] Multiple selections for parameters used in the IN function

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Thu Jan 11 18:05:19 CET 2024


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35746

--- Comment #5 from Brendan Lawlor <blawlor at clamsnet.org> ---
Somehow my test plan did not get attached to this patch.

This is a work in progress patch that adds a new syntax to reports for
multiselect similar to adding <<Item type|itemtypes:all>>

Currently the patch adds the syntax to the report allowing you to select
multiple authorized values when you run the report. The multiselected values
are passed as multiple url parameters, but those parameters will need to be
parsed and formatted for the query to work. I think this part could be done
using either javascript to override the default functionality of the
multiselect to send a single parameter, or done in the perl somewhere. 

Test Plan:
1. Try writing a report with the new syntax ie.
   WHERE itemtype in (<<Select item types|itemtypes:in>>)
2. Save the report and notice there is an error
3. Apply patch
4. Write a report with the new syntax
   select * 
   from items 
   where 
   itype in ( <<Select item types|itemtypes:in>> )
5. Note the report now saves without error
6. Run the report
7. Note that you can now select multiple parameters in the dropdown
8. Click 'Run the report'
9. Note the report fails to run
10. Check the url to see the multiselected parameters are included

TODO: Make the multi selected params insert into the SQL as a comma separated
list of strings.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list