From ef14bed4f60f095d4c3d9e7a6ad41463131a200c Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Sun, 12 Apr 2015 22:47:56 +0200 Subject: [PATCH] Improved translation overview. --- .../javascripts/app/controllers/translation.js.coffee | 2 ++ app/assets/javascripts/app/lib/app_post/i18n.js.coffee | 2 +- app/assets/javascripts/app/views/translation.jst.eco | 10 +++++----- app/assets/stylesheets/zammad.css.scss | 6 ++++++ 4 files changed, 14 insertions(+), 6 deletions(-) diff --git a/app/assets/javascripts/app/controllers/translation.js.coffee b/app/assets/javascripts/app/controllers/translation.js.coffee index 309a91d96..237919a9a 100644 --- a/app/assets/javascripts/app/controllers/translation.js.coffee +++ b/app/assets/javascripts/app/controllers/translation.js.coffee @@ -79,8 +79,10 @@ class Index extends App.ControllerContent reset = field.closest('tr').find('.js-Reset') if current isnt initial reset.show() + reset.closest('tr').addClass('warning') else reset.hide() + reset.closest('tr').removeClass('warning') App.Config.set( 'Translation', { prio: 1800, parent: '#system', name: 'Translations', target: '#system/translation', controller: Index, role: ['Admin'] }, 'NavBarAdmin' ) diff --git a/app/assets/javascripts/app/lib/app_post/i18n.js.coffee b/app/assets/javascripts/app/lib/app_post/i18n.js.coffee index e751631ed..ddbc2d5ae 100644 --- a/app/assets/javascripts/app/lib/app_post/i18n.js.coffee +++ b/app/assets/javascripts/app/lib/app_post/i18n.js.coffee @@ -164,7 +164,7 @@ class _i18nSingleton extends Spine.Module else @_translated = false translated = string - if App.Config.get('developer_mode') + if App.Config.get('developer_mode') is true @log 'notice', "translation for '#{string}' in '#{@locale}' is missing" # search %s diff --git a/app/assets/javascripts/app/views/translation.jst.eco b/app/assets/javascripts/app/views/translation.jst.eco index 59077d171..a19a202f3 100644 --- a/app/assets/javascripts/app/views/translation.jst.eco +++ b/app/assets/javascripts/app/views/translation.jst.eco @@ -14,13 +14,13 @@ <%- @T('Datetime') %> - + <%- @T('Date') %> - + @@ -41,9 +41,9 @@ <% if @list: %> <% for item in @list: %> - <%= item[1] %> - - <%= item[3]%> + <%= item[1] %> + + <%= item[3]%> <%- @T('Reset') %> <% end %> diff --git a/app/assets/stylesheets/zammad.css.scss b/app/assets/stylesheets/zammad.css.scss index 5872c0f5a..fba803ca3 100644 --- a/app/assets/stylesheets/zammad.css.scss +++ b/app/assets/stylesheets/zammad.css.scss @@ -5267,6 +5267,12 @@ label + .wizard-buttonList { .translationOverview { + tbody > tr > td { + padding: 20px 0 0 10px; + } + .translationOverview-itemContainer { + padding: 10px 0 10px 10px; + } .translationOverview-source { width: 25%; }