View | Details | Raw Unified | Return to bug 26540
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/transaction_types.inc (+1 lines)
Lines 2-7 Link Here
2
[% SET payment_types = [] %]
2
[% SET payment_types = [] %]
3
[% FOR pt IN AuthorisedValues.GetAuthValueDropbox('PAYMENT_TYPE') %]
3
[% FOR pt IN AuthorisedValues.GetAuthValueDropbox('PAYMENT_TYPE') %]
4
    [% NEXT IF pt.authorised_value.grep("^SIP[[:digit:]]{2}$").size() %]
4
    [% NEXT IF pt.authorised_value.grep("^SIP[[:digit:]]{2}$").size() %]
5
    [% NEXT IF ( type == 'payout' || type == 'refund' ) && pt.authorised_value == 'CASH' && Koha.Preference('UseCashRegisters') && registers.size == 0 %]
5
    [% payment_types.push(pt) %]
6
    [% payment_types.push(pt) %]
6
[% END %]
7
[% END %]
7
[% IF payment_types.size > 0 %]
8
[% IF payment_types.size > 0 %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt (-5 / +20 lines)
Lines 258-264 Link Here
258
                    <div class="modal-body">
258
                    <div class="modal-body">
259
                        [% IF Koha.Preference('UseCashRegisters') && ( registers.size == 0 ) %]
259
                        [% IF Koha.Preference('UseCashRegisters') && ( registers.size == 0 ) %]
260
                        <div id="payout_error" class="alert alert-warning">
260
                        <div id="payout_error" class="alert alert-warning">
261
                            You must have at least one cash register associated with this branch before you can record cash payouts.
261
                            <p>
262
                                You must have at least one cash register associated with this branch before you can record cash payouts.
263
                            </p>
264
                            [% IF ( CAN_user_parameters_manage_cash_registers ) %]
265
                                <form action="/cgi-bin/koha/admin/cash_registers.pl" method="get">
266
                                    <input type="hidden" name="op" value="add_form" />
267
                                    <button class="new" type="submit"><i class="fa fa-plus"></i> Create a new cash register</button>
268
                                </form>
269
                            [% END %]
262
                        </div>
270
                        </div>
263
                        [% END %]
271
                        [% END %]
264
                        <fieldset class="rows">
272
                        <fieldset class="rows">
Lines 274-280 Link Here
274
282
275
                                [% INCLUDE 'transaction_types.inc' type="payout" %]
283
                                [% INCLUDE 'transaction_types.inc' type="payout" %]
276
284
277
                                [% IF Koha.Preference('UseCashRegisters') %]
285
                                [% IF Koha.Preference('UseCashRegisters') && ( registers.size >= 1 ) %]
278
                                <li>
286
                                <li>
279
                                    <label for="registerid">Cash register: </label>
287
                                    <label for="registerid">Cash register: </label>
280
                                    <select name="registerid" id="payout_registerid">
288
                                    <select name="registerid" id="payout_registerid">
Lines 312-318 Link Here
312
                    <div class="modal-body">
320
                    <div class="modal-body">
313
                        [% IF Koha.Preference('UseCashRegisters') && ( registers.size == 0 ) %]
321
                        [% IF Koha.Preference('UseCashRegisters') && ( registers.size == 0 ) %]
314
                        <div id="refund_error" class="alert alert-warning">
322
                        <div id="refund_error" class="alert alert-warning">
315
                            You must have at least one cash register associated with this branch before you can record cash refunds.
323
                            <p>
324
                                You must have at least one cash register associated with this branch before you can record cash refunds.
325
                            </p>
326
                            [% IF ( CAN_user_parameters_manage_cash_registers ) %]
327
                                <form action="/cgi-bin/koha/admin/cash_registers.pl" method="get">
328
                                    <input type="hidden" name="op" value="add_form" />
329
                                    <button class="new" type="submit"><i class="fa fa-plus"></i> Create a new cash register</button>
330
                                </form>
331
                            [% END %]
316
                        </div>
332
                        </div>
317
                        [% END %]
333
                        [% END %]
318
                        <fieldset class="rows">
334
                        <fieldset class="rows">
Lines 331-337 Link Here
331
347
332
                                [% INCLUDE 'transaction_types.inc' type="refund" %]
348
                                [% INCLUDE 'transaction_types.inc' type="refund" %]
333
349
334
                                [% IF Koha.Preference('UseCashRegisters') %]
350
                                [% IF Koha.Preference('UseCashRegisters') && ( registers.size >= 1 ) %]
335
                                <li>
351
                                <li>
336
                                    <label for="registerid">Cash register: </label>
352
                                    <label for="registerid">Cash register: </label>
337
                                    <select name="registerid" id="refund_registerid">
353
                                    <select name="registerid" id="refund_registerid">
338
- 

Return to bug 26540