Koha/koha-tmpl/intranet-tmpl/prog/en/includes/acquisitions-toolbar.inc
Jonathan Druart 5825026448 Bug 21526: uri escape TT variables when used in 'a href'
This patch has been generated with the script provided on bug 21576.
It only affects variable used in the href attribute of a link *when*
href it the first attribute of the node (grep "a href")

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
2018-10-26 17:09:57 +00:00

41 lines
2.3 KiB
HTML

[% INCLUDE 'blocking_errors.inc' %]
<script type="text/javascript">
//<![CDATA[
function confirm_deletion() {
if (confirm(_("Are you sure you want to delete this vendor?"))) {
window.location="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | html %]&op=delete";
}
}
//]]>
</script>
<div id="toolbar" class="btn-toolbar">
[% IF ( booksellerid ) %]
<div class="btn-group">
<a class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown" href="#"><i class="fa fa-plus"></i> New
<span class="caret"></span>
</a>
<ul class="dropdown-menu">
[% IF CAN_user_acquisition_order_manage && active %]
<li><a href="/cgi-bin/koha/acqui/basketheader.pl?booksellerid=[% booksellerid | uri %]&amp;op=add_form">Basket</a></li>
[% END %]
[% IF CAN_user_acquisition_contracts_manage && active %]
<li><a href="/cgi-bin/koha/admin/aqcontract.pl?op=add_form&amp;booksellerid=[% booksellerid | uri %]">Contract</a></li>
[% END %]
[% IF ( CAN_user_acquisition_vendors_manage ) %]
<li><a href="/cgi-bin/koha/acqui/supplier.pl?op=enter">Vendor</a></li>
[% END %]
</ul>
</div>
[% IF ( CAN_user_acquisition_vendors_manage ) %]
<div class="btn-group"><a class="btn btn-default btn-sm" id="editsupplier" href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | html %]&amp;op=enter"><i class="fa fa-pencil"></i> Edit vendor</a></div>
[% UNLESS ( basketcount OR subscriptioncount ) %]
<div class="btn-group"><a class="btn btn-default btn-sm" id="deletesupplier" href="javascript:confirm_deletion()"><i class="fa fa-trash"></i> Delete vendor</a></div>
[% END %]
[% END %]
[% IF CAN_user_acquisition_order_receive && basketcount %]
<div class="btn-group"><a class="btn btn-default btn-sm" id="receive" href="/cgi-bin/koha/acqui/parcels.pl?booksellerid=[% booksellerid | html %]"><i class="fa fa-inbox"></i> Receive shipments</a></div>
[% END %]
[% ELSE %]
<div class="btn-group"><a class="btn btn-default btn-sm" href="/cgi-bin/koha/acqui/supplier.pl?op=enter"><i class="fa fa-plus"></i> New vendor</a></div>
[% END %]
</div>