Module: Api::Services

Extended by:
ActiveSupport::Concern
Included in:
SpacesController
Defined in:
app/controllers/concerns/api/services.rb

Overview

Provides access to Service(s) and Activity(s) for Serviceable objects.

Instance Method Summary collapse

Instance Method Details

#index_activityObject

Returns all activities for the given Serviceable object.



14
15
16
# File 'app/controllers/concerns/api/services.rb', line 14

def index_activity
  render json: @obj.activities
end

#index_serviceObject

Returns all services for the given Serviceable object.



19
20
21
# File 'app/controllers/concerns/api/services.rb', line 19

def index_service
  render json: @obj.services
end