From 5b1fec366eb79405c95b6a9bf167e7d1572987e2 Mon Sep 17 00:00:00 2001 From: Hubert Krzysztofiak Date: Fri, 25 Mar 2022 15:07:28 +0100 Subject: [PATCH] Add reminder varable --- .../ReminderAboutTermVariables.php | 20 +++++++++++++++++++ .../ConsultationTemplatesServiceProvider.php | 3 +++ 2 files changed, 23 insertions(+) create mode 100644 src/Consultations/ReminderAboutTermVariables.php diff --git a/src/Consultations/ReminderAboutTermVariables.php b/src/Consultations/ReminderAboutTermVariables.php new file mode 100644 index 0000000..3d4dd02 --- /dev/null +++ b/src/Consultations/ReminderAboutTermVariables.php @@ -0,0 +1,20 @@ + __('Report term ":consultation"', [ + 'consultation' => self::VAR_CONSULTATION_TITLE, + ]), + 'content' => self::wrapWithMjml(__('

Hello :user_name!

I would like to remind you about the upcoming consultation :consultation, which will take place :proposed_term.

', [ + 'user_name' => self::VAR_USER_NAME, + 'consultation' => self::VAR_CONSULTATION_TITLE, + 'proposed_term' => self::VAR_CONSULTATION_PROPOSED_TERM + ]),), + ]; + } +} diff --git a/src/Providers/ConsultationTemplatesServiceProvider.php b/src/Providers/ConsultationTemplatesServiceProvider.php index 61adfe9..d1ad5a7 100644 --- a/src/Providers/ConsultationTemplatesServiceProvider.php +++ b/src/Providers/ConsultationTemplatesServiceProvider.php @@ -4,9 +4,11 @@ use EscolaLms\Consultations\Events\ApprovedTerm; use EscolaLms\Consultations\Events\RejectTerm; +use EscolaLms\Consultations\Events\ReminderAboutTerm; use EscolaLms\Consultations\Events\ReportTerm; use EscolaLms\TemplatesEmail\Consultations\ApprovedTermVariables; use EscolaLms\TemplatesEmail\Consultations\RejectTermVariables; +use EscolaLms\TemplatesEmail\Consultations\ReminderAboutTermVariables; use EscolaLms\TemplatesEmail\Consultations\ReportTermVariables; use EscolaLms\TemplatesEmail\Core\EmailChannel; use Illuminate\Support\ServiceProvider; @@ -19,5 +21,6 @@ public function boot() Template::register(ApprovedTerm::class, EmailChannel::class, ApprovedTermVariables::class); Template::register(RejectTerm::class, EmailChannel::class, RejectTermVariables::class); Template::register(ReportTerm::class, EmailChannel::class, ReportTermVariables::class); + Template::register(ReminderAboutTerm::class, EmailChannel::class, ReminderAboutTermVariables::class); } }