Merge pull request #5315 from sbwalker/dev
fix initialization issue related to time zones
This commit is contained in:
commit
31aba14507
@ -8,6 +8,8 @@
|
||||
@inject IStringLocalizer<SharedResources> SharedLocalizer
|
||||
@inject ISettingService SettingService
|
||||
|
||||
@if (_initialized)
|
||||
{
|
||||
@if (PageState.Site.AllowRegistration)
|
||||
{
|
||||
if (!_userCreated)
|
||||
@ -88,8 +90,10 @@ else
|
||||
{
|
||||
<ModuleMessage Message="@Localizer["Info.Registration.Disabled"]" Type="MessageType.Info" />
|
||||
}
|
||||
}
|
||||
|
||||
@code {
|
||||
private bool _initialized = false;
|
||||
private List<Models.TimeZone> _timezones;
|
||||
private string _passwordrequirements;
|
||||
private string _username = string.Empty;
|
||||
@ -113,6 +117,7 @@ else
|
||||
_allowsitelogin = bool.Parse(SettingService.GetSetting(PageState.Site.Settings, "LoginOptions:AllowSiteLogin", "true"));
|
||||
_timezones = await TimeZoneService.GetTimeZonesAsync();
|
||||
_timezoneid = PageState.Site.TimeZoneId;
|
||||
_initialized = true;
|
||||
}
|
||||
|
||||
protected override void OnParametersSet()
|
||||
|
Loading…
x
Reference in New Issue
Block a user