mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Email notification settings get properly persisted and displayed
This commit is contained in:
@@ -18,19 +18,20 @@
|
||||
|
||||
<div>
|
||||
<label for="CommentSettings_ClosedCommentsDelay">@T("Automatically close comments after")</label>
|
||||
@Html.TextBoxFor(m => m.ClosedCommentsDelay, new { @class = "text small"}) @T("days")
|
||||
@Html.TextBoxFor(m => m.ClosedCommentsDelay, new { @class = "text small" }) @T("days")
|
||||
@Html.ValidationMessage("ClosedCommentsDelay", "*")
|
||||
<span class="hint">@T("Number of days after comments are automatically closed. Leave to 0 to have them always available.")</span>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<input type="checkbox" value="true" class="check-box" id="@Html.FieldIdFor(m => m.NotificationEmail)" name="@Html.FieldNameFor(m => m.NotificationEmail)" @(emailEnabled ? "" : "disabled=\"disabled\"") />
|
||||
@if (emailEnabled) {
|
||||
@Html.EditorFor(m => m.NotificationEmail, new { disabled = emailEnabled ? "" : "disabled" })
|
||||
<label class="forcheckbox" for="CommentSettings_NotificationEmail">@T("Notification email")</label>
|
||||
@Html.ValidationMessage("NotificationEmail", "*")
|
||||
<span class="hint">@T("Check to send comment notification emails to the commented content author at their account’s email address.")</span>
|
||||
|
||||
@if (!emailEnabled) {
|
||||
<div class="message message-Warning">@T("This option is available when an email module is activated.")</div>
|
||||
}
|
||||
else {
|
||||
<div class="message message-Warning">@T("The option to send comment notifications is available when an email module is activated.")</div>
|
||||
}
|
||||
</div>
|
||||
|
||||
|
Reference in New Issue
Block a user