Sha256: b484ea32291413ece6d0b2f6f250a0e9529dc4cbbf427a8ac0c9c8bee4080573

Contents?: true

Size: 383 Bytes

Versions: 23

Compression:

Stored size: 383 Bytes

Contents

# frozen-string_literal: true

module Decidim
  class AttachmentCreatedEvent < Decidim::Events::SimpleEvent
    i18n_attributes :attached_to_url

    def resource_path
      @resource.url
    end

    def resource_url
      @resource.url
    end

    private

    def attached_to_url
      resource_locator.url
    end

    def resource
      @resource.attached_to
    end
  end
end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
decidim-admin-0.15.2 app/events/decidim/attachment_created_event.rb
decidim-admin-0.15.1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.15.0 app/events/decidim/attachment_created_event.rb
decidim-admin-0.14.4 app/events/decidim/attachment_created_event.rb
decidim-admin-0.14.3 app/events/decidim/attachment_created_event.rb
decidim-admin-0.14.2 app/events/decidim/attachment_created_event.rb
decidim-admin-0.14.1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.13.1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.12.2 app/events/decidim/attachment_created_event.rb
decidim-admin-0.13.0 app/events/decidim/attachment_created_event.rb
decidim-admin-0.12.1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.13.0.pre1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.12.0 app/events/decidim/attachment_created_event.rb
decidim-admin-0.11.2 app/events/decidim/attachment_created_event.rb
decidim-admin-0.12.0.pre app/events/decidim/attachment_created_event.rb
decidim-admin-0.11.1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.11.0.pre1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.10.1 app/events/decidim/attachment_created_event.rb
decidim-admin-0.10.0 app/events/decidim/attachment_created_event.rb
decidim-admin-0.9.3 app/events/decidim/attachment_created_event.rb