Class: Hyrax::Admin::WorkflowRolesController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- Hyrax::Admin::WorkflowRolesController
- Defined in:
- app/controllers/hyrax/admin/workflow_roles_controller.rb
Instance Method Summary collapse
Instance Method Details
#create ⇒ Object
22 23 24 25 26 27 28 29 30 31 |
# File 'app/controllers/hyrax/admin/workflow_roles_controller.rb', line 22 def create :create, Sipity::WorkflowResponsibility form = Forms::WorkflowResponsibilityForm.new(params[:sipity_workflow_responsibility]) begin form.save! rescue ActiveRecord::RecordNotUnique logger.info "Not unique *****\n\n\n" end redirect_to admin_workflow_roles_path end |
#destroy ⇒ Object
15 16 17 18 19 20 |
# File 'app/controllers/hyrax/admin/workflow_roles_controller.rb', line 15 def destroy responsibility = Sipity::WorkflowResponsibility.find(params[:id]) :destroy, responsibility responsibility.destroy redirect_to admin_workflow_roles_path end |
#index ⇒ Object
8 9 10 11 12 13 |
# File 'app/controllers/hyrax/admin/workflow_roles_controller.rb', line 8 def index t(:'hyrax.controls.home'), root_path t(:'hyrax.dashboard.breadcrumbs.admin'), hyrax.dashboard_path t(:'hyrax.admin.workflow_roles.header'), hyrax.admin_workflow_roles_path @presenter = WorkflowRolesPresenter.new end |