Added more constructors for convenience in creating Notification objects. Refactored to use the new constructors where applicable. Fixed localization key issue in Site Settings and added scroll to top when testing SMTP.
This commit is contained in:
@ -605,8 +605,10 @@
|
||||
await SettingService.UpdateSiteSettingsAsync(settings, PageState.Site.SiteId);
|
||||
await logger.LogInformation("Site SMTP Settings Saved");
|
||||
|
||||
await NotificationService.AddNotificationAsync(new Notification(PageState.Site.SiteId, PageState.User.DisplayName, PageState.User.Email, PageState.User.DisplayName, PageState.User.Email, PageState.Site.Name + " SMTP Configuration Test", "SMTP Server Is Configured Correctly."));
|
||||
await NotificationService.AddNotificationAsync(new Notification(PageState.Site.SiteId, PageState.User, PageState.Site.Name + " SMTP Configuration Test", "SMTP Server Is Configured Correctly."));
|
||||
AddModuleMessage(Localizer["Info.Smtp.SaveSettings"], MessageType.Info);
|
||||
var interop = new Interop(JSRuntime);
|
||||
await interop.ScrollTo(0, 0, "smooth");
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
@ -616,7 +618,7 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
AddModuleMessage(Localizer["Message.required.Smtp"], MessageType.Warning);
|
||||
AddModuleMessage(Localizer["Message.Required.Smtp"], MessageType.Warning);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user