diff --git a/Oqtane.Client/Modules/Controls/AuditInfo.razor b/Oqtane.Client/Modules/Controls/AuditInfo.razor index 3022c49f..026a2986 100644 --- a/Oqtane.Client/Modules/Controls/AuditInfo.razor +++ b/Oqtane.Client/Modules/Controls/AuditInfo.razor @@ -1,4 +1,4 @@ -@namespace Oqtane.Modules.Controls +@namespace Oqtane.Modules.Controls @inherits ModuleControlBase @if (_text != string.Empty) @@ -14,13 +14,13 @@ public string CreatedBy { get; set; } [Parameter] - public DateTime CreatedOn { get; set; } + public DateTime? CreatedOn { get; set; } [Parameter] public string ModifiedBy { get; set; } [Parameter] - public DateTime ModifiedOn { get; set; } + public DateTime? ModifiedOn { get; set; } [Parameter] public string DeletedBy { get; set; } @@ -37,7 +37,7 @@ protected override void OnParametersSet() { _text = string.Empty; - if (!String.IsNullOrEmpty(CreatedBy) || CreatedOn != null) + if (!String.IsNullOrEmpty(CreatedBy) || CreatedOn.HasValue) { _text += "

Created "; @@ -48,13 +48,13 @@ if (CreatedOn != null) { - _text += " on " + CreatedOn.ToString("MMM dd yyyy HH:mm:ss") + ""; + _text += " on " + CreatedOn.Value.ToString("MMM dd yyyy HH:mm:ss") + ""; } _text += "

"; } - if (!String.IsNullOrEmpty(ModifiedBy) || ModifiedOn != null) + if (!String.IsNullOrEmpty(ModifiedBy) || ModifiedOn.HasValue) { _text += "

Last modified "; @@ -65,7 +65,7 @@ if (ModifiedOn != null) { - _text += " on " + ModifiedOn.ToString("MMM dd yyyy HH:mm:ss") + ""; + _text += " on " + ModifiedOn.Value.ToString("MMM dd yyyy HH:mm:ss") + ""; } _text += "

"; diff --git a/Oqtane.Client/Modules/Controls/ModuleMessage.razor b/Oqtane.Client/Modules/Controls/ModuleMessage.razor index 680f45c0..ee846b13 100644 --- a/Oqtane.Client/Modules/Controls/ModuleMessage.razor +++ b/Oqtane.Client/Modules/Controls/ModuleMessage.razor @@ -1,4 +1,4 @@ -@namespace Oqtane.Modules.Controls +@namespace Oqtane.Modules.Controls @inherits ModuleControlBase @inject NavigationManager NavigationManager @@ -6,7 +6,7 @@ {