Class: ActiveMetadata::StreamController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/active_metadata/stream_controller.rb

Instance Method Summary collapse

Instance Method Details

#indexObject



6
7
8
9
# File 'app/controllers/active_metadata/stream_controller.rb', line 6

def index
  @document = params[:model_name].to_class.find(params[:model_id])
  @stream = @document.stream_for params[:field_name]
end

#index_by_groupObject



11
12
13
14
# File 'app/controllers/active_metadata/stream_controller.rb', line 11

def index_by_group
  @stream = ActiveMetadata::Stream.by_group params[:group], starred_condition
  render :index
end