Sha256: f1f17e76b9dd222792aa0a67ad02f9bcf3af8db0fd07e3ce01d3532c53b7e95c
Contents?: true
Size: 898 Bytes
Versions: 81
Compression:
Stored size: 898 Bytes
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 create system notifications, which # will be later listed to the user in their Notifications Dashboard. # # This modules adds the needed logic to display these notifications. # # Example: # # class MyEvent < Decidim::Events::BaseEvent # include Decidim::Events::NotificationEvent # end module NotificationEvent extend ActiveSupport::Concern included do type :notification def notification_title I18n.t( "decidim.events.notification_event.notification_title", resource_title: resource_title, resource_path: resource_path ).html_safe end end end end end
Version data entries
81 entries across 81 versions & 1 rubygems