Class: Curate::CollectionsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- Curate::CollectionsController
- Includes:
- Blacklight::Catalog, FieldsForAddToCollection, Hydra::AccessControlsEnforcement, Hydra::CollectionsControllerBehavior
- Defined in:
- app/controllers/curate/collections_controller.rb
Instance Method Summary collapse
Instance Method Details
#add_member ⇒ Object
52 53 54 55 56 57 58 59 |
# File 'app/controllers/curate/collections_controller.rb', line 52 def add_member if @collection && @collection.add_member(@collectible) flash[:notice] = "\"#{@collectible}\" has been added to \"#{@collection}\"" else flash[:error] = 'Unable to add item to collection.' end redirect_to catalog_index_path end |
#add_member_form ⇒ Object
46 47 48 49 50 |
# File 'app/controllers/curate/collections_controller.rb', line 46 def add_member_form render 'add_member_form' end |
#new ⇒ Object
41 42 43 44 |
# File 'app/controllers/curate/collections_controller.rb', line 41 def new @add_to_profile = params.delete(:add_to_profile) super end |