Bugzilla – Attachment 98930 Details for
Bug 24661
Inclusion of locale-related javascript files is broken
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 24661: Fix inclusion of locale-related javascript files
Bug-24661-Fix-inclusion-of-locale-related-javascri.patch (text/plain), 1.62 KB, created by
Martin Renvoize (ashimema)
on 2020-02-14 11:56:35 UTC
(
hide
)
Description:
Bug 24661: Fix inclusion of locale-related javascript files
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2020-02-14 11:56:35 UTC
Size:
1.62 KB
patch
obsolete
>From d2e60c553ba42e61c8ad321c3625e6d291e9c13d Mon Sep 17 00:00:00 2001 >From: Julian Maurice <julian.maurice@biblibre.com> >Date: Fri, 14 Feb 2020 09:46:01 +0100 >Subject: [PATCH] Bug 24661: Fix inclusion of locale-related javascript files > >2 js files (Gettext.js, i18n.js) + 1 generated js file (locale_data.js) >were added by bug 21156. Their URL are broken and the files are not loaded. > >Use Template::Toolkit plugin Asset to include these files, and exclude >locale_data.js when language is english, because obviously translations >are not needed in this case. > >Test plan: >1. Just make sure the files mentioned above are loaded correctly when in > English and in other languages as well > >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > .../intranet-tmpl/prog/en/includes/doc-head-close.inc | 8 +++++--- > 1 file changed, 5 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/doc-head-close.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/doc-head-close.inc >index 45bd9999fe..1ad6197288 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/doc-head-close.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/doc-head-close.inc >@@ -26,9 +26,11 @@ > var Koha = {}; > </script> > >-<script src="[% themelang | url %]/js/locale_data.js"></script> >-<script src="[% interface | url %]/js/Gettext.js"></script> >-<script src="[% interface | url %]/js/i18n.js"></script> >+[% IF lang != 'en' %] >+ [% Asset.js(lang _ '/js/locale_data.js') | $raw %] >+[% END %] >+[% Asset.js('js/Gettext.js') | $raw %] >+[% Asset.js('js/i18n.js') | $raw %] > > [% IF ( login ) %] > [% Asset.css("css/login.css") | $raw %] >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 24661
:
98913
| 98930 |
99586