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

--- Comment #10 from Matt Blenkinsop <[email protected]> ---
Created attachment 206269
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=206269&action=edit
Bug 42623: (QA follow-up) Resolve runtime parameter limits to branchcodes

The library_group branch of _confirm_branch_param_allowed and the Library
runtime parameter dropdown only looked at qualifying library groups. A
report limited to a library that is not in any reports group therefore
allowed any branch, while the saved reports list hid the report. Both now
use library_group_limit_branchcodes from bug 42621 so an ungrouped library
is enforced as a group of one.

The dropdown filter is now only applied when the report has limits. A
report with no limits previously produced an empty IN () clause and an
empty Library dropdown in library group mode.

Also fixes the top-level test plan in t/db_dependent/Koha/Reports.t, which
was not incremented when the _confirm_branch_param_allowed subtest was
added.

Test plan:
1. Set LimitReportsBy to Library group, create a group containing
   Centerville and Fairfield with "Limit report access by group" ticked
2. Create a report with a <<Library|branches>> runtime parameter and no
   library limit. Run it: the dropdown lists all libraries
3. Limit the report to Fairview only. Run it: the dropdown lists Fairview
   only. Amend sql_params in the URL to Centerville: access is refused
4. Limit the report to Centerville. Run it: the dropdown lists Centerville
   and Fairfield
5. prove t/db_dependent/Koha/Reports.t

Co-Authored-By: Claude Fable 5.1 <[email protected]>

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to