2019-12-04 20:38:33 +05:30
= form_for @application_setting, url: general_admin_application_settings_path(anchor: 'js-signup-settings'), html: { class: 'fieldset-form' } do |f|
2018-05-09 12:01:36 +05:30
= form_errors(@application_setting)
%fieldset
.form-group
2018-11-08 19:23:39 +05:30
.form-check
= f.check_box :signup_enabled, class: 'form-check-input'
= f.label :signup_enabled, class: 'form-check-label' do
Sign-up enabled
2018-05-09 12:01:36 +05:30
.form-group
2018-11-08 19:23:39 +05:30
.form-check
= f.check_box :send_user_confirmation_email, class: 'form-check-input'
= f.label :send_user_confirmation_email, class: 'form-check-label' do
Send confirmation email on sign-up
2018-05-09 12:01:36 +05:30
.form-group
2018-11-18 11:00:15 +05:30
= f.label :domain_whitelist, 'Whitelisted domains for sign-ups', class: 'label-bold'
2018-11-08 19:23:39 +05:30
= f.text_area :domain_whitelist_raw, placeholder: 'domain.com', class: 'form-control', rows: 8
.form-text.text-muted ONLY users with e-mail addresses that match these domain(s) will be able to sign-up. Wildcards allowed. Use separate lines for multiple entries. Ex: domain.com, *.domain.com
2018-05-09 12:01:36 +05:30
.form-group
2018-11-18 11:00:15 +05:30
= f.label :domain_blacklist_enabled, 'Domain Blacklist', class: 'label-bold'
2018-11-08 19:23:39 +05:30
.form-check
= f.check_box :domain_blacklist_enabled, class: 'form-check-input'
= f.label :domain_blacklist_enabled, class: 'form-check-label' do
Enable domain blacklist for sign ups
2018-05-09 12:01:36 +05:30
.form-group
2018-11-08 19:23:39 +05:30
.form-check
= radio_button_tag :blacklist_type, :file, false, class: 'form-check-input'
= label_tag :blacklist_type_file, class: 'form-check-label' do
.option-title
Upload blacklist file
.form-check
= radio_button_tag :blacklist_type, :raw, @application_setting.domain_blacklist.present? || @application_setting.domain_blacklist.blank?, class: 'form-check-input'
= label_tag :blacklist_type_raw, class: 'form-check-label' do
.option-title
Enter blacklist manually
2018-05-09 12:01:36 +05:30
.form-group.blacklist-file
2018-11-18 11:00:15 +05:30
= f.label :domain_blacklist_file, 'Blacklist file', class: 'label-bold'
2018-11-08 19:23:39 +05:30
= f.file_field :domain_blacklist_file, class: 'form-control', accept: '.txt,.conf'
.form-text.text-muted Users with e-mail addresses that match these domain(s) will NOT be able to sign-up. Wildcards allowed. Use separate lines or commas for multiple entries.
2018-05-09 12:01:36 +05:30
.form-group.blacklist-raw
2018-11-18 11:00:15 +05:30
= f.label :domain_blacklist, 'Blacklisted domains for sign-ups', class: 'label-bold'
2018-11-08 19:23:39 +05:30
= f.text_area :domain_blacklist_raw, placeholder: 'domain.com', class: 'form-control', rows: 8
.form-text.text-muted Users with e-mail addresses that match these domain(s) will NOT be able to sign-up. Wildcards allowed. Use separate lines for multiple entries. Ex: domain.com, *.domain.com
2018-05-09 12:01:36 +05:30
.form-group
2018-11-18 11:00:15 +05:30
= f.label :after_sign_up_text, class: 'label-bold'
2018-11-08 19:23:39 +05:30
= f.text_area :after_sign_up_text, class: 'form-control', rows: 4
.form-text.text-muted Markdown enabled
2018-05-09 12:01:36 +05:30
= f.submit 'Save changes', class: "btn btn-success"