Sha256: 6749e9b9ae9c41baa01a53acbe0ff6f7a74607ea9b1d91548a3409b481a86e59
Contents?: true
Size: 740 Bytes
Versions: 2
Compression:
Stored size: 740 Bytes
Contents
# frozen_string_literal: true class Tramway::Event::SectionDecorator < ::Tramway::Landing::BlockTypes::FeaturesDecorator class << self def collections [:all] end def show_associations [ :partakings ] end end delegate_attributes :description, :created_at decorate_association :event decorate_association :partakings, as: :part, decorator: Tramway::Event::PartakingFeatureDecorator def name "#{object.title} | #{object.event.title}" end def title "#{fa_icon(object.icon)} #{object.title}".html_safe end def background object.photo end def anchor "section-#{object.id}" end def event_title event.title end def event_duration event.duration end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
tramway-event-1.12.8 | app/decorators/tramway/event/section_decorator.rb |
tramway-event-1.12.7 | app/decorators/tramway/event/section_decorator.rb |