<%= t('headings.settings', "Account Settings") %>
<%= form_for :account, :url => account_url(@account), :html => {:method => :put, :id => "account_settings", :class => 'account_settings'} do |f| %>
<%= t(:account_settings_title, "Account Settings") %>
<%= f.blabel :name, :en => "Account Name" %>
<%= f.text_field :name, :class => 'same-width-as-select' %>
<% if [email protected] _account? && (@context.sis_source_id && can_do(@context.root_account, @current_user, :read_sis) || can_do(@context.root_account, @current_user, :manage_sis)) %>
<%= f.blabel :sis_source_id, :en => "SIS ID" %>
<% if can_do(@context.root_account, @current_user, :manage_sis) %>
<%= f.text_field :sis_source_id, :title => "SIS ID", :value => @context.sis_source_id %>
<% else %>
<%= @context.sis_source_id %>
<% end %>
<% end %>
<% if available_locales.size > 1 %>
<%= f.blabel :default_locale, :default_language, :en => "Default Language" %>
<% no_language = t(:no_language_preference, "Not set (defaults to %{language})", :language => available_locales[infer_locale(:context => @context.parent_account)]) %>
<%= f.select :default_locale,
[[no_language, nil]] + available_locales.invert.sort_by { |desc, _| Canvas::ICU.collation_key(desc) },
{:selected => @context.default_locale}, {:class => 'locale'} %>
<%= render :partial => 'shared/locale_warning' %>
<%= t(:default_language_description, "This will override any browser/OS language settings. Preferred languages can still be set at the course/user level.") %>
<% end %>
<% if [email protected] _admin? && @account.root_account.feature_enabled?(:default_due_time) %>
<%= f.fields_for :settings do |settings| %>
<%= settings.fields_for :default_due_time do |ddt| %>
<%= ddt.blabel :value, t("Default Due Time") %>
<%= ddt.select :value, options_for_select(default_due_time_options(@account), default_due_time_key(@account)) %>
<%= t("This influences the user interface for setting due dates. It does not change the time due for any existing assignments.") %>
<% end %>
<% end %>
<% end %>
<% if @account.primary_settings_root_account? %>
<%= f.blabel :default_time_zone, :en => "Default Time Zone" %>
<%= f.time_zone_select :default_time_zone, I18nTimeZone.us_zones, :model => I18nTimeZone %>
<% if @account.shard.database_server.maintenance_window_start_hour %>
<%= render partial: 'shared/maintenance_window', locals: { database_server: @account.shard.database_server, local_zone: @account.default_time_zone } %>
<% end %>
<%= f.fields_for :settings do |settings| %>
<% if @account.grants_right?(@current_user, :manage_site_settings) %>
<%= settings.blabel :mfa_settings, :en => "Multi-Factor Authentication" %>
<%= settings.select :mfa_settings, [[t('select.mfa.disabled', "Disabled"), :disabled],
[t('select.mfa.optional', "Optional"), :optional],
[t('select.mfa.required_for_admins', "Required for Admins"), :required_for_admins],
[t('select.mfa.required', "Required"), :required]], :selected => @account.mfa_settings %>
<%= settings.check_box :mobile_qr_login_is_enabled, checked: @account.mobile_qr_login_is_enabled? %>
<%= settings.label :mobile_qr_login_is_enabled, en: "Allow logins to the mobile apps via the use of QR codes" %>
<% end %>
<% unless @account.site_admin? %>
<%= settings.blabel :self_enrollment, :en => "Allow Self-Enrollment" %>
<%= settings.select :self_enrollment, [
[t(:never_allow_self_enrollment_option, 'Never'), ''],
[t(:self_enroll_for_manually_created_courses_option, 'For Manually-Created Courses'), 'manually_created'],
[t(:self_enroll_for_any_courses_option, 'For Any Courses'), 'any']
], :selected => @account.settings[:self_enrollment] %>
<%= settings.blabel :trusted_referers, :en => "Trusted HTTP Referers" %>
<%= settings.text_field :trusted_referers,
:value => @account.settings[:trusted_referers],
:class => 'same-width-as-select',
:placeholder => "https://example.edu" %>
<%= t("This is a comma separated list of URL's to trust. Trusting any URL's in this list will bypass the CSRF token when logging in to Canvas.") %>
<% if can_do(@context, @current_user, :manage_account_settings) %>
<%= settings.blabel :default_dashboard_view, t("Default View for Dashboard") %>
<%= settings.select :default_dashboard_view, options_for_select(dashboard_view_options, @account.default_dashboard_view) %>
<%= settings.check_box :force_default_dashboard_view, :checked => false %> <%= settings.label :force_default_dashboard_view, t("Overwrite all users' existing default dashboard preferences") %>
<% end %>
<%= settings.check_box :prevent_course_renaming_by_teachers, :checked => @account.settings[:prevent_course_renaming_by_teachers] %>
<%= settings.label :prevent_course_renaming_by_teachers, :en => "Don't let teachers rename their courses" %>
<%= settings.check_box :prevent_course_availability_editing_by_teachers, :checked => @account.settings[:prevent_course_availability_editing_by_teachers] %>
<%= settings.label :prevent_course_availability_editing_by_teachers, :en => "Don't let teachers modify course availability dates" %>
<%= settings.check_box :allow_sending_scores_in_emails, :checked => @account.settings[:allow_sending_scores_in_emails] != false %>
<%= settings.label :allow_sending_scores_in_emails, :en => "Students can opt-in to receiving scores in email notifications" %>
<% if @account.grants_right?(@current_user, :manage_site_settings) %>
<%= settings.check_box :include_students_in_global_survey, checked: @account.include_students_in_global_survey?%>
<%= settings.label :include_students_in_global_survey, en: "Include students in global surveys" %>
<% end %>
<%= settings.check_box :restrict_quiz_questions, :checked => @account.settings[:restrict_quiz_questions] %>
<%= settings.label :restrict_quiz_questions, :en => "Restrict students from viewing quiz questions after course end date" %>
<% end %>
<% end %>
<% end %>
<% unless @account.site_admin? %>
<%= f.fields_for :settings do |settings| %>
<%= settings.fields_for :restrict_student_future_view do |r| %>
<% hash = @account.restrict_student_future_view %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, :checked => hash[:value], :disabled => disabled %>
<%= r.label :value , t("Restrict students from accessing courses before start date") %>
<% unless disabled %>
<%= r.check_box :locked, :checked => hash[:locked] %>
<%= r.label :locked, :en => "Lock this setting for sub-accounts and courses" %>
<% end %>
<% end %>
<%= settings.fields_for :restrict_student_future_listing do |r| %>
<% hash = @account.restrict_student_future_listing %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, :checked => hash[:value], :disabled => disabled %>
<%= r.label :value, t("Restrict students from viewing future courses in enrollments list") %>
<% unless disabled %>
<%= r.check_box :locked, :checked => hash[:locked] %>
<%= r.label :locked, t("Lock this setting for sub-accounts") %>
<% end %>
<% end %>
<%= settings.fields_for :restrict_student_past_view do |r| %>
<% hash = @account.restrict_student_past_view %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, :checked => hash[:value], :disabled => disabled %>
<%= r.label :value, t("Restrict students from accessing courses after end date") %>
<% unless disabled %>
<%= r.check_box :locked, :checked => hash[:locked] %>
<%= r.label :locked, :en => "Lock this setting for sub-accounts and courses" %>
<% end %>
<% end %>
<% unless [email protected] _account.feature_enabled?(:restrict_quantitative_data) %>
<%= settings.fields_for :restrict_quantitative_data do |r| %>
<% hash = @account.restrict_quantitative_data %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, :checked => hash[:value], :disabled => disabled %>
<%= r.label :value, t("Restrict view of quantitative data") %>
<%= t(:rqd_screenreader, "About restrict quantitative data") %>
<%= t(:rqd_help_message,
"When selected, this setting will limit the view of new courses' quantitative (numeric) grading data. Students and observers will only see qualitative data, which includes letter grades and comments.") %>
<% unless disabled %>
<%= r.check_box :locked, :checked => hash[:locked] && hash[:value], :disabled => !hash[:value] %>
<%= r.label :locked, :en => "Lock this setting for sub-accounts and courses" %>
<% end %>
<% end %>
<% end %>
<%= settings.fields_for :lock_all_announcements do |r| %>
<% hash = @account.lock_all_announcements %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, :checked => hash[:value], :disabled => disabled %>
<%= r.label :value, :en => "Disable comments on announcements" %>
<% unless disabled %>
<%= r.check_box :locked, :checked => hash[:locked] %>
<%= r.label :locked, :en => "Lock this setting for sub-accounts and courses" %>
<% end %>
<% end %>
<%= settings.fields_for :conditional_release do |r| %>
<% hash = @account.conditional_release %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, :checked => hash[:value], :disabled => disabled %>
<%= r.label :value, t("Mastery Paths") %>
<% unless disabled %>
<%= r.check_box :locked, :checked => hash[:locked] %>
<%= r.label :locked, :en => "Lock this setting for sub-accounts and courses" %>
<% end %>
<% end %>
<%= settings.fields_for :enable_offline_web_export do |r| %>
<% hash = @account.enable_offline_web_export %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, checked: hash[:value], disabled: disabled %>
<%= r.label :value, t("Allow students to download course content and view offline") %>
<% end %>
<%= settings.fields_for :usage_rights_required do |r| %>
<% hash = @account.usage_rights_required %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, :checked => hash[:value], :disabled => disabled %>
<%= r.label :value, t("Copyright and license information must be provided for files before they are published.") %>
<% unless disabled %>
<%= r.check_box :locked, :checked => hash[:locked] %>
<%= r.label :locked, :en => "Lock this setting for sub-accounts and courses" %>
<% end %>
<% end %>
<%= settings.fields_for :disable_rce_media_uploads do |r| %>
<% hash = @account.disable_rce_media_uploads %>
<% disabled = hash[:locked] && hash[:inherited] %>
<%= r.check_box :value, checked: hash[:value], disabled: disabled %>
<%= r.label :value, t("Disable uploads to Canvas Media from the enhanced rich content editor") %>
<% end %>
<% if Account.site_admin.feature_enabled?(:observer_appointment_groups) %>
<%= settings.fields_for :allow_observers_in_appointment_groups do |r| %>
<% hash = @account.allow_observers_in_appointment_groups %>
<%= r.check_box :value, checked: hash[:value] %>
<%= r.label :value, t("Allow observers to sign-up for appointments when enabled by the teacher") %>
<% end %>
<% end %>
<% if Account.site_admin.feature_enabled?(:gradebook_show_first_last_names) %>
<%= settings.fields_for :allow_gradebook_show_first_last_names do |r| %>
<% hash = @account.allow_gradebook_show_first_last_names %>
<%= r.check_box :value, checked: hash[:value] %>
<%= r.label :value, t("Allow gradebook users to view and export student first and last names in separate columns") %>
<% end %>
<% end %>
<% if [email protected] _admin? && @account.primary_settings_root_account? %>
<%= settings.check_box :allow_additional_email_at_registration, checked: @account.allow_additional_email_at_registration? %>
<%= settings.label :allow_additional_email_at_registration, t("Allow users to submit an additional email at registration.") %>
<% end %>
<% if [email protected] _admin? && @account.primary_settings_root_account? %>
<%= settings.check_box :show_sections_in_course_tray, checked: @account.show_sections_in_course_tray? %>
<%= settings.label :show_sections_in_course_tray, t("Show Sections in Course Tray.") %>
<% end %>
<% if [email protected] _admin? && @account.primary_settings_root_account? && @account.feature_enabled?(:admin_manage_access_tokens)%>
<%= settings.check_box :limit_personal_access_tokens, checked: @account.limit_personal_access_tokens? %>
<%= settings.label :limit_personal_access_tokens, t("Limit personal access token creation to Admins.") %>
<% end%>
<% end %>
<% end %>
<%= render partial: 'additional_settings', locals: { f: f } %>
<% if
[email protected] _admin? && @account.primary_settings_root_account? && @account.feature_enabled?(:slack_notifications)%>
<% slack_api_key = @account.root_account.settings[:encrypted_slack_key] ? Canvas::Security.decrypt_password(@account.root_account.settings[:encrypted_slack_key], @account.root_account.settings[:encrypted_slack_key_salt], 'instructure_slack_encrypted_key') : '' %>
<%= t("Slack Api Key") %>
<%= t("Current Slack Api Key:") %>
<%= slack_api_key.length > 4 ? "#{slack_api_key[0..3]}#{'*' * (slack_api_key.length - 4)}" : '****' %>
<%= f.fields_for :slack do |slack| %>
<%= slack.label :slack_api_key , t("New Slack Api Key") %>
<%= slack.text_field :slack_api_key, placeholder: t("New Slack Api Key"), value:''%>
<% end %>
<% end %>
<% if @account.primary_settings_root_account? %>
<%= t("Personal Profile Settings") %>
<%= f.fields_for :settings do |settings| %>
<% if @account.grants_right?(@current_user, :manage_site_settings) %>
<%= settings.check_box :enable_profiles, :checked => @account.settings[:enable_profiles] %>
<%= settings.label :enable_profiles, :en => "Enable Profiles" %>
<% end %>
<% if [email protected] _admin? && @account.root_account? %>
<%= settings.check_box :enable_name_pronunciation, :checked => @account.enable_name_pronunciation?, class: "element_toggler", "aria-controls": "name_pronunciation_options" %>
<%= settings.label :enable_name_pronunciation, :en => "Enable name pronunciation" %>
>
<%= t(:pronunciation_change_description, "Limit name pronunciation editing by base role") %>
<%= settings.check_box :allow_name_pronunciation_edit_for_admins, :checked => @account.allow_name_pronunciation_edit_for_admins? %>
<%= settings.label :allow_name_pronunciation_edit_for_admins, :en => "Admin" %>
<%= settings.check_box :allow_name_pronunciation_edit_for_teachers, :checked => @account.allow_name_pronunciation_edit_for_teachers? %>
<%= settings.label :allow_name_pronunciation_edit_for_teachers, :en => "Teacher" %>
<%= settings.check_box :allow_name_pronunciation_edit_for_students, :checked => @account.allow_name_pronunciation_edit_for_students? %>
<%= settings.label :allow_name_pronunciation_edit_for_students, :en => "Student" %>
<% end %>
<% if [email protected] _admin? %>
<%= settings.check_box :can_add_pronouns, :checked => @account.settings[:can_add_pronouns], class: "element_toggler", "aria-controls": "personal_pronouns_options" %>
<%= settings.label :can_add_pronouns, en: "Enable Personal Pronouns" %>
>
<%= settings.check_box :can_change_pronouns, :checked => @account.can_change_pronouns? %>
<%= settings.label :can_change_pronouns, en: "Allow users to change their pronouns in Canvas" %>
<% js_env(PRONOUNS_LIST: ((@account.pronouns.presence || Pronouns.default_pronouns)))
js_bundle :available_pronouns_list %>
<% end %>
<%= settings.check_box :users_can_edit_name, :checked => @account.users_can_edit_name? %>
<%= settings.label :users_can_edit_name, :en => "Users can edit their name" %>
<%= settings.check_box :users_can_edit_profile, :checked => @account.users_can_edit_profile? %>
<%= settings.label :users_can_edit_profile, :en => "Users can edit their profile" %>
<% end %>
<% end %>
<% if
[email protected] _admin? && @account.root_account? && @account.grants_right?(@current_user, :manage_site_settings) %>
<% TermsOfService.ensure_terms_for_account(@account) %>
<% js_bundle :terms_of_service_modal%>
<%= t("Acceptable Use Policy") %>
<%= f.fields_for :terms_of_service do |tos| %>
<%= tos.label :terms_type, t("License Type") %>
<% if TermsOfService.type_dropdown_options_for_account(@account)[0][1] == "built_in:default" %>
(<%= t("Old Policy") %>)
<% end %>
<%= tos.select :terms_type, options_for_select(TermsOfService.type_dropdown_options_for_account(@account), @account.terms_of_service.terms_type) %>
<%= tos.check_box :passive, :checked => @account.terms_of_service.passive %>
<%= tos.label :passive, t("Allow passive acceptance of Terms of Service")%>
<% end %>
<% end %>
<% if
[email protected] _admin? &&
@account.primary_settings_root_account? &&
@account.feature_enabled?(:google_docs_domain_restriction) &&
@account.grants_right?(@current_user, :manage_site_settings) %>
<%= t(:google_docs_domain, 'Allowed Google Docs Domain') %>
<%= f.fields_for :settings do |settings| %>
<%= settings.label :google_docs_domain, t('labels.domain', 'Domain:') %>
<%= settings.text_field :google_docs_domain, placeholder: 'gmail.com', value: @account.settings[:google_docs_domain] %>
<% end %>
<% end %>
<% unless @account.site_admin? %>
<%= t('Quiz IP Address Filters') %>
<%= t('Quiz IP Address Filters') %>
<%= t(:quiz_ip_filters_help_tooltip, "What are Quiz IP Filters?") %>
<%= t(:quiz_ip_filters_help_title, "What are Quiz IP Filters?") %>
<%= mt(:quiz_ip_filters_help_message,
"Quiz IP filters are a way to limit access to quizzes to computers in a specified IP range.\n\n" +
"Specify a set of IP address filters that teachers can use to " +
"protect access to quizzes. Filters can be a comma-separated " +
"list of addresses, or an address followed by a mask " +
"(\"192.168.217.1/24\" or \"192.168.217.1/255.255.255.0\").\"") %>
"
>
<%= t(:add_ip_filter_link, "Filter") %>
<% end %>
<%= t('Features') %>
<%= t(:features_title, "Features") %>
<%= f.fields_for :settings do |settings| %>
<% k5_settings = @account.enable_as_k5_account %>
<% disabled = k5_settings[:locked] && k5_settings[:inherited] %>
<%= settings.fields_for :enable_as_k5_account do |k5| %>
<%= k5.check_box :value, :checked => k5_settings[:value], :disabled => disabled %>
<%= k5.label :value, t("Canvas for Elementary") %>
<% end %>
<%= t ("This setting significantly changes the Canvas experience for students and teachers.")%>
<%= t do %>
To learn more about Canvas for Elementary, please refer to our documentation .
<% end %>
<% font_settings = @account.use_classic_font_in_k5 %>
<%= settings.fields_for :use_classic_font_in_k5 do |font| %>
<%= t('Canvas for Elementary Font Selection') %>
<%= font.radio_button :value, false, checked: !font_settings[:value], disabled: disabled, id: "k5_font_disabled_radio" %>
<%= font.label :value, t("Large Balsamiq Font"), for: "k5_font_disabled_radio", style: "margin-bottom: 0;" %>
<%= font.radio_button :value, true, checked: font_settings[:value], disabled: disabled, id: "k5_font_enabled_radio" %>
<%= font.label :value, t("Regular Lato Font"), for: "k5_font_enabled_radio" %>
<% end %>
<% if @account.grants_right?(@current_user, :manage_account_settings) && @account.root_account.feature_enabled?(:allow_limited_access_for_students)%>
<%= settings.check_box :enable_limited_access_for_students, :checked => @account.enable_limited_access_for_students? %>
<%= settings.label :enable_limited_access_for_students, :en => "Enable Limited Access for Students for this account" %>
<% end %>
<% if @account.primary_settings_root_account? %>
<% if @account.grants_right?(@current_user, :manage_site_settings) %>
<%= settings.check_box :admins_can_change_passwords, :checked => @account.settings[:admins_can_change_passwords] == true %>
<%= settings.label :admins_can_change_passwords, :en => "Password setting by admins" %>
<%= settings.check_box :admins_can_view_notifications, :checked => @account.settings[:admins_can_view_notifications] %>
<%= settings.label :admins_can_view_notifications, :en => "Admins can view notifications" %>
<% unless @account.site_admin? %>
<%= settings.check_box :enable_eportfolios, :checked => @account.settings[:enable_eportfolios] != false %>
<%= settings.label :enable_eportfolios, :en => "ePortfolios" %>
<% if [email protected] _enabled?(:new_sis_integrations) %>
<%= f.check_box :allow_sis_import, :checked => @account.allow_sis_import %>
<%= f.label :allow_sis_import, t("SIS imports") %>
<%= f.fields_for :settings do |settings| %>
<%= settings.check_box :include_integration_ids_in_gradebook_exports, :checked => @account.settings[:include_integration_ids_in_gradebook_exports] == true %>
<%= settings.label :include_integration_ids_in_gradebook_exports, t("Include Integration IDs in the gradebook exports") %>
<% end %>
<% end %>
<%= settings.check_box :allow_invitation_previews, :checked => @account.settings[:allow_invitation_previews] %>
<%= settings.label :allow_invitation_previews, :en => "Invitation Previews" %>
<%= settings.check_box :enable_alerts, :checked => @account.settings[:enable_alerts] %>
<%= settings.label :enable_alerts, :en => "Alerts (beta)" %>
<% end %>
<%# end of site_admin? %>
<%= settings.check_box :global_includes, :checked => @account.settings[:global_includes] %>
<%= settings.label :global_includes, :en => "Custom CSS/JavaScript overrides" %>
<%= t ("Custom CSS and Javascript may cause accessibility issues or conflicts with future Canvas updates!")%>
<%= t do %>
Before implementing custom CSS or Javascript, please refer to our documentation .
<% end %>
<%= settings.check_box :show_scheduler, :checked => @account.settings[:show_scheduler] %>
<%= settings.label :show_scheduler, :en => "Enable Scheduler" %>
<%= settings.check_box :limit_parent_app_web_access, :checked => @account.settings[:limit_parent_app_web_access] %>
<%= settings.label :limit_parent_app_web_access, :en => "Limit access to Canvas web from the Canvas Parent app" %>
<% end %>
<%# end of :manage_site_settings %>
<%= settings.check_box :sub_account_includes, checked: @account.settings[:sub_account_includes] %>
<%= settings.label :sub_account_includes, :en => "Let sub-accounts use the Theme Editor to customize their own branding" %>
<% if @account.canvas_authentication? %>
<%= settings.check_box :open_registration, :checked => @account.open_registration? %>
<%= settings.label :open_registration, :en => "Open Registration" %>
<% if @account.delegated_authentication? %>
<%= link_to(image_tag('warning.png', :alt => ''), '#',
:class => 'open_registration_delegated_warning_link no-hover',
:title => t(:open_registration_delegated_warning_tooltip,
"An External Identity Provider is Enabled"))
%>
<%= t(:open_registration_delegated_warning_message,
"An external identity provider is enabled, and users created via open registration may not be able to log in unless
the external identity provider's login form has a link back to %{url}.", :url => canvas_login_url) %>
<% end %>
<% end %>
<% if [email protected] _admin? && @account.root_account? && Account.site_admin.feature_enabled?(:inbox_settings) %>
<% inbox_signature_block_enabled = @account.enable_inbox_signature_block? %>
<%= settings.check_box :enable_inbox_signature_block, :checked => inbox_signature_block_enabled %>
<%= settings.label :enable_inbox_signature_block, :en => "Enable Inbox Signature Block" %>
<%= settings.check_box :disable_inbox_signature_block_for_students, :checked => @account.disable_inbox_signature_block_for_students?, :disabled => !inbox_signature_block_enabled %>
<%= settings.label :disable_inbox_signature_block_for_students, :en => "Disable Inbox Signature Block for Students" %>
<% inbox_auto_response_enabled = @account.enable_inbox_auto_response? %>
<%= settings.check_box :enable_inbox_auto_response, :checked => inbox_auto_response_enabled %>
<%= settings.label :enable_inbox_auto_response, :en => "Enable Inbox Auto Response" %>
<%= settings.check_box :disable_inbox_auto_response_for_students, :checked => @account.disable_inbox_auto_response_for_students?, :disabled => !inbox_auto_response_enabled %>
<%= settings.label :disable_inbox_auto_response_for_students, :en => "Disable Inbox Auto Response for Students" %>
<% end %>
<%= settings.check_box :users_can_edit_comm_channels, :checked => @account.users_can_edit_comm_channels? %>
<%= settings.label :users_can_edit_comm_channels, :en => "Users can edit their communication channels" %>
<%= settings.check_box :edit_institution_email, :checked => @account.edit_institution_email? %>
<%= settings.label :edit_institution_email, :en => "Users can delete their institution-assigned email address" %>
<%= settings.check_box :author_email_in_notifications, :checked => @account.author_email_in_notifications? %>
<%= settings.label :author_email_in_notifications, :en => "Show the email address of sender for user interaction Notifications" %>
<%= settings.check_box :enable_course_catalog, :checked => @account.settings[:enable_course_catalog] %>
<%= settings.label :enable_course_catalog, :en => "Show a searchable list of courses in this root account with the \"Include this course in the public course index\" flag enabled." %>
<% if Account.site_admin.feature_enabled?(:show_push_notification_account_setting) %>
<%= settings.check_box :enable_push_notifications, :checked => @account.enable_push_notifications? %>
<%= settings.label :enable_push_notifications, :en => "Enable push notifications to mobile devices" %>
<% end %>
<% unless @account.site_admin? %>
<%= settings.check_box :kill_joy, :checked => @account.kill_joy? %>
<%= settings.label :kill_joy, :en => "Remove hidden game from 404 page" %>
<% end %>
<% unless @account.site_admin? %>
<%= settings.check_box :suppress_notifications, :checked => @account.suppress_notifications? %>
<%= settings.label :suppress_notifications, :en => "Suppress notifications from being created and sent out" %>
<% end %>
<% end %>
<% unless @account.site_admin? %>
/>
<%= t 'labels.equella', 'Equella' %>
<% end %>
<% if @account.grants_right?(@current_user, :manage_site_settings) %>
<%= settings.check_box :enable_turnitin, :checked => @account.settings[:enable_turnitin] %>
<%= settings.label :enable_turnitin, :en => "Turnitin" %>
<% end %>
<% end %>
<%= f.fields_for :services do |services| %>
<% Account.services_exposed_to_ui_hash(:setting, @current_user, @account).sort_by { |k,h| Canvas::ICU.collation_key(h[:name]) }.each do |key, service| %>
<%= services.check_box key, :checked => @account.service_enabled?(key) %>
<%= services.label key, service[:name] + " " %>
<% if key == :avatars && @account.primary_settings_root_account? %>
<%= hidden_field_tag "account[settings][enable_gravatar]", "0", id: "hidden_account_settings_enable_gravatar" %>
<%= check_box_tag "account[settings][enable_gravatar]", "1", @account.enable_gravatar? %>
<%= label_tag "account[settings][enable_gravatar]", t("Enable Gravatar") %>
<% end %>
<% end %>
<% end %>
<% unless @account.site_admin? %>
<% if @account.feature_enabled?(:new_sis_integrations) %>
<%= render partial: 'sis_integration_settings', locals: { f: f } %>
<% else %>
<%= render partial: 'sis_integration_settings_old', locals: { f: f } %>
<% end %>
<% end %>
<% if @account.primary_settings_root_account? &&
[email protected] _admin? %>
<% end %>
<% unless @account.site_admin? %>
<%= t(:equella_settings_title, "Equella Settings") %>
<%= f.fields_for :settings do |settings| %>
<% end %>
<%= t("Similarity Detection Platform") %>
<% if @account.settings[:enable_turnitin] %>
<%= t(:turnitin_settings_title, "Turnitin Settings") %>
<% end %>
<% end %>
<% if
[email protected] _admin? &&
@account.primary_settings_root_account? &&
@account.feature_allowed?(:submission_comment_emojis) &&
@account.grants_right?(@current_user, :manage_account_settings) %>
<% end %>
<% if @account.primary_settings_root_account? and not (exposed_services = Account.services_exposed_to_ui_hash(:service, @current_user)).empty? %>
<%= t('Enabled Web Services') %>
<%= t('Enabled Web Services') %>
<%= f.fields_for :services do |services| %>
<% exposed_services.sort_by { |k,h| Canvas::ICU.collation_key(h[:name]) }.each do |key, service| %>
<%= services.check_box key, :checked => @account.service_enabled?(key) %>
<%= services.label key, service[:name] + " " %>
<% end %>
<% end %>
" id="google_docs_previews_help_dialog">
<%= mt(:about_google_docs, <<~TEXT, :terms_url => "https://docs.google.com/viewer/TOS")
Google Docs Previews allow users to view documents from
within Canvas, rather than having to download them and
open the corresponding program (e.g. Word or Excel).
Google Docs Previews can also render file types
not supported by the Canvas document previewer.
By using this service you
acknowledge that you have read and agreed to the
[Google Docs Viewer Terms of Service](%{terms_url}).
TEXT
%>
<% end %>
<% if @account.root_account.feature_enabled?(:course_templates) %>
<%= t('Course Template') %>
<%= t('Course Template') %>
<%
disabled = []
options = []
if @account.root_account?
options << [t("No Template Selected"), nil]
disabled << nil unless @account.course_template_id.nil? || @account.grants_any_right?(@current_user, :delete_course_template, :edit_course_template)
else
options << [t("Inherit (%{course_name})", course_name: @account.parent_account.effective_course_template&.name || t("No Template Selected")), nil ]
options << [t("No Template Selected"), 0]
disabled.concat([0, nil]) unless @account.course_template_id == 0 || @account.grants_any_right?(@current_user, :delete_course_template, :edit_course_template)
end
visible_templates = @account.root_account.all_courses.templates
.order(Course.best_unicode_collation_key('courses.name'))
.pluck(:name, :id)
if @account.course_template_id && [email protected] _template_id.zero? && !visible_templates.find { |_, id| @account.course_template_id == id }
visible_templates.unshift([@account.course_template.name, @account.course_template_id])
end
options.concat(visible_templates)
unless @account.grants_right?(@current_user, :edit_course_template)
nonselected = visible_templates.map(&:last)
nonselected.delete(@account.course_template_id)
disabled.concat(nonselected)
end
%>
<%= f.select :course_template_id, options, disabled: disabled %>
<%= f.label :course_template_id, en: 'The selected course template will be used for all new courses' %>
<% end %>
<% if @account.primary_settings_root_account? &&
[email protected] _admin? %>
<%= t('Who Can Create New Courses') %>
<%= t(:create_courses_title, "Who Can Create New Courses") %>
<% if @account.feature_enabled?(:create_course_subaccount_picker) %>
<% else %>
<%= t(:create_courses_description, "(Account Administrators can always create courses)") %>
<%= f.fields_for :settings do |settings| %>
<%= settings.check_box :teachers_can_create_courses, :checked => @account.teachers_can_create_courses? %>
<%= settings.label :teachers_can_create_courses, :en => "Teachers" %>
<%= settings.check_box :students_can_create_courses, :checked => @account.students_can_create_courses? %>
<%= settings.label :students_can_create_courses, :en => "Students" %>
<%= settings.check_box :no_enrollments_can_create_courses, :checked => @account.no_enrollments_can_create_courses? %>
<%= settings.label :no_enrollments_can_create_courses, :en => "Users with no enrollments" %>
<% end %>
<% end %>
<% end %>
<%= render partial: 'external_integration_keys', locals: { f: f } %>
<% if @account.root_account &&
@account.root_account.feature_enabled?(:smart_alerts) &&
can_do(@account, @current_user, :manage_alerts)
%>
<%= t('Smart Assignment Alerts') %>
<%= t('Smart Assignment Alerts') %>
<%= f.fields_for :settings do |settings| %>
<% end %>
<% end %>
<% end %>
<% end %>
<% if can_do(@context, @current_user, :manage_storage_quotas) %>
<% end %>
<% if can_do(@context, @current_user, :manage_account_settings) && @account.root_account? && @account.feature_enabled?(:microsoft_group_enrollments_syncing) %>
<% end %>
<% if can_do(@context, @current_user, :manage_account_settings) && @account.primary_settings_root_account? &&
<%= form_for :account, :url => account_url(@account), :html => {:method => :put, :id => "account_settings_notifications"} do |f| %>
<%= t(:email_notification_from_settings, 'E-mail Notification "From" Settings') %>
<%= t(:email_notification_from_description, "This setting allows the Admin to brand or label the 'From' text on all notifications sent from Canvas for this Account.") %>
<%= f.fields_for :settings do |settings| %>
<%= settings.radio_button :outgoing_email_default_name_option, 'default',
:checked => @account.settings[:outgoing_email_default_name].blank?,
:class => 'notification_from_name_option' %>
<%= settings.label :outgoing_email_default_name_option_default, :en => "Default Canvas Setting" %>
: 2em;'>
<%= t 'notifications.example', 'Example:' %>
<%= settings.radio_button :outgoing_email_default_name_option, 'custom',
:checked =>
[email protected] [:outgoing_email_default_name].blank?,
:class => 'notification_from_name_option' %>
<%= settings.label :outgoing_email_default_name_option_custom, :en => 'Custom "From" Name' %>
: 2em;'>
<%= t('notifications.custom_name_description', 'If selected, this will replace all other branding sent in Canvas notifications.') %>
<%= settings.label :outgoing_email_default_name, :en => 'Name:' %>
<%= text_field_tag 'account[settings][outgoing_email_default_name]', @account.settings[:outgoing_email_default_name] %>
: 2em;'>
<%= t 'notifications.example', 'Example:' %>
<%= t('notifications.external_services', 'Notifications Sent to External Services') %>
<% end %>
<%= t(:update_settings_button, "Update Settings") %>
<% end %>
<%= t(:global_announcements_title, "Global Announcements") %>
<% if can_do(@account, @current_user, :manage_alerts) %>
<%= t("New Announcement") %>
<%= form_for :account_notification,
url: account_account_notifications_url(@account),
html: {
id: "add_notification_form",
class: "hidden_form",
role: "region" } do |f| %>
<%= t("Title") %>
<%= f.text_field :subject, :class => 'ic-Input', :id => 'account_notification_subject' %>
<%= t("Announcement type") %>
<%= options_for_select([[t("information"), "information", {:class=>"information"}],
[t("error"), "error", {:class=>"error"}],
[t("warning"), "warning", {:class=>"warning"}],
[t("question"), "question", {:class=>"question"}],
[t("calendar"), "calendar", {:class=>"calendar"}]]) %>
<% if @account.root_account.trust_exists? %>
<% end %>
<% if @account.site_admin? %>
<% end %>
<%= t("Announcement starts at") %>
<%= datepicker_screenreader_prompt %>
<%= f.text_field :start_at,
:id => "account_notification_start_at",
:class => 'datetime_field',
"aria-labelledby" => "announcement_starts_at_label",
"data-tooltip" => "",
:title => accessible_date_format %>
<%= t("Announcement ends at") %>
<%= datepicker_screenreader_prompt %>
<%= f.text_field :end_at,
:id => "account_notification_end_at",
:class => 'datetime_field',
"aria-labelledby" => "announcement_ends_at_label",
"data-tooltip" => "",
:title => accessible_date_format %>
<% if
[email protected] _admin? %>
<%= f.check_box :send_message, :id => "account_notification_send_message" %>
<%= f.label :send_message, t("Send notification directly to users when announcement starts"), :class => "ic-Label" %>
<% end %>
<%= t('#buttons.cancel', %{Cancel}) %>
<%= t("Publish announcement") %>
<% end %>
<% end %>
<%= will_paginate(@announcements, params: {anchor: "tab-announcements"}) %>
<% @announcements.each do |announcement| %>
<%= accessible_message_icon_text(notification_icon_type(announcement)) %>
<%= announcement.subject %>
<%= user_content(announcement.message) %>
<% if can_do(@account, @current_user, :manage_alerts) %>
"
title="<%= t("Copy announcement %{title}", title: announcement.subject) %>"
class="Button Button--icon-action element_toggler copy_notification_toggle_focus"
data-copy-toggle-id="<%= announcement.id %>"
>
<%= t("Copy announcement %{title}", :title => announcement.subject) %>
"
title="<%= t("Edit announcement %{title}", title: announcement.subject) %>"
class="Button Button--icon-action element_toggler edit_notification_toggle_focus"
aria-controls="<%= "edit_notification_form_#{announcement.id}" %>"
data-edit-toggle-id="<%= announcement.id %>"
>
<%= t("Edit announcement %{title}", :title => announcement.subject) %>
"
>
<%= t("Delete announcement %{title}", :title => announcement.subject) %>
<% end %>
<% if @account.site_admin? %>
<%= t("This is a message from *Canvas Administration*", wrapper: '\1 ') %>
<% else %>
<%= t("This is a message from *%{name}*", name: announcement.account.name, wrapper: '\1 ') %>
<% end %>
<%= t(:alert_timespan, "from %{start_at} to %{end_at}",
:start_at => datetime_string(announcement.start_at),
:end_at => datetime_string(announcement.end_at)) %>
<%= link_to(context_user_name(@account, announcement.user_id), user_path(announcement.user_id)) %>
<% if announcement.required_account_service %>
<%= AccountServices.allowable_services[announcement.required_account_service.to_sym].try(:[], :name) %>
<% end %>
<% unless announcement.account_notification_roles.empty? %>
<%= t "Send only to the following types of users:" %>
<%= roles_message(@account) %>
<% announcement.account_notification_roles.each do |r| %>
<% @course_roles.select {|rt| rt[:id] == r.role_id }.each do |rt| %>
<%= rt[:label] %>
<% end %>
<% # NilEnrollment is a special case %>
<% if r.role_id.nil? %>
<%= t :no_enrollment_roles, "Unenrolled users" %>
<% end %>
<% @account_roles.select {|rt| rt[:id] == r.role_id }.each do |rt| %>
<%= rt[:label] %>
<% end %>
<% end %>
<% end %>
<% if announcement.months_in_display_cycle %>
<%= t :announcement_sent_to_subset, "Sent to 1 / %{denominator} users each month", denominator: announcement.months_in_display_cycle %>
<% end %>
<% if can_do(@account, @current_user, :manage_alerts) %>
<%= render(:partial => "edit_account_notification", :locals => {:announcement => announcement}) %>
<% end %>
<% end %>
<%= render :partial => 'external_tools/external_tools', :object => @context.context_external_tools.active %>
<% end %>
<% if @context.root_account.settings[:enable_alerts] && can_do(@context, @current_user, :manage_interaction_alerts) %>
<% end %>
<% if can_do(@context, @current_user, :view_feature_flags) %>
<% end %>
<% if @account.root_account.feature_enabled?(:javascript_csp) && can_do(@context, @current_user, :manage_account_settings) &&
<% end %>
<% if @account.site_admin? && can_do(@context, @current_user, :manage_internal_settings) %>