app/controllers/meetings_controller.rb
# Prepares the instance variables for the #show_full action.
# Used also in #show_autoscroll.
#
Prepares the instance variables for the #show_full action.
Used also in #show_autoscroll.
Prepares the instance variables for the #show_full action . Used also in #show_autoscroll .
def prepare_show_full
    @preselected_swimmer_id = params[:swimmer_id]
    @preselected_team_id    = params[:team_id]
    @meeting_events_list = @meeting.meeting_events
      .joins( :meeting_session, :event_type, :stroke_type )
      .includes( :meeting_session, :event_type, :stroke_type )
      .unscope( :order )
      .order( 'meeting_sessions.session_order, meeting_events.event_order' )
    last_mir_updated_at       = get_timestamp_from_relation_chain() 
    last_mrr_updated_at       = get_timestamp_from_relation_chain( :meeting_relay_results )
    last_passage_updated_at   = get_timestamp_from_relation_chain( :passages )
    last_rswimmer_updated_at  = get_timestamp_from_relation_chain( :meeting_relay_swimmers )
    @max_updated_at = [
      last_mir_updated_at, last_mrr_updated_at,
      last_passage_updated_at, last_rswimmer_updated_at
    ].max
  end
def prepare_show_full @preselected_swimmer_id = params [ :swimmer_id ] @preselected_team_id = params [ :team_id ] @meeting_events_list = @meeting . meeting_events . joins ( :meeting_session , :event_type , :stroke_type ) . includes ( :meeting_session , :event_type , :stroke_type ) . unscope ( :order ) . order ( 'meeting_sessions.session_order, meeting_events.event_order' ) last_mir_updated_at = get_timestamp_from_relation_chain ( ) last_mrr_updated_at = get_timestamp_from_relation_chain ( :meeting_relay_results ) last_passage_updated_at = get_timestamp_from_relation_chain ( :passages ) last_rswimmer_updated_at = get_timestamp_from_relation_chain ( :meeting_relay_swimmers ) @max_updated_at = [ last_mir_updated_at , last_mrr_updated_at , last_passage_updated_at , last_rswimmer_updated_at ] . max end
Prepares the instance variables for the #show_full action.
Prepares the instance variables for the #show_full action .
# Get a timestamp for the cache key, either from last MIR, last MRR (when existing), # last Passage (when existing) or last Relay Swimmer (when existing). # default: MIR