Class: Decidim::Meetings::HighlightedMeetingsForComponentCell

Inherits:
ViewModel
  • Object
show all
Includes:
CardHelper, ComponentPathHelper, ApplicationHelper
Defined in:
app/cells/decidim/meetings/highlighted_meetings_for_component_cell.rb

Overview

This cell renders the highlighted meetings for a given component. It is intended to be used in the ‘participatory_space_highlighted_elements` view hook.

Instance Method Summary collapse

Methods included from ApplicationHelper

#activity_filter_values, #apply_meetings_pack_tags, #filter_date_values, #filter_origin_values, #filter_type_values, #iframe_embed_or_live_event_page?, #online_or_hybrid_meeting?, #prevent_timeout_seconds, #render_meeting_body, #render_meeting_sanitize_field, #safe_content?, #safe_content_admin?

Methods included from MapHelper

#meetings_data_for_map

Instance Method Details

#items_blank?Boolean

Returns:

  • (Boolean)


21
22
23
# File 'app/cells/decidim/meetings/highlighted_meetings_for_component_cell.rb', line 21

def items_blank?
  meetings_count.zero?
end

#showObject



17
18
19
# File 'app/cells/decidim/meetings/highlighted_meetings_for_component_cell.rb', line 17

def show
  render unless items_blank?
end