[Bug 39298] New: Runtime parameters don't work with report templates on first run
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 Bug ID: 39298 Summary: Runtime parameters don't work with report templates on first run Change sponsored?: --- Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Reports Assignee: koha-bugs@lists.koha-community.org Reporter: dcook@prosentient.com.au QA Contact: testopia@bugs.koha-community.org If you have a SQL report with runtime parameters, and you click "Run with template", it'll prompt for runtime parameter inputs, but then it will render a normal SQL output and not the template output. If you do the same thing again, it will work the second time, because the param_name and sql_params URL parameters are now added to the link. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |dcook@prosentient.com.au |ity.org | -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 --- Comment #1 from David Cook <dcook@prosentient.com.au> --- Created attachment 179136 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=179136&action=edit Bug 39298: Add runtime parameter support to report templates This change makes it so that you can provide runtime parameters and use "Run with template". Test plan: 0. Apply the patch and koha-plack --restart kohadev 1. Create a report template. For example: <table> <tr><th>Transformed Biblionumber</th></tr> [% FOREACH row IN data %] <tr><td>Biblionumber [% row.biblionumber %]</td></tr> [% END %] </table> 2. Create a SQL report with a runtime parameter. For example: SELECT biblionumber FROM biblio WHERE biblionumber > <<biblionumber>> 3. Run the report using "Run with template" 4. Specify a biblionumber of 1 5. Click "Run the report" 6. Note that the output is the template output and not regular SQL output -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #179136|0 |1 is obsolete| | --- Comment #2 from David Nind <david@davidnind.com> --- Created attachment 179145 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=179145&action=edit Bug 39298: Add runtime parameter support to report templates This change makes it so that you can provide runtime parameters and use "Run with template". Test plan: 0. Apply the patch and koha-plack --restart kohadev 1. Create a report template. For example: <table> <tr><th>Transformed Biblionumber</th></tr> [% FOREACH row IN data %] <tr><td>Biblionumber [% row.biblionumber %]</td></tr> [% END %] </table> 2. Create a SQL report with a runtime parameter. For example: SELECT biblionumber FROM biblio WHERE biblionumber > <<biblionumber>> 3. Run the report using "Run with template" 4. Specify a biblionumber of 1 5. Click "Run the report" 6. Note that the output is the template output and not regular SQL output Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |david@davidnind.com --- Comment #3 from David Nind <david@davidnind.com> --- Testing notes (using KTD) - replicating the issue before applying the patch: 1. The first time you run the report using the report template option, it will look like a normal report result - with standard pagination and a column with just the biblionumber. 2. If you then go "Run with template" again, you will then get your customised output, in this case a table with all the results formatted using the template: a table heading called "Transformed Biblionumber" and then rows with "Biblionumber X" (where X = a number). -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |julian.maurice@biblibre.com QA Contact|testopia@bugs.koha-communit |julian.maurice@biblibre.com |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #179145|0 |1 is obsolete| | --- Comment #4 from Julian Maurice <julian.maurice@biblibre.com> --- Created attachment 180354 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=180354&action=edit Bug 39298: Add runtime parameter support to report templates This change makes it so that you can provide runtime parameters and use "Run with template". Test plan: 0. Apply the patch and koha-plack --restart kohadev 1. Create a report template. For example: <table> <tr><th>Transformed Biblionumber</th></tr> [% FOREACH row IN data %] <tr><td>Biblionumber [% row.biblionumber %]</td></tr> [% END %] </table> 2. Create a SQL report with a runtime parameter. For example: SELECT biblionumber FROM biblio WHERE biblionumber > <<biblionumber>> 3. Run the report using "Run with template" 4. Specify a biblionumber of 1 5. Click "Run the report" 6. Note that the output is the template output and not regular SQL output Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Julian Maurice <julian.maurice@biblibre.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 --- Comment #5 from Julian Maurice <julian.maurice@biblibre.com> --- Created attachment 180355 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=180355&action=edit Bug 39298: (QA follow-up) Add missing html filter Signed-off-by: Julian Maurice <julian.maurice@biblibre.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA --- Comment #6 from Julian Maurice <julian.maurice@biblibre.com> --- I didn't know about the report template feature, so for future references: report templates are created with the "Notices & slips" tool. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 --- Comment #7 from David Cook <dcook@prosentient.com.au> --- (In reply to Julian Maurice from comment #6)
I didn't know about the report template feature, so for future references: report templates are created with the "Notices & slips" tool.
I only learned about it recently myself. It managed to sneak into Koha without too much advertisement I think. A scary feature in a number of ways, but also quite interesting. Using bug 39296 a person can use the entire MARC record for generating reports. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to main Version(s)| |25.05.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 --- Comment #8 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Pushed for 25.05! Well done everyone, thank you! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)|25.05.00 |25.05.00,24.11.08 released in| | CC| |fridolin.somers@biblibre.co | |m Status|Pushed to main |Pushed to stable --- Comment #9 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 24.11.x for 24.11.08 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |Needs documenting --- Comment #10 from Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> --- Not backporting to 22.11.x as it wasn't backported to 24.05.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39298 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs documenting |RESOLVED Resolution|--- |FIXED --- Comment #11 from David Nind <david@davidnind.com> --- Bug fix, no changes to the manual required. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org