diff --git a/app/controllers/personalization_settings_controller.rb b/app/controllers/personalization_settings_controller.rb index 9812aaee..d9d33490 100644 --- a/app/controllers/personalization_settings_controller.rb +++ b/app/controllers/personalization_settings_controller.rb @@ -4,6 +4,7 @@ class PersonalizationSettingsController < ApplicationController ALLOWED_KEYS = [ AccountConfig::FORM_COMPLETED_BUTTON_KEY, AccountConfig::SUBMITTER_INVITATION_EMAIL_KEY, + AccountConfig::SUBMITTER_INVITATION_REMINDER_EMAIL_KEY, AccountConfig::SUBMITTER_DOCUMENTS_COPY_EMAIL_KEY, AccountConfig::SUBMITTER_COMPLETED_EMAIL_KEY, AccountConfig::FORM_COMPLETED_MESSAGE_KEY, diff --git a/app/controllers/templates_preferences_controller.rb b/app/controllers/templates_preferences_controller.rb index 6b610b57..391b6714 100644 --- a/app/controllers/templates_preferences_controller.rb +++ b/app/controllers/templates_preferences_controller.rb @@ -5,6 +5,8 @@ class TemplatesPreferencesController < ApplicationController RESETTABLE_PREFERENCE_KEYS = { AccountConfig::SUBMITTER_INVITATION_EMAIL_KEY => %w[request_email_subject request_email_body submitters], + AccountConfig::SUBMITTER_INVITATION_REMINDER_EMAIL_KEY => %w[invitation_reminder_email_subject + invitation_reminder_email_body], AccountConfig::SUBMITTER_DOCUMENTS_COPY_EMAIL_KEY => %w[documents_copy_email_subject documents_copy_email_body], AccountConfig::SUBMITTER_COMPLETED_EMAIL_KEY => %w[completed_notification_email_subject completed_notification_email_body] @@ -46,14 +48,14 @@ class TemplatesPreferencesController < ApplicationController def template_params params.require(:template).permit( preferences: %i[bcc_completed request_email_subject request_email_body + invitation_reminder_email_subject invitation_reminder_email_body documents_copy_email_subject documents_copy_email_body documents_copy_email_enabled documents_copy_email_attach_audit documents_copy_email_attach_documents documents_copy_email_reply_to completed_notification_email_attach_documents completed_redirect_url validate_unique_submitters require_all_submitters submitters_order require_phone_2fa - default_expire_at_duration shared_link_2fa - default_expire_at request_email_enabled + default_expire_at_duration shared_link_2fa default_expire_at request_email_enabled completed_notification_email_subject completed_notification_email_body completed_notification_email_enabled completed_notification_email_attach_audit] + [completed_message: %i[title body], diff --git a/app/models/account_config.rb b/app/models/account_config.rb index 462cc725..c2893360 100644 --- a/app/models/account_config.rb +++ b/app/models/account_config.rb @@ -22,6 +22,7 @@ # class AccountConfig < ApplicationRecord SUBMITTER_INVITATION_EMAIL_KEY = 'submitter_invitation_email' + SUBMITTER_INVITATION_REMINDER_EMAIL_KEY = 'submitter_invitation_reminder_email' SUBMITTER_COMPLETED_EMAIL_KEY = 'submitter_completed_email' SUBMITTER_DOCUMENTS_COPY_EMAIL_KEY = 'submitter_documents_copy_email' BCC_EMAILS = 'bcc_emails' @@ -59,6 +60,12 @@ class AccountConfig < ApplicationRecord 'body' => I18n.t(:submitter_invitation_email_sign_body) } }, + SUBMITTER_INVITATION_REMINDER_EMAIL_KEY => lambda { + { + 'subject' => I18n.t(:you_are_invited_to_sign_a_document), + 'body' => I18n.t(:submitter_invitation_email_sign_body) + } + }, SUBMITTER_COMPLETED_EMAIL_KEY => lambda { { 'subject' => I18n.t(:template_name_has_been_completed_by_submitters), diff --git a/app/views/templates_preferences/_submitter_invitation_reminder_email_collapse.html.erb b/app/views/templates_preferences/_submitter_invitation_reminder_email_collapse.html.erb new file mode 100644 index 00000000..e69de29b diff --git a/app/views/templates_preferences/show.html.erb b/app/views/templates_preferences/show.html.erb index 71c0f7e4..290286cf 100644 --- a/app/views/templates_preferences/show.html.erb +++ b/app/views/templates_preferences/show.html.erb @@ -101,6 +101,7 @@ <%= render 'templates_preferences/submitter_invitation_email_form' %> + <%= render 'templates_preferences/submitter_invitation_reminder_email_collapse' %>