From f61efe1e45da9f0169c984c4c128b161dedbf99e Mon Sep 17 00:00:00 2001 From: Harrys Ravalomanana Date: Mon, 20 May 2019 14:23:38 +0400 Subject: [PATCH 1/3] PHRAS-2589-Admin_personnalisation_logo_fix --- .../web/admin/personalisation_logo.html.twig | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/templates/web/admin/personalisation_logo.html.twig b/templates/web/admin/personalisation_logo.html.twig index b286f6fae5..58a9bb8483 100644 --- a/templates/web/admin/personalisation_logo.html.twig +++ b/templates/web/admin/personalisation_logo.html.twig @@ -5,16 +5,18 @@ {{ form_label(form.logoChoice[0]) }}
gabari + src="/assets/common/images/logo.png"/>
- {{ 'prod::setup: download gabari' | trans }} + {{ form_widget(form.logoChoice[1]) }} {{ form_label(form.logoChoice[1]) }}
{{ 'prod::setup: help text' | trans }} - +
+ {{ 'prod::setup: download gabari' | trans }} +
{% if app['conf'].get(['registry', 'general', 'personalize-logo-choice', 'personalizeFile']) == 'true' %} {% set extension = app['conf'].get(['registry', 'general', 'personalize-logo-choice', 'fileType']) %} @@ -28,6 +30,7 @@
+ {{ form_widget(form.personalizeFile) }} {{ form_widget(form.fileType) }} @@ -95,7 +98,7 @@ $('#general_personalize-logo-choice_personalizeLogoInput').val(""); $('#error-text').text(errorFileType); $('#error-text').show(); - $('#help-text').hide(); + /*$('#help-text').hide();*/ $('#personalize-image-container').hide(); return false; } @@ -109,7 +112,7 @@ if (h > 41 || w > 120 ) { $('#error-text').text(errorDimension); $('#error-text').show(); - $('#help-text').hide(); + /*$('#help-text').hide();*/ $('#personalize-image-container').hide(); $('#general_personalize-logo-choice_personalizeLogoInput').val(""); return false; @@ -121,7 +124,7 @@ loadImage(file, function (img) { $('#personalize-image-container').show(); $('#error-text').hide(); - $('#help-text').hide(); + /*$('#help-text').hide();*/ $('#personalize-image-container').empty().append(img); }, { maxSize: 5242880, // 5MB @@ -150,7 +153,7 @@ $('#general_personalize-logo-choice_personalizeFile').val(false); } - console.log(data); + /* console.log(data);*/ } }); From 28151751eb9306d9cf0d06220cb8673869396c1f Mon Sep 17 00:00:00 2001 From: Harrys Ravalomanana Date: Mon, 20 May 2019 14:31:46 +0400 Subject: [PATCH 2/3] PHRAS-2589-Admin_personnalisation_logo_fix --- templates/web/admin/personalisation_logo.html.twig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/web/admin/personalisation_logo.html.twig b/templates/web/admin/personalisation_logo.html.twig index 58a9bb8483..0e895a8af7 100644 --- a/templates/web/admin/personalisation_logo.html.twig +++ b/templates/web/admin/personalisation_logo.html.twig @@ -57,7 +57,7 @@ $("#download-image-template").on('click', function (event) { event.preventDefault(); - var imageInBase64 = $('#original-image-placeholder').attr('src'); + var imageInBase64 = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHgAAAApCAYAAAGJsd0WAAAAAXNSR0IArs4c6QAAB+dJREFUeAHtm2lsVFUUgDvtdLphAVEECi0pjUDYiqBWimaqSPgBRSOiaICofwiRGDF0U5FEoLSFok1UIv1DxB82igaUxRhttC4YRWNKAlUQSEWkbAJtp3TzO8O745t2OtNOZ95MX+ckZ8695557zzl3X95YoqKiOkG/wVvmVF+lSubffAl5SrfAlMxCXVBYWDiira1takxMzF8dHR2O0tLS+g0bNljBNpeQFvBmdldZt7jS7MbsbaRfmX0p2YNAli8hnwKeCojRmPVCCwoK5s+bN+90dXV1R35+/gM1NTVnLBbLELvdnpiVlWUn/oenQvzi9bvC/GnnWzFVuu5WzeSP/THdH8X+6HHLE63FMqCGGqDaSWg3kB7T3t6+JykpaVhjY2M1vaWus7PTXlZWlr5u3bodcXFxZS0tLTnwt1qt1onILk9ISKhsamqSnrQN3r7NmzfXditYYxjqqTJCeaziYU/PYOFQsA7ssSqD4cV0rdAkaBE4OhhKDCkz1xAtKFHjOF1TOMwoxR7Hr1LOWP1HZnrW11mss4lQWRmS4uPjf4Bam5ubsxm3PzPG72Fs78/LyxuTmJh4yeFw2BnvMSUlJZ+psr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fo.split('/').pop(); var filename = $('#original-image-placeholder').attr('alt') + "." + ext; From f5f05276007bcfc7bd6f40315b9765b838effbc0 Mon Sep 17 00:00:00 2001 From: Harrys Ravalomanana Date: Tue, 21 May 2019 10:03:27 +0400 Subject: [PATCH 3/3] PHRAS-2589-Admin-personnalisation update translation --- resources/locales/messages.de.xlf | 52 +++++++++---------- resources/locales/messages.en.xlf | 52 +++++++++---------- resources/locales/messages.fr.xlf | 52 +++++++++---------- resources/locales/messages.nl.xlf | 52 +++++++++---------- resources/locales/validators.de.xlf | 2 +- resources/locales/validators.en.xlf | 2 +- resources/locales/validators.fr.xlf | 2 +- resources/locales/validators.nl.xlf | 2 +- .../web/admin/personalisation_logo.html.twig | 10 ++-- 9 files changed, 113 insertions(+), 113 deletions(-) diff --git a/resources/locales/messages.de.xlf b/resources/locales/messages.de.xlf index 00f9ca99c3..e7d5f19c59 100644 --- a/resources/locales/messages.de.xlf +++ b/resources/locales/messages.de.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. @@ -8908,6 +8908,31 @@ Aggregateinstellungen admin/search-engine/search-engine-settings.html.twig + + admin::setup:personalisation_logo: download gabari + admin::setup:personalisation_logo: download gabari + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text dimension + admin::setup:personalisation_logo: error text dimension + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text file type + admin::setup:personalisation_logo: error text file type + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: help text + admin::setup:personalisation_logo: help text + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: select file + admin::setup:personalisation_logo: select file + web/admin/personalisation_logo.html.twig + admin::status: case A Off @@ -11267,31 +11292,6 @@ Achtung : Die ausgewählte Datenbanken Liste für die Suche wurde verändert Controller/Prod/LanguageController.php - - prod::setup: download gabari - prod::setup: download gabari - web/admin/personalisation_logo.html.twig - - - prod::setup: error text dimension - prod::setup: error text dimension - web/admin/personalisation_logo.html.twig - - - prod::setup: error text file type - prod::setup: error text file type - web/admin/personalisation_logo.html.twig - - - prod::setup: help text - prod::setup: help text - web/admin/personalisation_logo.html.twig - - - prod::setup: select file - prod::setup: select file - web/admin/personalisation_logo.html.twig - prod::thesaurusTab:candidats mögliche Begriffe diff --git a/resources/locales/messages.en.xlf b/resources/locales/messages.en.xlf index c0bfa8d4ca..f6afecf3eb 100644 --- a/resources/locales/messages.en.xlf +++ b/resources/locales/messages.en.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. @@ -8908,6 +8908,31 @@ Aggregates settings admin/search-engine/search-engine-settings.html.twig + + admin::setup:personalisation_logo: download gabari + admin::setup:personalisation_logo: download gabari + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text dimension + admin::setup:personalisation_logo: error text dimension + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text file type + admin::setup:personalisation_logo: error text file type + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: help text + admin::setup:personalisation_logo: help text + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: select file + admin::setup:personalisation_logo: select file + web/admin/personalisation_logo.html.twig + admin::status: case A Off @@ -11268,31 +11293,6 @@ See documentation for more examples https://docs.phraseanet.com Warning, list of collections to search in has been changed Controller/Prod/LanguageController.php - - prod::setup: download gabari - prod::setup: download gabari - web/admin/personalisation_logo.html.twig - - - prod::setup: error text dimension - prod::setup: error text dimension - web/admin/personalisation_logo.html.twig - - - prod::setup: error text file type - prod::setup: error text file type - web/admin/personalisation_logo.html.twig - - - prod::setup: help text - prod::setup: help text - web/admin/personalisation_logo.html.twig - - - prod::setup: select file - prod::setup: select file - web/admin/personalisation_logo.html.twig - prod::thesaurusTab:candidats Candidates diff --git a/resources/locales/messages.fr.xlf b/resources/locales/messages.fr.xlf index 5261e1de01..c714357c61 100644 --- a/resources/locales/messages.fr.xlf +++ b/resources/locales/messages.fr.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. @@ -8908,6 +8908,31 @@ Si vous recevez cet e-mail sans l'avoir sollicité, merci de l'ignorer ou de le Réglage d'agrégation admin/search-engine/search-engine-settings.html.twig + + admin::setup:personalisation_logo: download gabari + admin::setup:personalisation_logo: download gabari + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text dimension + admin::setup:personalisation_logo: error text dimension + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text file type + admin::setup:personalisation_logo: error text file type + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: help text + admin::setup:personalisation_logo: help text + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: select file + admin::setup:personalisation_logo: select file + web/admin/personalisation_logo.html.twig + admin::status: case A Off @@ -11267,31 +11292,6 @@ Si vous recevez cet e-mail sans l'avoir sollicité, merci de l'ignorer ou de le Attention : la liste des collections sélectionnées pour la recherche a été changée Controller/Prod/LanguageController.php - - prod::setup: download gabari - prod::setup: download gabari - web/admin/personalisation_logo.html.twig - - - prod::setup: error text dimension - prod::setup: error text dimension - web/admin/personalisation_logo.html.twig - - - prod::setup: error text file type - prod::setup: error text file type - web/admin/personalisation_logo.html.twig - - - prod::setup: help text - prod::setup: help text - web/admin/personalisation_logo.html.twig - - - prod::setup: select file - prod::setup: select file - web/admin/personalisation_logo.html.twig - prod::thesaurusTab:candidats Candidats diff --git a/resources/locales/messages.nl.xlf b/resources/locales/messages.nl.xlf index 2b08839c6b..f0fbeeb0b7 100644 --- a/resources/locales/messages.nl.xlf +++ b/resources/locales/messages.nl.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. @@ -8915,6 +8915,31 @@ admin::search-engine: general-aggregation admin/search-engine/search-engine-settings.html.twig + + admin::setup:personalisation_logo: download gabari + admin::setup:personalisation_logo: download gabari + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text dimension + admin::setup:personalisation_logo: error text dimension + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: error text file type + admin::setup:personalisation_logo: error text file type + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: help text + admin::setup:personalisation_logo: help text + web/admin/personalisation_logo.html.twig + + + admin::setup:personalisation_logo: select file + admin::setup:personalisation_logo: select file + web/admin/personalisation_logo.html.twig + admin::status: case A Case A @@ -11274,31 +11299,6 @@ Opgepast : de lijst met de geslecteerde databases is veranderd. Controller/Prod/LanguageController.php - - prod::setup: download gabari - prod::setup: download gabari - web/admin/personalisation_logo.html.twig - - - prod::setup: error text dimension - prod::setup: error text dimension - web/admin/personalisation_logo.html.twig - - - prod::setup: error text file type - prod::setup: error text file type - web/admin/personalisation_logo.html.twig - - - prod::setup: help text - prod::setup: help text - web/admin/personalisation_logo.html.twig - - - prod::setup: select file - prod::setup: select file - web/admin/personalisation_logo.html.twig - prod::thesaurusTab:candidats Kandidaten diff --git a/resources/locales/validators.de.xlf b/resources/locales/validators.de.xlf index f160aedb25..352466f945 100644 --- a/resources/locales/validators.de.xlf +++ b/resources/locales/validators.de.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. diff --git a/resources/locales/validators.en.xlf b/resources/locales/validators.en.xlf index 32a6d1b782..d25324b360 100644 --- a/resources/locales/validators.en.xlf +++ b/resources/locales/validators.en.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. diff --git a/resources/locales/validators.fr.xlf b/resources/locales/validators.fr.xlf index d1ab4fb190..e03b531b2f 100644 --- a/resources/locales/validators.fr.xlf +++ b/resources/locales/validators.fr.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. diff --git a/resources/locales/validators.nl.xlf b/resources/locales/validators.nl.xlf index 19cd0f01ae..b6aa595998 100644 --- a/resources/locales/validators.nl.xlf +++ b/resources/locales/validators.nl.xlf @@ -1,6 +1,6 @@ - +
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message. diff --git a/templates/web/admin/personalisation_logo.html.twig b/templates/web/admin/personalisation_logo.html.twig index 0e895a8af7..9f1cd4daaf 100644 --- a/templates/web/admin/personalisation_logo.html.twig +++ b/templates/web/admin/personalisation_logo.html.twig @@ -13,9 +13,9 @@ {{ form_widget(form.logoChoice[1]) }} {{ form_label(form.logoChoice[1]) }}
- {{ 'prod::setup: help text' | trans }} + {{ 'admin::setup:personalisation_logo: help text' | trans }}
- {{ 'prod::setup: download gabari' | trans }} + {{ 'admin::setup:personalisation_logo: download gabari' | trans }}
{% if app['conf'].get(['registry', 'general', 'personalize-logo-choice', 'personalizeFile']) == 'true' %} @@ -28,7 +28,7 @@
{{ form_widget(form.personalizeLogoInput) }} + id="select-logo-btn">{{ 'admin::setup:personalisation_logo: select file' | trans }}
@@ -41,8 +41,8 @@ $(document).ready(function () { var fileToUpload = null; - var errorDimension = '{{ 'prod::setup: error text dimension' | trans }}'; - var errorFileType = '{{ 'prod::setup: error text file type' | trans }}'; + var errorDimension = '{{ 'admin::setup:personalisation_logo: error text dimension' | trans }}'; + var errorFileType = '{{ 'admin::setup:personalisation_logo: error text file type' | trans }}'; $('#help-text').show();