Skip to content

Commit

Permalink
feat(fworks): Addition of framework evaluator roles
Browse files Browse the repository at this point in the history
  • Loading branch information
ryantk committed Aug 23, 2023
1 parent a388ec4 commit 89a4674
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/models/support/agent.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ class Agent < ApplicationRecord
e_and_o: "Engagement and Outreach Staff Member",
internal: "Digital Team Staff Member",
analyst: "Data Analyst",
framework_evaluator: "Framework Evaluator",
}.freeze

has_many :cases, class_name: "Support::Case"
Expand Down
2 changes: 2 additions & 0 deletions app/policies/cms_portal_policy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ def access_proc_ops_portal? = allow_any_of(%w[global_admin internal procops_admi
def access_e_and_o_portal? = allow_any_of(%w[global_admin internal e_and_o_admin e_and_o])
def access_admin_settings? = allow_any_of(%w[global_admin procops_admin e_and_o_admin])
def access_establishment_search? = access_proc_ops_portal? || access_e_and_o_portal?
def access_frameworks_portal? = allow_any_of(%w[global_admin framework_evaluator])

# Agent management

Expand All @@ -27,6 +28,7 @@ def grant_e_and_o_admin_role? = allow_any_of(%w[global_admin e_and_o_admin])
def grant_e_and_o_role? = allow_any_of(%w[global_admin e_and_o_admin])
def grant_internal_role? = allow_any_of(%w[global_admin])
def grant_analyst_role? = allow_any_of(%w[global_admin])
def grant_framework_evaluator_role? = allow_any_of(%w[global_admin framework_evaluator])

private

Expand Down
1 change: 1 addition & 0 deletions spec/controllers/cms_entry_points_controller_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
"e_and_o" => :engagement_root_path,
"internal" => :support_root_path,
"analyst" => :support_case_statistics_path,
"framework_evaluator" => :frameworks_root_path
}

home_paths.each do |role, home_path|
Expand Down

0 comments on commit 89a4674

Please sign in to comment.