From 54689dd95bf56bc91ba8ce19445f65103cf93498 Mon Sep 17 00:00:00 2001 From: Aleksey Smirnov Date: Sun, 5 May 2019 20:22:12 +0300 Subject: [PATCH 1/5] Update Russian language (#113) * Update blueprints.yaml * Update languages.yaml * Update blueprints.yaml --- blueprints.yaml | 14 +++++++------- languages.yaml | 24 ++++++++++++++++++++++++ 2 files changed, 31 insertions(+), 7 deletions(-) diff --git a/blueprints.yaml b/blueprints.yaml index 50a7a53..443e785 100644 --- a/blueprints.yaml +++ b/blueprints.yaml @@ -34,7 +34,7 @@ form: label: PLUGIN_EMAIL.MAIL_ENGINE size: medium options: - none: Disabled + none: PLUGIN_ADMIN.DISABLED smtp: SMTP sendmail: Sendmail @@ -44,14 +44,14 @@ form: size: medium default: 'text/html' options: - 'text/plain': Plain text + 'text/plain': PLUGIN_EMAIL.CONTENT_TYPE_PLAIN_TEXT 'text/html': HTML charset: type: text size: medium label: PLUGIN_EMAIL.CHARSET - placeholder: "Defaults to UTF-8" + placeholder: PLUGIN_EMAIL.CHARSET_PLACEHOLDER email_Defaults: type: section @@ -160,7 +160,7 @@ form: size: medium label: PLUGIN_EMAIL.SMTP_ENCRYPTION options: - none: None + none: PLUGIN_EMAIL.SMTP_ENCRYPTION_NONE ssl: SSL tls: TLS @@ -178,7 +178,7 @@ form: sendmail_config: type: section - title: Sendmail Configuration + title: PLUGIN_EMAIL.SENDMAIL_CONFIGURATION underline: true mailer.sendmail.bin: @@ -217,13 +217,13 @@ form: type: number label: PLUGIN_EMAIL.QUEUE_FLUSH_MSG_LIMIT size: x-small - append: Messages + append: PLUGIN_EMAIL.QUEUE_FLUSH_MSG_LIMIT_APPEND queue.flush_time_limit: type: number label: PLUGIN_EMAIL.QUEUE_FLUSH_TIME_LIMIT size: x-small - append: Seconds + append: PLUGIN_EMAIL.QUEUE_FLUSH_TIME_LIMIT_APPEND advanced_section: type: section diff --git a/languages.yaml b/languages.yaml index 74d4d8f..115f1de 100644 --- a/languages.yaml +++ b/languages.yaml @@ -1,8 +1,11 @@ en: PLUGIN_EMAIL: MAIL_ENGINE: "Mail Engine" + MAIL_ENGINE_DISABLED: "Disabled" CONTENT_TYPE: "Content type" + CONTENT_TYPE_PLAIN_TEXT: "Plain text" CHARSET: "Charset" + CHARSET_PLACEHOLDER: "Defaults to UTF-8" EMAIL_FORM: "From address" EMAIL_FORM_PLACEHOLDER: "Default email from address" EMAIL_FROM_NAME: "From name" @@ -28,6 +31,7 @@ en: SMTP_PORT: "SMTP port" SMTP_PORT_PLACEHOLDER: "Defaults to 25 (plaintext) / 587 (encrypted)" SMTP_ENCRYPTION: "SMTP encryption" + SMTP_ENCRYPTION_NONE: "None" SMTP_LOGIN_NAME: "SMTP login name" SMTP_PASSWORD: "SMTP password" PATH_TO_SENDMAIL: "Path to sendmail" @@ -38,6 +42,7 @@ en: TEST_EMAIL_BODY: "

Testing Email

This test email has been sent based on the following configuration:

%1$s

" EMAIL_DEFAULTS: "Email Defaults" SMTP_CONFIGURATION: "SMTP Configuration" + SENDMAIL_CONFIGURATION: "Sendmail Configuration" ADVANCED: "Advanced" EMAIL_FOOTER: "GetGrav.org" QUEUE_TITLE: "Email Queue" @@ -46,7 +51,9 @@ en: QUEUE_FLUSH_FREQUENCY: "Flush Frequency" QUEUE_FLUSH_FREQUENCY_HELP: "Use 'cron' format" QUEUE_FLUSH_MSG_LIMIT: "Messages per flush" + QUEUE_FLUSH_MSG_LIMIT_APPEND: "Messages" QUEUE_FLUSH_TIME_LIMIT: "Flush time limit" + QUEUE_FLUSH_TIME_LIMIT_APPEND: "Seconds" @@ -94,8 +101,12 @@ ro: ru: PLUGIN_EMAIL: MAIL_ENGINE: "Почтовая система" + MAIL_ENGINE_DISABLED: "Отключена" CONTENT_TYPE: "Тип контента" + CONTENT_TYPE_PLAIN_TEXT: "Простой текст" CHARSET: "Кодировка" + CHARSET_PLACEHOLDER: "По умолчанию UTF-8" + EMAIL_DEFAULTS: "Email настройки по умолчанию" EMAIL_FORM: "Почта отправителя" EMAIL_FORM_PLACEHOLDER: "Email адрес отправителя по умолчанию" EMAIL_FROM_NAME: "Имя почты отправителя" @@ -116,14 +127,27 @@ ru: EMAIL_REPLY_TO_NAME_PLACEHOLDER: "Email для ответов имя по умолчанию" EMAIL_BODY: "Тело сообщения" EMAIL_BODY_PLACEHOLDER: "По умолчанию используется таблица всех полей формы" + SMTP_CONFIGURATION: "Конфигурация SMTP" SMTP_SERVER: "SMTP сервер" SMTP_SERVER_PLACEHOLDER: "e.g. smtp.google.com" SMTP_PORT: "SMTP порт" SMTP_PORT_PLACEHOLDER: "По умолчанию 25 (plaintext) / 587 (encrypted)" SMTP_ENCRYPTION: "SMTP шифрование" + SMTP_ENCRYPTION_NONE: "Нет" SMTP_LOGIN_NAME: "SMTP логин" SMTP_PASSWORD: "SMTP пароль" + SENDMAIL_CONFIGURATION: "Конфигурация Sendmail" PATH_TO_SENDMAIL: "Путь к sendmail" + QUEUE_TITLE: "Очередь Email" + QUEUE_DESC: "Когда вы включаете очередь email, электронная почта не отправляется немедленно, а отправляется в очередь, затем планировщик Grav обрабатывает очередь и на основе настроенной частоты фактически отправляет электронную почту. Это гарантирует, что Grav не ждет завершения подключения к электронной почте." + QUEUE_ENABLED: "Включено" + QUEUE_FLUSH_FREQUENCY: "Частота обраблтки" + QUEUE_FLUSH_FREQUENCY_HELP: "Использовать формат 'cron'" + QUEUE_FLUSH_MSG_LIMIT: "Количество сообщений на задачу" + QUEUE_FLUSH_MSG_LIMIT_APPEND: "Сообщений" + QUEUE_FLUSH_TIME_LIMIT: "Ограничение времени обработки" + QUEUE_FLUSH_TIME_LIMIT_APPEND: "Секунд" + ADVANCED: "Расширенные" DEBUG: "Отладка" EMAIL_NOT_CONFIGURED: "Электронная почта не настроена" PLEASE_CONFIGURE_A_TO_ADDRESS: "Пожалуйста настройте адрес получателя ('to') в настройках плагина Email Plugin, или на форме" From 5ae4064ce50ab9400c0b737e00905404eb84cf0c Mon Sep 17 00:00:00 2001 From: Matias Griese Date: Wed, 8 May 2019 09:55:32 +0300 Subject: [PATCH 2/5] Fixed missing attachments when sending an email using a form [form#333] --- CHANGELOG.md | 8 ++++++++ blueprints.yaml | 1 + email.php | 4 ++-- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 724886c..25981bf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +# v3.0.2 +## mm/dd/2019 + +1. [](#new) + * Requires Form Plugin v3.0.3 +1. [](#bugfix) + * Better fix for missing attachments when sending an email using a form [form#333](https://github.com/getgrav/grav-plugin-form/issues/333) + # v3.0.1 ## 04/15/2019 diff --git a/blueprints.yaml b/blueprints.yaml index 50a7a53..63d794c 100644 --- a/blueprints.yaml +++ b/blueprints.yaml @@ -14,6 +14,7 @@ license: MIT dependencies: - { name: grav, version: '>=1.6.0' } + - { name: form, version: '>=3.0.3' } form: validation: loose diff --git a/email.php b/email.php index 6ac1062..3fa8143 100644 --- a/email.php +++ b/email.php @@ -72,8 +72,8 @@ public function onFormProcessed(Event $event) ); // Copy files now, we need those. - // TODO: we need a better solution. Maybe we can use streams for the attachments? - $form->copyFiles(); + // TODO: needs an update + $form->legacyUploads(); $grav = Grav::instance(); $grav->fireEvent('onEmailSend', new Event(['params' => &$params, 'vars' => &$vars])); From 1626741415f691887c1d4da882b6ce93a2185e65 Mon Sep 17 00:00:00 2001 From: Matias Griese Date: Wed, 8 May 2019 10:11:57 +0300 Subject: [PATCH 3/5] Fixed missing attachments when sending an email using a form (part 2) [form#333] --- email.php | 1 + 1 file changed, 1 insertion(+) diff --git a/email.php b/email.php index 3fa8143..1b7d3e0 100644 --- a/email.php +++ b/email.php @@ -74,6 +74,7 @@ public function onFormProcessed(Event $event) // Copy files now, we need those. // TODO: needs an update $form->legacyUploads(); + $form->copyFiles(); $grav = Grav::instance(); $grav->fireEvent('onEmailSend', new Event(['params' => &$params, 'vars' => &$vars])); From ee36d3763a254821f31dec600bd2b7f68f40b976 Mon Sep 17 00:00:00 2001 From: Andy Miller Date: Thu, 9 May 2019 10:19:58 -0600 Subject: [PATCH 4/5] updated changelog --- CHANGELOG.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 25981bf..49f69ff 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,8 +1,9 @@ # v3.0.2 -## mm/dd/2019 +## 05/09/2019 1. [](#new) * Requires Form Plugin v3.0.3 + * Added Russian translation [#113](https://github.com/getgrav/grav-plugin-email/pull/113) 1. [](#bugfix) * Better fix for missing attachments when sending an email using a form [form#333](https://github.com/getgrav/grav-plugin-form/issues/333) From b03decf934b374c6979649a1c5bd6c7eb255857d Mon Sep 17 00:00:00 2001 From: Andy Miller Date: Thu, 9 May 2019 10:20:37 -0600 Subject: [PATCH 5/5] prepare for release --- blueprints.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blueprints.yaml b/blueprints.yaml index 76e3437..dc54865 100644 --- a/blueprints.yaml +++ b/blueprints.yaml @@ -1,5 +1,5 @@ name: Email -version: 3.0.1 +version: 3.0.2 testing: false description: Enables the emailing system for Grav icon: envelope