|
Lines 1-6
Link Here
|
| 1 |
[% USE AuthorisedValues %] |
1 |
[% USE AuthorisedValues %] |
| 2 |
[% USE Branches %] |
2 |
[% USE Branches %] |
| 3 |
[% USE Price %] |
3 |
[% USE Price %] |
|
|
4 |
[% USE Koha %] |
| 4 |
[% SET footerjs = 1 %] |
5 |
[% SET footerjs = 1 %] |
| 5 |
[% INCLUDE 'doc-head-open.inc' %] |
6 |
[% INCLUDE 'doc-head-open.inc' %] |
| 6 |
<title>Koha › Administration › Funds[% IF op == 'add_form' %] › [% IF ( budget_id ) %]Modify fund[% IF ( budget_name ) %] '[% budget_name %]'[% END %][% ELSE %]Add fund [% END %][% END %]</title> |
7 |
<title>Koha › Administration › Funds[% IF op == 'add_form' %] › [% IF ( budget_id ) %]Modify fund[% IF ( budget_name ) %] '[% budget_name %]'[% END %][% ELSE %]Add fund [% END %][% END %]</title> |
|
Lines 232-237
Link Here
|
| 232 |
<li> |
233 |
<li> |
| 233 |
<label style="white-space: nowrap;" for="budget_amount" class="required">Amount: </label> |
234 |
<label style="white-space: nowrap;" for="budget_amount" class="required">Amount: </label> |
| 234 |
<input type="text" name="budget_amount" id="budget_amount" value="[% budget_amount | $Price on_editing => 1 %]" size="8" /> |
235 |
<input type="text" name="budget_amount" id="budget_amount" value="[% budget_amount | $Price on_editing => 1 %]" size="8" /> |
|
|
236 |
[% INCLUDE 'price-conversion-message.inc' %] |
| 235 |
</li> |
237 |
</li> |
| 236 |
|
238 |
|
| 237 |
<li> |
239 |
<li> |
|
Lines 241-249
Link Here
|
| 241 |
</li> |
243 |
</li> |
| 242 |
|
244 |
|
| 243 |
<li> |
245 |
<li> |
| 244 |
<label for="budget_expend">Warning at (amount): </label> |
246 |
<label for="budget_expend">Warning at (amount): </label> |
| 245 |
<input type="text" name="budget_expend" id="budget_expend" value="[% budget_expend | $Price on_editing => 1 %]" size="10" /> |
247 |
<input type="text" name="budget_expend" id="budget_expend" value="[% budget_expend | $Price on_editing => 1 %]" size="10" /> |
| 246 |
<span class="hint">0 to disable</span> |
248 |
|
|
|
249 |
<span class="hint">0 to disable.</span> |
| 250 |
[% INCLUDE 'price-conversion-message.inc' %] |
| 251 |
|
| 247 |
</li> |
252 |
</li> |
| 248 |
|
253 |
|
| 249 |
<li> |
254 |
<li> |
|
Lines 449-454
Link Here
|
| 449 |
|
454 |
|
| 450 |
<script type="text/javascript" src="[% interface %]/[% theme %]/js/acq_[% KOHA_VERSION %].js"></script> |
455 |
<script type="text/javascript" src="[% interface %]/[% theme %]/js/acq_[% KOHA_VERSION %].js"></script> |
| 451 |
[% IF op == 'add_form' %] |
456 |
[% IF op == 'add_form' %] |
|
|
457 |
[% INCLUDE 'prices.inc' %] |
| 452 |
<script type="text/javascript"> |
458 |
<script type="text/javascript"> |
| 453 |
//<![CDATA[ |
459 |
//<![CDATA[ |
| 454 |
|
460 |
|
|
Lines 563-569
Link Here
|
| 563 |
} |
569 |
} |
| 564 |
} |
570 |
} |
| 565 |
|
571 |
|
| 566 |
// else do lookup |
572 |
// else do lookup |
| 567 |
var budgetTotal = Math.abs(f.budget_amount.value); |
573 |
var budgetTotal = Math.abs(f.budget_amount.value); |
| 568 |
var result = budgetExceedsParent (budgetTotal, budgetId, newBudgetParent, f.budget_period_id.value) |
574 |
var result = budgetExceedsParent (budgetTotal, budgetId, newBudgetParent, f.budget_period_id.value) |
| 569 |
if (result) { |
575 |
if (result) { |
|
Lines 579-585
Link Here
|
| 579 |
alert(alertString2); |
585 |
alert(alertString2); |
| 580 |
} |
586 |
} |
| 581 |
} |
587 |
} |
|
|
588 |
|
| 589 |
|
| 582 |
$(document).ready(function(){ |
590 |
$(document).ready(function(){ |
|
|
591 |
$('#budget_expend').on('change', function(){CheckAmount(this)}); |
| 592 |
$('#budget_amount').on('change', function(){CheckAmount(this)}); |
| 593 |
function CheckAmount(f){ |
| 594 |
var ok=1; |
| 595 |
var _alertString=""; |
| 596 |
var alertString2; |
| 597 |
if (!(isPrice(f.value))) { |
| 598 |
_alertString += "\n- " + _("Amount must be a valid number, or empty"); |
| 599 |
}else{ |
| 600 |
f.value=Price_from_string(f.value); |
| 601 |
|
| 602 |
} |
| 603 |
if (_alertString.length==0) { |
| 604 |
return true; |
| 605 |
} else { |
| 606 |
alertString2 = _("Form not submitted because of the following problem(s)"); |
| 607 |
alertString2 += "\n------------------------------------------------------------------------------------\n"; |
| 608 |
alertString2 += _alertString; |
| 609 |
alert(alertString2); |
| 610 |
return false; |
| 611 |
} |
| 612 |
} |
| 613 |
|
| 583 |
$("#remove_owner").on("click",function(e){ |
614 |
$("#remove_owner").on("click",function(e){ |
| 584 |
e.preventDefault(); |
615 |
e.preventDefault(); |
| 585 |
ownerRemove(); |
616 |
ownerRemove(); |
|
Lines 692-696
Link Here
|
| 692 |
//]]> |
723 |
//]]> |
| 693 |
</script> |
724 |
</script> |
| 694 |
[% END %] |
725 |
[% END %] |
| 695 |
[% END %] |
726 |
[% END %][%# end of MACRO jsinclude %] |
| 696 |
[% INCLUDE 'intranet-bottom.inc' %] |
727 |
[% INCLUDE 'intranet-bottom.inc' %] |