diff --git a/Oqtane.Client/Modules/Admin/ModuleCreator/Templates/External/Client/[Owner].[Module]s.Module.Client.csproj b/Oqtane.Client/Modules/Admin/ModuleCreator/Templates/External/Client/[Owner].[Module]s.Module.Client.csproj index d23e3647..757eb45c 100644 --- a/Oqtane.Client/Modules/Admin/ModuleCreator/Templates/External/Client/[Owner].[Module]s.Module.Client.csproj +++ b/Oqtane.Client/Modules/Admin/ModuleCreator/Templates/External/Client/[Owner].[Module]s.Module.Client.csproj @@ -12,8 +12,8 @@ - - + + diff --git a/Oqtane.Client/Modules/Admin/Profiles/Edit.razor b/Oqtane.Client/Modules/Admin/Profiles/Edit.razor index d232a5ac..96a65b18 100644 --- a/Oqtane.Client/Modules/Admin/Profiles/Edit.razor +++ b/Oqtane.Client/Modules/Admin/Profiles/Edit.razor @@ -144,7 +144,7 @@ { profile = new Profile(); } - + profile.Name = _name; profile.Title = _title; profile.Description = _description; @@ -154,8 +154,14 @@ profile.DefaultValue = _defaultvalue; profile.IsRequired = (_isrequired == null ? false : Boolean.Parse(_isrequired)); profile.IsPrivate = (_isprivate == null ? false : Boolean.Parse(_isprivate)); - profile = await ProfileService.UpdateProfileAsync(profile); - + if (_profileid != -1) + { + profile = await ProfileService.UpdateProfileAsync(profile); + }else + { + profile = await ProfileService.AddProfileAsync(profile); + } + await logger.LogInformation("Profile Saved {Profile}", profile); NavigationManager.NavigateTo(NavigateUrl()); }