From: Bill Erickson Date: Fri, 18 May 2018 17:15:57 +0000 (-0400) Subject: LP#1770973 Webstaff loads locale-specific IDL X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=4602ff59aa69d2bc1dcdb9478ba029ed16626b00;p=working%2FEvergreen.git LP#1770973 Webstaff loads locale-specific IDL Fetch the locale-specific version of the /IDL2js data so that IDL-based labels in the UI may be correctly translated. Signed-off-by: Bill Erickson --- diff --git a/Open-ILS/src/templates/staff/base_js.tt2 b/Open-ILS/src/templates/staff/base_js.tt2 index e2e88dec73..78e37693a0 100644 --- a/Open-ILS/src/templates/staff/base_js.tt2 +++ b/Open-ILS/src/templates/staff/base_js.tt2 @@ -10,6 +10,13 @@ the UpUp resource list! %] +[% +# $locale is encoded as aa_bb. The IDL needs aa-BB. +SET idl_locale = ''; +IF ctx.locale; + idl_locale = ctx.locale.split('_').0 _ '-' _ ctx.locale.split('_').1.upper; +END; +%] - +