Skip to content

Commit

Permalink
add researcher to validations
Browse files Browse the repository at this point in the history
  • Loading branch information
mwvolo committed Apr 12, 2023
1 parent aa39048 commit a625339
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion app/handlers/newflow/educator_signup/complete_profile.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class CompleteProfile
validates(
:educator_specific_role,
inclusion: {
in: %w(instructor administrator other),
in: %w(instructor researcher administrator other),
}
)
end
Expand Down
3 changes: 2 additions & 1 deletion app/models/user.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ class User < ApplicationRecord
DESIGNER_ROLE = :designer,
OTHER_ROLE = :other,
ADJUNCT_ROLE = :adjunct,
HOMESCHOOL_ROLE = :homeschool
HOMESCHOOL_ROLE = :homeschool,
RESEARCHER_ROLE = :researcher,
].freeze

VALID_FACULTY_STATUSES = [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<%
educator_complete_roles = [
[ I18n.t(:'educator_profile_form.instructor'), 'instructor', false ],
[I18n.t(:'educator_profile_form.researcher'), 'researcher', false],
[ I18n.t(:'educator_profile_form.researcher'), 'researcher', false ],
[ I18n.t(:'educator_profile_form.administrator'), 'administrator', false ],
[ I18n.t(:'educator_profile_form.other'), 'other', false ]
]
Expand Down
6 changes: 3 additions & 3 deletions config/secrets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@ development:
httponly: <%= ActiveModel::Type::Boolean.new.cast ENV.fetch('SSO_COOKIE_HTTPONLY', true) %>
same_site: <%= ENV['SSO_COOKIE_OPTIONS_SAME_SITE'] %>

cms_url: https://cms-dev.openstax.org
openstax_url: https://dev.openstax.org
cms_url: https://staging.openstax.org
openstax_url: https://staging.openstax.org

cms_api_url: https://cms-dev.openstax.org/apps/cms/api/
cms_api_url: https://staging.openstax.org/apps/cms/api/
sentry:
dsn: <%= ENV['SENTRY_DSN'] || 'invalid' %>

Expand Down

0 comments on commit a625339

Please sign in to comment.