From e44f9adecd827cfd172c3a5cc86b8a3b99ec6d7f Mon Sep 17 00:00:00 2001
From: Victor Grousset <victor.grousset@biblibre.com>
Date: Wed, 25 Oct 2017 15:22:11 +0200
Subject: [PATCH] Bug 19522: Label creator - some strings are not translatable
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Templates: new form:
Add hardcoded unit names to make them translatable.

Test plan:
1. install the fr_FR locale
2. go to /cgi-bin/koha/labels/label-edit-template.pl?op=new
3. then you should see the "Unités" dropdown with english units
4. apply this patch
5. install the language
6. refresh the page
7. then you should see the "Unités" dropdown with french units

Signed-off-by: Simon Pouchol <simon.pouchol@biblibre.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
---
 .../prog/en/modules/labels/label-edit-template.tt          | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-template.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-template.tt
index e4fc9f9..1a107ef 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-template.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-template.tt
@@ -77,14 +77,24 @@
                                  <label for="units">Units:</label>
                                  <select id="units" name="units">
                                  [% FOREACH unit IN units %]
-
 									[% IF ( unit.selected ) %]
 									<option value="[% unit.type %]" selected="selected">
 									[% ELSE %]
 									<option value="[% unit.type %]">
 									[% END %]
 
-                                 [% unit.desc %]
+                                     [% SWITCH unit.type %]
+                                     [%   CASE 'POINT' %]
+                                     PostScript Points
+                                     [%   CASE 'AGATE' %]
+                                     Adobe Agates
+                                     [%   CASE 'INCH' %]
+                                     US Inches
+                                     [%   CASE 'MM' %]
+                                     SI Millimeters
+                                     [%   CASE 'CM' %]
+                                     SI Centimeters
+                                     [% END %]
                                  </option>
                                  [% END %]
                                  </select>
-- 
2.7.4