Sha256: 684181ef21f1c31ff6ff460abefb283cfe57e6250fe3067d41f7901da9a0325c
Contents?: true
Size: 1.06 KB
Versions: 50
Compression:
Stored size: 1.06 KB
Contents
# frozen-string_literal: true module Decidim module Events # This module is used to be included in event classes (those inheriting from # `Decidim::Events::BaseEvent`) that need to send emails with the notification. # # This modules adds the needed logic to deliver emails to a given user. # # Example: # # class MyEvent < Decidim::Events::BaseEvent # include Decidim::Events::EmailEvent # end module EmailEvent extend ActiveSupport::Concern included do type :email def email_subject I18n.t("decidim.events.email_event.email_subject", resource_title: resource_title) end def email_greeting I18n.t("decidim.events.email_event.email_greeting", user_name: user.name) end def email_intro I18n.t("decidim.events.email_event.email_intro", resource_title: resource_title) end def email_outro I18n.t("decidim.events.email_event.email_outro", resource_title: resource_title) end end end end end
Version data entries
50 entries across 50 versions & 1 rubygems