Bug 34478: Add 'op' to reports/guided_reports - WIP
Bug 34478: [TO SQUASH] Add 'op' to reports/guided_reports
Found bug 36071 when working on this. This is not a regression from this
patch.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
[% UNLESS ( errors ) # Unless there are errors saving a report %]
<divclass="btn-group">
<aid="runreport"class="btn btn-default"href="/cgi-bin/koha/reports/guided_reports.pl?reports=[% id | html %]&phase=Run%20this%20report">
<aid="runreport"class="btn btn-default"href="/cgi-bin/koha/reports/guided_reports.pl?id=[% id | html %]&op=run">
<iclass="fa fa-play"></i> Run report
</a>
</div>
@ -71,7 +78,7 @@
<ulclass="dropdown-menu">
[% FOREACH t IN templates %]
<li>
<aid="runreport"class="btn btn-default"href="/cgi-bin/koha/reports/guided_reports.pl?reports=[% id | html %]&phase=Run%20this%20report&template=[% t.id | html %][% PROCESS params %]">
<aid="runreport"class="btn btn-default"href="/cgi-bin/koha/reports/guided_reports.pl?id=[% id | html %]&op=run&template=[% t.id | html %][% PROCESS params %]">
[% t.name | html %]
</a>
</li>
@ -130,11 +137,11 @@
<divclass="btn-group">
<buttonclass="btn btn-default dropdown-toggle"aria-haspopup="menu"aria-label="Select format and download report results"data-toggle="dropdown"id="format"><iclass="fa fa-download"></i> Download <spanclass="caret"></span></button>
<ulclass="dropdown-menu">
<li><aid="csv"href="/cgi-bin/koha/reports/guided_reports.pl?reports=1&phase=Export&format=csv&report_id=[% id | html %]&reportname=[% name |uri %][% PROCESS params %]">[% PROCESS 'delimiter_text.inc' %]</a></li>
<li><aid="tab"href="/cgi-bin/koha/reports/guided_reports.pl?reports=1&phase=Export&format=tab&report_id=[% id | html %]&reportname=[% name |uri %][% PROCESS params %]">Tab separated text</a></li>
<li><aid="ods"href="/cgi-bin/koha/reports/guided_reports.pl?reports=1&phase=Export&format=ods&report_id=[% id | html %]&reportname=[% name |uri %][% PROCESS params %]">Open Document Spreadsheet</a></li>
<li><aid="csv"href="/cgi-bin/koha/reports/guided_reports.pl?op=export&format=csv&id=[% id | html %]&reportname=[% name |uri %][% PROCESS params %]">[% PROCESS 'delimiter_text.inc' %]</a></li>
<li><aid="tab"href="/cgi-bin/koha/reports/guided_reports.pl?op=export&format=tab&id=[% id | html %]&reportname=[% name |uri %][% PROCESS params %]">Tab separated text</a></li>
<li><aid="ods"href="/cgi-bin/koha/reports/guided_reports.pl?op=export&format=ods&id=[% id | html %]&reportname=[% name |uri %][% PROCESS params %]">Open Document Spreadsheet</a></li>
[% IF processed_notice_title %]
<li><aid="template"href="/cgi-bin/koha/reports/guided_reports.pl?reports=1&phase=Export&format=template&report_id=[% id | html %]&template=[% template_id | html %]&reportname=[% name |uri %][% PROCESS params %]">Rendered template ([% processed_notice_title | html %])</a></li>
<li><aid="template"href="/cgi-bin/koha/reports/guided_reports.pl?op=export&format=template&id=[% id | html %]&template=[% template_id | html %]&reportname=[% name |uri %][% PROCESS params %]">Rendered template ([% processed_notice_title | html %])</a></li>
<aclass="btn btn-default fetch_chart_data"href="/cgi-bin/koha/reports/guided_reports.pl?reports=[% id | html %]&phase=Run this report&reportname=[% name |uri %][% PROCESS params %]&want_full_chart=1"><iclass="fa fa-chart-bar"></i> Fetch all data for chart</a>
<aclass="btn btn-default fetch_chart_data"href="/cgi-bin/koha/reports/guided_reports.pl?id=[% id | html %]&op=run&reportname=[% name |uri %][% PROCESS params %]&want_full_chart=1"><iclass="fa fa-chart-bar"></i> Fetch all data for chart</a>
<ul class="dropdown-menu pull-right" role="menu" aria-labelledby="reportactions[% savedreport.id | html %]">
<li><a href="/cgi-bin/koha/reports/guided_reports.pl?reports=[% savedreport.id | uri %]&phase=Show%20SQL"><i class="fa fa-search"></i> View</a></li>
<li><a href="/cgi-bin/koha/reports/guided_reports.pl?id=[% savedreport.id | uri %]&op=show"><i class="fa fa-search"></i> View</a></li>
<li>
<a href="/cgi-bin/koha/reports/guided_reports.pl?reports=[% savedreport.id | uri %]&phase=Show%20SQL" class="preview_sql" data-reportid="[% savedreport.id | html %]">
<a href="/cgi-bin/koha/reports/guided_reports.pl?id=[% savedreport.id | uri %]&op=show" class="preview_sql" data-reportid="[% savedreport.id | html %]">
<i class="fa-solid fa-eye"></i> Preview SQL
</a>
</li>
[% IF ( CAN_user_reports_create_reports ) %]
<li><a href="/cgi-bin/koha/reports/guided_reports.pl?reports=[% savedreport.id | uri %]&phase=Edit%20SQL"><i class="fa-solid fa-pencil" aria-hidden="true"></i> Edit</a></li>
<li><a title="Duplicate this saved report" href="/cgi-bin/koha/reports/guided_reports.pl?phase=Create report from existing&report_id=[% savedreport.id | uri %]"><i class="fa fa-copy"></i> Duplicate</a></li>
<li><a href="/cgi-bin/koha/reports/guided_reports.pl?id=[% savedreport.id | uri %]&op=edit_form"><i class="fa-solid fa-pencil" aria-hidden="true"></i> Edit</a></li>
<li><a title="Duplicate this saved report" href="/cgi-bin/koha/reports/guided_reports.pl?op=duplicate&id=[% savedreport.id | uri %]"><i class="fa fa-copy"></i> Duplicate</a></li>
[% END %]
[% IF (Koha.Preference('Mana') == 1) %]
<li><a class="ShareButton" data-toggle="modal" href="#mana_share_report" title="Share your report with Mana Knowledge Base"><i class="fa fa-share-alt"></i> Share</a></li>
[% END %]
<li><a href="/cgi-bin/koha/tools/scheduler.pl?id=[% savedreport.id | uri %]"><i class="fa-solid fa-clock"></i> Schedule</a></li>
[% IF ( CAN_user_reports_delete_reports ) %]
<li><a class="confirmdelete" title="Delete this saved report" href="/cgi-bin/koha/reports/guided_reports.pl?reports=[% savedreport.id | html %]&phase=Delete%20Saved"><i class="fa fa-trash-can"></i> Delete</a></li>
[%- cardnumbers = PROCESS batch_list results=results batch_type='cardnumber' | trim | html %][% IF cardnumbers %][% SET batch_cardnumbers = 1 %][% cardnumbers | html %][% END -%]