Class: MailyHerald::Webui::ListsController
Instance Method Summary
collapse
#create, #destroy, #edit, #index, #new, #show, #update
#expert_mode?, #work_mode
included
included
Instance Method Details
#context_variables ⇒ Object
20
21
22
23
24
|
# File 'app/controllers/maily_herald/webui/lists_controller.rb', line 20
def context_variables
@context = MailyHerald.context(params[:context])
render layout: "maily_herald/webui/modal"
end
|
#subscribe ⇒ Object
6
7
8
9
10
11
|
# File 'app/controllers/maily_herald/webui/lists_controller.rb', line 6
def subscribe
find_item
@entity = @item.context.model.find params[:entity_id]
@item.subscribe! @entity
end
|
#unsubscribe ⇒ Object
13
14
15
16
17
18
|
# File 'app/controllers/maily_herald/webui/lists_controller.rb', line 13
def unsubscribe
find_item
@entity = @item.context.model.find params[:entity_id]
@item.unsubscribe! @entity
end
|