2015-10-05 15:24:37 +03:00
|
|
|
class Api::EventsController < Api::ApplicationController
|
2015-10-08 01:46:21 +03:00
|
|
|
include ::CurrentConferenceAssigning
|
2016-11-04 15:34:44 +02:00
|
|
|
include ::PublicApiExposing
|
2015-10-08 01:46:21 +03:00
|
|
|
before_filter :require_current_conference!
|
2015-10-05 15:24:37 +03:00
|
|
|
|
2015-10-08 01:46:21 +03:00
|
|
|
def index
|
2016-08-27 17:11:20 +03:00
|
|
|
@events = current_conference.events.approved.joins(:proposition).includes(:participations)
|
2015-10-05 15:24:37 +03:00
|
|
|
end
|
2015-10-08 02:54:16 +03:00
|
|
|
|
|
|
|
def halfnarp_friendly
|
|
|
|
@events = current_conference.events.includes(:track, :event_type)
|
|
|
|
render json: @events, include: [:track, :event_type]
|
|
|
|
end
|
2015-10-05 15:24:37 +03:00
|
|
|
end
|