Sha256: beca6240b18170019b9df289cbb47755b9446ad1e80d1e0840cca9196946f44e

Contents?: true

Size: 1.07 KB

Versions: 36

Compression:

Stored size: 1.07 KB

Contents

module Hyrax
  # Presents a list of works in workflow
  class Admin::WorkflowsController < ApplicationController
    before_action :ensure_authorized!
    with_themed_layout 'dashboard'
    class_attribute :deposited_workflow_state_name

    # Works that are in this workflow state (see workflow json template) are excluded from the
    # status list and display in the "Published" tab
    self.deposited_workflow_state_name = 'deposited'

    def index
      add_breadcrumb t(:'hyrax.controls.home'), root_path
      add_breadcrumb t(:'hyrax.dashboard.breadcrumbs.admin'), hyrax.dashboard_path
      add_breadcrumb t(:'hyrax.admin.sidebar.tasks'), '#'
      add_breadcrumb t(:'hyrax.admin.sidebar.workflow_review'), request.path
      @status_list = Hyrax::Workflow::StatusListService.new(self, "-workflow_state_name_ssim:#{deposited_workflow_state_name}")
      @published_list = Hyrax::Workflow::StatusListService.new(self, "workflow_state_name_ssim:#{deposited_workflow_state_name}")
    end

    private

      def ensure_authorized!
        authorize! :review, :submissions
      end
  end
end

Version data entries

36 entries across 36 versions & 1 rubygems

Version Path
hyrax-2.9.6 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.9.5 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.9.4 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.9.3 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.9.2 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.9.1 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.9.0 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.8.0 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.7.2 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.7.1 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.7.0 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.6.0 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-3.0.0.pre.rc1 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-3.0.0.pre.beta3 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.5.1 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.5.0 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-3.0.0.pre.beta2 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.4.1 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-3.0.0.pre.beta1 app/controllers/hyrax/admin/workflows_controller.rb
hyrax-2.4.0 app/controllers/hyrax/admin/workflows_controller.rb