From 863b825824114c601d32a910b06cec8510df8bdf Mon Sep 17 00:00:00 2001 From: Bernardo Gonzalez Kriegel Date: Sat, 22 Mar 2014 14:50:03 -0300 Subject: [PATCH] [PASSED QA] Bug 11646 - Untranslatable confirm popup in field 006 and 008 builders This patch MARC21 modifies value builders 006 and 008 to make confirm popup translatable To test: 1) Update po files for your preferred language, xx-YY cd misc/translator; perl translate update xx-YY 2) Check that confirm string is NOT present egrep -B3 "Show values for|material type\?" po/xx-YY*po 3) Apply the patch 4) Repeat 1) 5) Repeat 2), now the strings are present Also check that english or translated popup is right Signed-off-by: Owen Leonard Signed-off-by: Katrin Fischer Works as described. --- .../prog/en/modules/cataloguing/value_builder/marc21_field_006.tt | 2 +- .../prog/en/modules/cataloguing/value_builder/marc21_field_008.tt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tt index 4a2263a..37524ff 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tt @@ -24,7 +24,7 @@ function changeTypeofMaterial(form) { - if (form.material_type.options[form.material_type.selectedIndex].value != "" && confirm('Show values for \'' + form.material_type.options[form.material_type.selectedIndex].text + '\' material type?')) { + if (form.material_type.options[form.material_type.selectedIndex].value != "" && confirm(_("Show values for") +' \'' + form.material_type.options[form.material_type.selectedIndex].text + '\' ' +_("material type?"))) { objXmlControlField.setIdMaterial(form.material_type.options[form.material_type.selectedIndex].value); objXmlControlField.renderTemplate(); renderResult(tr_result, form.result.value, true); diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tt index 6e5acb9..4a5b8f8 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tt @@ -24,7 +24,7 @@ function changeTypeofMaterial(form) { - if (form.material_type.options[form.material_type.selectedIndex].value != "" && confirm('Show values for \'' + form.material_type.options[form.material_type.selectedIndex].text + '\' material type?')) { + if (form.material_type.options[form.material_type.selectedIndex].value != "" && confirm(_("Show values for") + ' \'' + form.material_type.options[form.material_type.selectedIndex].text + '\' ' + _("material type?"))) { objXmlControlField.setIdMaterial(form.material_type.options[form.material_type.selectedIndex].value); objXmlControlField.renderTemplate(); renderResult(tr_result, form.result.value, true); -- 1.8.3.2