-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
check AppConfig.mail.enable? before displaying some view content
closes #7190
- Loading branch information
1 parent
c7a0b05
commit 00ed1c9
Showing
6 changed files
with
82 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,33 @@ | ||
#paste_link | ||
= t('.paste_link') | ||
= t(".paste_link") | ||
%span#codes_left | ||
= "(" + t(".codes_left", count: @invite_code.count) + ")" unless AppConfig.settings.enable_registrations? | ||
.form-horizontal | ||
.control-group | ||
= invite_link(@invite_code) | ||
|
||
#email_invitation | ||
= form_tag new_user_invitation_path, class: 'form-horizontal' do | ||
- if AppConfig.mail.enable? | ||
#email_invitation | ||
= form_tag new_user_invitation_path, class: "form-horizontal" do | ||
|
||
.form-group | ||
%label.col-sm-2.control-label{ for: 'email_inviter_emails' } | ||
= t('email') | ||
.col-sm-10 | ||
= text_field_tag 'email_inviter[emails]', @invalid_emails, title: t('.comma_separated_plz'), | ||
placeholder: 'foo@bar.com, max@foo.com...', class: "form-control" | ||
#already_sent | ||
= t("invitations.create.note_already_sent", emails: @valid_emails) unless @valid_emails.empty? | ||
.form-group | ||
%label.col-sm-2.control-label{for: "email_inviter_emails"} | ||
= t("email") | ||
.col-sm-10 | ||
= text_field_tag "email_inviter[emails]", @invalid_emails, title: t(".comma_separated_plz"), | ||
placeholder: "foo@bar.com, max@foo.com...", class: "form-control" | ||
#already_sent | ||
= t("invitations.create.note_already_sent", emails: @valid_emails) unless @valid_emails.empty? | ||
|
||
.form-group | ||
%label.col-sm-2.control-label{ for: 'email_inviter_locale' } | ||
= t('.language') | ||
.col-sm-10 | ||
= select_tag 'email_inviter[locale]', options_from_collection_for_select(available_language_options, | ||
"second", "first", selected: current_user.language), class: "form-control" | ||
.form-group | ||
%label.col-sm-2.control-label{for: "email_inviter_locale"} | ||
= t(".language") | ||
.col-sm-10 | ||
= select_tag "email_inviter[locale]", options_from_collection_for_select(available_language_options, | ||
"second", "first", selected: current_user.language), class: "form-control" | ||
|
||
.form-group | ||
.pull-right.col-md-12 | ||
= submit_tag t('.send_an_invitation'), class: 'btn btn-primary pull-right', | ||
data: {disable_with: t('.sending_invitation')} | ||
.clearfix | ||
.form-group | ||
.pull-right.col-md-12 | ||
= submit_tag t(".send_an_invitation"), class: "btn btn-primary pull-right", | ||
data: {disable_with: t(".sending_invitation")} | ||
.clearfix |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters