From: Jonathan Druart
Date: Thu, 19 Sep 2013 15:03:00 +0000 (+0200)
Subject: Bug 9374: The color should manage all zero format.
X-Git-Url: http://git.rot13.org/?p=koha.git;a=commitdiff_plain;h=c523b56bcf0eccb2feb342fe962e590d74baa749
Bug 9374: The color should manage all zero format.
The format of prices in Koha is discuted in some bugs (e.g. 9410).
The good way will be to introduce a syspref in order to deal with the
number of decimal.
The previous patch is too restrictive, we should deal with other zero
format.
Signed-off-by: Jonathan Druart
Signed-off-by: Galen Charlton
---
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt
index 3d4cf43f83..edac2a7696 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt
@@ -450,15 +450,16 @@
[% END %]
- [% books_loo.rrpgste %] |
- [% books_loo.ecostgste %] |
- [% books_loo.rrpgsti %] |
- [% books_loo.ecostgsti %] |
- [% books_loo.quantity %] |
- [% books_loo.totalgste %] |
- [% books_loo.totalgsti %] |
- [% books_loo.gstgsti %] |
- [% books_loo.gstvalue %] |
+ [% SET zero_regex = "^0{1,}\.?0{1,}[^1-9]" %] [%# 0 or 0.0 or 0.00 or 00 or 00.0 or 00.00 or 0.000 ... %]
+ [% books_loo.rrpgste %] |
+ [% books_loo.ecostgste %] |
+ [% books_loo.rrpgsti %] |
+ [% books_loo.ecostgsti %] |
+ [% books_loo.quantity %] |
+ [% books_loo.totalgste %] |
+ [% books_loo.totalgsti %] |
+ [% books_loo.gstgsti %] |
+ [% books_loo.gstvalue %] |
[% books_loo.budget_name %] |
[% IF ( active ) %]
[% UNLESS ( closedate ) %]