From: Pasi Kallinen Date: Sun, 2 Dec 2012 20:49:42 +0000 (+0200) Subject: LP#1078596: Cannot translate strings handled by fieldmapper X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=25e1b57aa03518edf86c2de9c15a1ab8b6d8c1d7;p=evergreen%2Fmasslnc.git LP#1078596: Cannot translate strings handled by fieldmapper Strings that should be translatable only show up in English, for example in the Patron Registration screen. There's a bug in the fieldmapper where it sets a variable to an empty array, but later in the code only checks whether that particular variable exists, not if it's an empty array. Signed-off-by: Pasi Kallinen Signed-off-by: Dan Scott --- diff --git a/Open-ILS/web/js/dojo/fieldmapper/IDL.js b/Open-ILS/web/js/dojo/fieldmapper/IDL.js index 9cc7a3c275..7efb9671fe 100644 --- a/Open-ILS/web/js/dojo/fieldmapper/IDL.js +++ b/Open-ILS/web/js/dojo/fieldmapper/IDL.js @@ -32,7 +32,7 @@ if(!dojo._hasResource["fieldmapper.IDL"]) { window._preload_fieldmapper_IDL = null; } - if(!fieldmapper.IDL.fmclasses || (classlist && classlist.length)) { + if(!fieldmapper.IDL.fmclasses || !fieldmapper.IDL.fmclasses.length || (classlist && classlist.length)) { var idl_url = this._URL_PATH; if (classlist.length && (classlist.length > 1 || classlist[0] != '*')) {