}
}
-if( $patron && !$patron->can_request_article) {
+if ( $patron && !$patron->can_request_article ) {
$patron = undef;
+ $template->param( error_message => 'article_request_limit_reached' );
+}
+
+if ( $patron ) {
$template->param(
- error_message => 'article_request_limit_reached'
+ article_request_fee => $patron->article_request_fee
);
}
[%- SWITCH debit_type.code -%]
[%- CASE 'ACCOUNT' -%]Account creation fee
[%- CASE 'ACCOUNT_RENEW' -%]Account renewal fee
+ [%- CASE 'ARTICLE_REQUEST' -%]Article scan request fee
[%- CASE 'LOST' -%]Lost item
[%- CASE 'MANUAL' -%]Manual fee
[%- CASE 'NEW_CARD' -%]New card
[% USE Branches %]
[% USE ItemTypes %]
[% USE AuthorisedValues %]
+[% USE Price %]
[% SET footerjs = 1 %]
[% SET article_requests_view = 1 %]
[% SET biblionumber = biblio.biblionumber %]
</form>
[% ELSE %]
[% IF biblio.can_article_request( patron ) %]
-
+ [% IF article_request_fee > 0 %]
+ <div class="dialog alert">
+ Patron will be charged with <strong>[% article_request_fee | $Price %]</strong> for every request
+ </div>
+ [% END %]
<form id="place-article-request" method="post" action="/cgi-bin/koha/circ/request-article.pl">
<input type="hidden" name="action" value="create" />
<input type="hidden" name="biblionumber" id="biblionumber" value="[% biblio.biblionumber | html %]" />
[%- SWITCH debit_type_code -%]
[%- CASE 'ACCOUNT' -%]Account creation fee
[%- CASE 'ACCOUNT_RENEW' -%]Account renewal fee
+ [%- CASE 'ARTICLE_REQUEST' -%]Article scan request fee
[%- CASE 'LOST' -%]Lost item
[%- CASE 'MANUAL' -%]Manual fee
[%- CASE 'NEW_CARD' -%]New card
[% USE Branches %]
[% USE ItemTypes %]
[% USE AdditionalContents %]
+[% USE Price %]
[% USE raw %]
[% INCLUDE 'doc-head-open.inc' %]
[% IF article_request_type == 'item_only' %] [% SET mandatory_fields = Koha.Preference('ArticleRequestsMandatoryFieldsItemOnly') %] [% END %]
+ [% IF article_request_fee > 0 %]
+ <div class="alert alert-warning">
+ You will be charged with <strong>[% article_request_fee | $Price %]</strong> for every request
+ </div>
+ [% END %]
+
<form id="place-article-request" method="post" action="/cgi-bin/koha/opac-request-article.pl">
<legend class="sr-only">Place article request</legend>
<input type="hidden" name="action" value="create" />
);
}
+$template->param( article_request_fee => $patron->article_request_fee )
+ if $action ne 'create';
+
$template->param(
biblio => $biblio,
patron => $patron,