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

--- Comment #7 from Kyle M Hall (khall) <[email protected]> ---
Created attachment 203795
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=203795&action=edit
Bug 42585: Add Analyze button to the reports editor

This patch adds an Analyze button to the SQL editor on
guided_reports.pl. Clicking it opens a modal that prompts for any
placeholder values, calls the REST endpoint and lists the findings, so
a librarian can check a report before saving or running it.

Placeholder dropdowns are filled from the matching lookup table for the
common placeholder types (branches, categorycode, itemtypes) and from
the authorised values for the rest, so the librarian picks a real value
instead of typing a code.

Test Plan:
1) Apply this patch
2) Restart all the things!
3) Create a new report with the SQL "SELECT barcode FROM items"
4) Note the new Analyze button beside "Save report"!
5) Click it, then click "Run analysis", note the empty findings list!
6) Change the SQL to "UPDATE borrowers SET surname='X' WHERE 1=1" and
   analyze again, note the high severity forbidden_statement finding!
7) Change the SQL to "SELECT * FROM borrowers WHERE branchcode =
   <<Branch|branches>>" and analyze again, note the modal prompts for a
   branch with a dropdown of your real branches!

-- 
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