From 3abe47ae9e6c54aad405ed280566e7881b53e034 Mon Sep 17 00:00:00 2001 From: vnetonline Date: Tue, 20 Jun 2023 16:52:50 +1000 Subject: [PATCH] [ENHANCE] - Added Module to NameSpace [Owner].Module.[Module] [ENHANCE] - Added Module to NameSpace [Owner].Module.[Module] --- .../Modules/Admin/ModuleCreator/Index.razor | 2 +- .../Controllers/ModuleDefinitionController.cs | 10 +++++----- Oqtane.Server/Oqtane.Server.csproj | 15 ++------------- .../Templates/External/Client/AssemblyInfo.cs | 4 ++-- .../Modules/Templates/External/Client/Interop.cs | 4 ++-- .../Edit.razor | 6 +++--- .../Index.razor | 6 +++--- .../ModuleInfo.cs | 6 +++--- .../Settings.razor | 2 +- .../Edit.resx | 0 .../Index.resx | 0 .../Settings.resx | 0 .../External/Client/Services/I[Module]Service.cs | 4 ++-- .../External/Client/Services/[Module]Service.cs | 4 ++-- ...roj => [Owner].Module.[Module].Client.csproj} | 6 +++--- ...oj => [Owner].Module.[Module].Package.csproj} | 8 ++++---- ...le].nuspec => [Owner].Module.[Module].nuspec} | 16 ++++++++-------- .../Modules/Templates/External/Package/debug.cmd | 12 ++++++------ .../Templates/External/Package/release.cmd | 2 +- .../Server/Controllers/[Module]Controller.cs | 4 ++-- .../External/Server/Manager/[Module]Manager.cs | 8 ++++---- .../Migrations/01000000_InitializeModule.cs | 8 ++++---- .../EntityBuilders/[Module]EntityBuilder.cs | 2 +- .../Server/Repository/I[Module]Repository.cs | 4 ++-- .../Server/Repository/[Module]Context.cs | 2 +- .../Server/Repository/[Module]Repository.cs | 4 ++-- ...roj => [Owner].Module.[Module].Server.csproj} | 6 +++--- .../Module.css | 0 .../Module.js | 2 +- .../Templates/External/Shared/Models/[Module].cs | 2 +- ...roj => [Owner].Module.[Module].Shared.csproj} | 4 ++-- ....[Module].sln => [Owner].Module.[Module].sln} | 10 +++++----- 32 files changed, 76 insertions(+), 87 deletions(-) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/{[Owner].[Module] => [Owner].Module.[Module]}/Edit.razor (97%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/{[Owner].[Module] => [Owner].Module.[Module]}/Index.razor (95%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/{[Owner].[Module] => [Owner].Module.[Module]}/ModuleInfo.cs (71%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/{[Owner].[Module] => [Owner].Module.[Module]}/Settings.razor (97%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/{[Owner].[Module] => [Owner].Module.[Module]}/Edit.resx (100%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/{[Owner].[Module] => [Owner].Module.[Module]}/Index.resx (100%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/{[Owner].[Module] => [Owner].Module.[Module]}/Settings.resx (100%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Client/{[Owner].[Module].Client.csproj => [Owner].Module.[Module].Client.csproj} (86%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Package/{[Owner].[Module].Package.csproj => [Owner].Module.[Module].Package.csproj} (65%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Package/{[Owner].[Module].nuspec => [Owner].Module.[Module].nuspec} (53%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Server/{[Owner].[Module].Server.csproj => [Owner].Module.[Module].Server.csproj} (84%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/{[Owner].[Module] => [Owner].Module.[Module]}/Module.css (100%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/{[Owner].[Module] => [Owner].Module.[Module]}/Module.js (65%) rename Oqtane.Server/wwwroot/Modules/Templates/External/Shared/{[Owner].[Module].Shared.csproj => [Owner].Module.[Module].Shared.csproj} (80%) rename Oqtane.Server/wwwroot/Modules/Templates/External/{[Owner].[Module].sln => [Owner].Module.[Module].sln} (77%) diff --git a/Oqtane.Client/Modules/Admin/ModuleCreator/Index.razor b/Oqtane.Client/Modules/Admin/ModuleCreator/Index.razor index bd5689f6..6785292a 100644 --- a/Oqtane.Client/Modules/Admin/ModuleCreator/Index.razor +++ b/Oqtane.Client/Modules/Admin/ModuleCreator/Index.razor @@ -195,7 +195,7 @@ else if (_owner != "" && _module != "" && _template != "-") { var template = _templates.FirstOrDefault(item => item.Name == _template); - _location = template.Location + _owner + "." + _module; + _location = template.Location + _owner + ".Module." + _module; } StateHasChanged(); diff --git a/Oqtane.Server/Controllers/ModuleDefinitionController.cs b/Oqtane.Server/Controllers/ModuleDefinitionController.cs index b672c72f..c8114821 100644 --- a/Oqtane.Server/Controllers/ModuleDefinitionController.cs +++ b/Oqtane.Server/Controllers/ModuleDefinitionController.cs @@ -123,14 +123,14 @@ namespace Oqtane.Controllers if (moduleDefinition.Template.ToLower().Contains("internal")) { rootPath = Utilities.PathCombine(rootFolder.FullName, Path.DirectorySeparatorChar.ToString()); - moduleDefinition.ModuleDefinitionName = moduleDefinition.Owner + "." + moduleDefinition.Name + ", Oqtane.Client"; - moduleDefinition.ServerManagerType = moduleDefinition.Owner + "." + moduleDefinition.Name + ".Manager." + moduleDefinition.Name + "Manager, Oqtane.Server"; + moduleDefinition.ModuleDefinitionName = moduleDefinition.Owner + ".Module." + moduleDefinition.Name + ", Oqtane.Client"; + moduleDefinition.ServerManagerType = moduleDefinition.Owner + ".Module." + moduleDefinition.Name + ".Manager." + moduleDefinition.Name + "Manager, Oqtane.Server"; } else { - rootPath = Utilities.PathCombine(rootFolder.Parent.FullName, moduleDefinition.Owner + "." + moduleDefinition.Name, Path.DirectorySeparatorChar.ToString()); - moduleDefinition.ModuleDefinitionName = moduleDefinition.Owner + "." + moduleDefinition.Name + ", " + moduleDefinition.Owner + "." + moduleDefinition.Name + ".Client.Oqtane"; - moduleDefinition.ServerManagerType = moduleDefinition.Owner + "." + moduleDefinition.Name + ".Manager." + moduleDefinition.Name + "Manager, " + moduleDefinition.Owner + "." + moduleDefinition.Name + ".Server.Oqtane"; + rootPath = Utilities.PathCombine(rootFolder.Parent.FullName, moduleDefinition.Owner + ".Module." + moduleDefinition.Name, Path.DirectorySeparatorChar.ToString()); + moduleDefinition.ModuleDefinitionName = moduleDefinition.Owner + ".Module." + moduleDefinition.Name + ", " + moduleDefinition.Owner + ".Module." + moduleDefinition.Name + ".Client.Oqtane"; + moduleDefinition.ServerManagerType = moduleDefinition.Owner + ".Module." + moduleDefinition.Name + ".Manager." + moduleDefinition.Name + "Manager, " + moduleDefinition.Owner + ".Module." + moduleDefinition.Name + ".Server.Oqtane"; } ProcessTemplatesRecursively(new DirectoryInfo(templatePath), rootPath, rootFolder.Name, templatePath, moduleDefinition); diff --git a/Oqtane.Server/Oqtane.Server.csproj b/Oqtane.Server/Oqtane.Server.csproj index 737c5160..780e0400 100644 --- a/Oqtane.Server/Oqtane.Server.csproj +++ b/Oqtane.Server/Oqtane.Server.csproj @@ -21,10 +21,10 @@ - - + + @@ -63,15 +63,4 @@ - - - - - - - - - - - diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/AssemblyInfo.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/AssemblyInfo.cs index 247d7bc8..4def57e3 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/AssemblyInfo.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/AssemblyInfo.cs @@ -1,4 +1,4 @@ -using System.Resources; +using System.Resources; using Microsoft.Extensions.Localization; -[assembly: RootNamespace("[Owner].[Module].Client")] \ No newline at end of file +[assembly: RootNamespace("[Owner].Module.[Module].Client")] diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Interop.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Interop.cs index 9d6f0a4e..bcb7d729 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Interop.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Interop.cs @@ -1,7 +1,7 @@ -using Microsoft.JSInterop; +using Microsoft.JSInterop; using System.Threading.Tasks; -namespace [Owner].[Module] +namespace [Owner].Module.[Module] { public class Interop { diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Edit.razor b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Edit.razor similarity index 97% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Edit.razor rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Edit.razor index 20cf950a..23ca8f4f 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Edit.razor +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Edit.razor @@ -1,8 +1,8 @@ @using Oqtane.Modules.Controls -@using [Owner].[Module].Services -@using [Owner].[Module].Models +@using [Owner].Module.[Module].Services +@using [Owner].Module.[Module].Models -@namespace [Owner].[Module] +@namespace [Owner].Module.[Module] @inherits ModuleBase @inject I[Module]Service [Module]Service @inject NavigationManager NavigationManager diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Index.razor b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Index.razor similarity index 95% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Index.razor rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Index.razor index df7b157a..91eef0a1 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Index.razor +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Index.razor @@ -1,7 +1,7 @@ -@using [Owner].[Module].Services -@using [Owner].[Module].Models +@using [Owner].Module.[Module].Services +@using [Owner].Module.[Module].Models -@namespace [Owner].[Module] +@namespace [Owner].Module.[Module] @inherits ModuleBase @inject I[Module]Service [Module]Service @inject NavigationManager NavigationManager diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/ModuleInfo.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/ModuleInfo.cs similarity index 71% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/ModuleInfo.cs rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/ModuleInfo.cs index 0585c65c..8ba827d6 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/ModuleInfo.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/ModuleInfo.cs @@ -1,7 +1,7 @@ using Oqtane.Models; using Oqtane.Modules; -namespace [Owner].[Module] +namespace [Owner].Module.[Module] { public class ModuleInfo : IModule { @@ -12,8 +12,8 @@ namespace [Owner].[Module] Version = "1.0.0", ServerManagerType = "[ServerManagerType]", ReleaseVersions = "1.0.0", - Dependencies = "[Owner].[Module].Shared.Oqtane", - PackageName = "[Owner].[Module]" + Dependencies = "[Owner].Module.[Module].Shared.Oqtane", + PackageName = "[Owner].Module.[Module]" }; } } diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Settings.razor b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Settings.razor similarity index 97% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Settings.razor rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Settings.razor index 51ff22e6..d8f9bfaf 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].[Module]/Settings.razor +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Modules/[Owner].Module.[Module]/Settings.razor @@ -1,4 +1,4 @@ -@namespace [Owner].[Module] +@namespace [Owner].Module.[Module] @inherits ModuleBase @inject ISettingService SettingService @inject IStringLocalizer Localizer diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].[Module]/Edit.resx b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].Module.[Module]/Edit.resx similarity index 100% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].[Module]/Edit.resx rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].Module.[Module]/Edit.resx diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].[Module]/Index.resx b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].Module.[Module]/Index.resx similarity index 100% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].[Module]/Index.resx rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].Module.[Module]/Index.resx diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].[Module]/Settings.resx b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].Module.[Module]/Settings.resx similarity index 100% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].[Module]/Settings.resx rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/Resources/[Owner].Module.[Module]/Settings.resx diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/I[Module]Service.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/I[Module]Service.cs index 601eba6a..30ea62c9 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/I[Module]Service.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/I[Module]Service.cs @@ -1,8 +1,8 @@ using System.Collections.Generic; using System.Threading.Tasks; -using [Owner].[Module].Models; +using [Owner].Module.[Module].Models; -namespace [Owner].[Module].Services +namespace [Owner].Module.[Module].Services { public interface I[Module]Service { diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/[Module]Service.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/[Module]Service.cs index cd154052..b6503356 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/[Module]Service.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/Services/[Module]Service.cs @@ -5,9 +5,9 @@ using System.Threading.Tasks; using Oqtane.Modules; using Oqtane.Services; using Oqtane.Shared; -using [Owner].[Module].Models; +using [Owner].Module.[Module].Models; -namespace [Owner].[Module].Services +namespace [Owner].Module.[Module].Services { public class [Module]Service : ServiceBase, I[Module]Service, IService { diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/[Owner].[Module].Client.csproj b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/[Owner].Module.[Module].Client.csproj similarity index 86% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Client/[Owner].[Module].Client.csproj rename to Oqtane.Server/wwwroot/Modules/Templates/External/Client/[Owner].Module.[Module].Client.csproj index 423c3e27..98abe0e7 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Client/[Owner].[Module].Client.csproj +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Client/[Owner].Module.[Module].Client.csproj @@ -7,9 +7,9 @@ [Owner] [Owner] [Description] - [Owner].[Module] + [Owner].Module.[Module] [Owner] - [Owner].[Module].Client.Oqtane + [Owner].Module.[Module].Client.Oqtane @@ -22,7 +22,7 @@ - + diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].[Module].Package.csproj b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].Module.[Module].Package.csproj similarity index 65% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].[Module].Package.csproj rename to Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].Module.[Module].Package.csproj index 50fa0fbf..fa3cfe16 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].[Module].Package.csproj +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].Module.[Module].Package.csproj @@ -1,4 +1,4 @@ - + net7.0 @@ -13,9 +13,9 @@ - - - + + + diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].[Module].nuspec b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].Module.[Module].nuspec similarity index 53% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].[Module].nuspec rename to Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].Module.[Module].nuspec index 70658e74..f148f2d3 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].[Module].nuspec +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/[Owner].Module.[Module].nuspec @@ -1,7 +1,7 @@ - + - [Owner].[Module] + [Owner].Module.[Module] 1.0.0 [Owner] [Owner] @@ -20,12 +20,12 @@ - - - - - - + + + + + + diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/debug.cmd b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/debug.cmd index 4f0cf6d4..6f8b554a 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/debug.cmd +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/debug.cmd @@ -1,7 +1,7 @@ -XCOPY "..\Client\bin\Debug\net7.0\[Owner].[Module].Client.Oqtane.dll" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y -XCOPY "..\Client\bin\Debug\net7.0\[Owner].[Module].Client.Oqtane.pdb" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y -XCOPY "..\Server\bin\Debug\net7.0\[Owner].[Module].Server.Oqtane.dll" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y -XCOPY "..\Server\bin\Debug\net7.0\[Owner].[Module].Server.Oqtane.pdb" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y -XCOPY "..\Shared\bin\Debug\net7.0\[Owner].[Module].Shared.Oqtane.dll" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y -XCOPY "..\Shared\bin\Debug\net7.0\[Owner].[Module].Shared.Oqtane.pdb" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y +XCOPY "..\Client\bin\Debug\net7.0\[Owner].Module.[Module].Client.Oqtane.dll" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y +XCOPY "..\Client\bin\Debug\net7.0\[Owner].Module.[Module].Client.Oqtane.pdb" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y +XCOPY "..\Server\bin\Debug\net7.0\[Owner].Module.[Module].Server.Oqtane.dll" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y +XCOPY "..\Server\bin\Debug\net7.0\[Owner].Module.[Module].Server.Oqtane.pdb" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y +XCOPY "..\Shared\bin\Debug\net7.0\[Owner].Module.[Module].Shared.Oqtane.dll" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y +XCOPY "..\Shared\bin\Debug\net7.0\[Owner].Module.[Module].Shared.Oqtane.pdb" "..\..\[RootFolder]\Oqtane.Server\bin\Debug\net7.0\" /Y XCOPY "..\Server\wwwroot\*" "..\..\[RootFolder]\Oqtane.Server\wwwroot\" /Y /S /I diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/release.cmd b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/release.cmd index dd5c95db..14ce91dc 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Package/release.cmd +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Package/release.cmd @@ -1,3 +1,3 @@ -"..\..\[RootFolder]\oqtane.package\nuget.exe" pack [Owner].[Module].nuspec +"..\..\[RootFolder]\oqtane.package\nuget.exe" pack [Owner].Module.[Module].nuspec XCOPY "*.nupkg" "..\..\[RootFolder]\Oqtane.Server\Packages\" /Y diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Controllers/[Module]Controller.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Controllers/[Module]Controller.cs index f5bf1443..90384aff 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Controllers/[Module]Controller.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Controllers/[Module]Controller.cs @@ -5,11 +5,11 @@ using Microsoft.AspNetCore.Http; using Oqtane.Shared; using Oqtane.Enums; using Oqtane.Infrastructure; -using [Owner].[Module].Repository; +using [Owner].Module.[Module].Repository; using Oqtane.Controllers; using System.Net; -namespace [Owner].[Module].Controllers +namespace [Owner].Module.[Module].Controllers { [Route(ControllerRoutes.ApiRoute)] public class [Module]Controller : ModuleControllerBase diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Manager/[Module]Manager.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Manager/[Module]Manager.cs index 18e08faf..17553cc8 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Manager/[Module]Manager.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Manager/[Module]Manager.cs @@ -7,9 +7,9 @@ using Oqtane.Models; using Oqtane.Infrastructure; using Oqtane.Enums; using Oqtane.Repository; -using [Owner].[Module].Repository; +using [Owner].Module.[Module].Repository; -namespace [Owner].[Module].Manager +namespace [Owner].Module.[Module].Manager { public class [Module]Manager : MigratableModuleBase, IInstallable, IPortable { @@ -32,7 +32,7 @@ namespace [Owner].[Module].Manager return Migrate(new [Module]Context(_DBContextDependencies), tenant, MigrationType.Down); } - public string ExportModule(Module module) + public string ExportModule(Oqtane.Models.Module module) { string content = ""; List [Module]s = _[Module]Repository.Get[Module]s(module.ModuleId).ToList(); @@ -43,7 +43,7 @@ namespace [Owner].[Module].Manager return content; } - public void ImportModule(Module module, string content, string version) + public void ImportModule(Oqtane.Models.Module module, string content, string version) { List [Module]s = null; if (!string.IsNullOrEmpty(content)) diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/01000000_InitializeModule.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/01000000_InitializeModule.cs index 542d6087..d40eb50c 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/01000000_InitializeModule.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/01000000_InitializeModule.cs @@ -2,13 +2,13 @@ using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Migrations; using Oqtane.Databases.Interfaces; using Oqtane.Migrations; -using [Owner].[Module].Migrations.EntityBuilders; -using [Owner].[Module].Repository; +using [Owner].Module.[Module].Migrations.EntityBuilders; +using [Owner].Module.[Module].Repository; -namespace [Owner].[Module].Migrations +namespace [Owner].Module.[Module].Migrations { [DbContext(typeof([Module]Context))] - [Migration("[Owner].[Module].01.00.00.00")] + [Migration("[Owner].Module.[Module].01.00.00.00")] public class InitializeModule : MultiDatabaseMigration { public InitializeModule(IDatabase database) : base(database) diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/EntityBuilders/[Module]EntityBuilder.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/EntityBuilders/[Module]EntityBuilder.cs index c249b1d4..32ec9adb 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/EntityBuilders/[Module]EntityBuilder.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Migrations/EntityBuilders/[Module]EntityBuilder.cs @@ -5,7 +5,7 @@ using Oqtane.Databases.Interfaces; using Oqtane.Migrations; using Oqtane.Migrations.EntityBuilders; -namespace [Owner].[Module].Migrations.EntityBuilders +namespace [Owner].Module.[Module].Migrations.EntityBuilders { public class [Module]EntityBuilder : AuditableBaseEntityBuilder<[Module]EntityBuilder> { diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/I[Module]Repository.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/I[Module]Repository.cs index da2db55f..959cac4a 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/I[Module]Repository.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/I[Module]Repository.cs @@ -1,7 +1,7 @@ using System.Collections.Generic; -using [Owner].[Module].Models; +using [Owner].Module.[Module].Models; -namespace [Owner].[Module].Repository +namespace [Owner].Module.[Module].Repository { public interface I[Module]Repository { diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Context.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Context.cs index e5541f80..a921ca0f 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Context.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Context.cs @@ -5,7 +5,7 @@ using Oqtane.Repository; using Oqtane.Infrastructure; using Oqtane.Repository.Databases.Interfaces; -namespace [Owner].[Module].Repository +namespace [Owner].Module.[Module].Repository { public class [Module]Context : DBContextBase, ITransientService, IMultiDatabase { diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Repository.cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Repository.cs index 899dca19..522c26f8 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Repository.cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/Repository/[Module]Repository.cs @@ -2,9 +2,9 @@ using Microsoft.EntityFrameworkCore; using System.Linq; using System.Collections.Generic; using Oqtane.Modules; -using [Owner].[Module].Models; +using [Owner].Module.[Module].Models; -namespace [Owner].[Module].Repository +namespace [Owner].Module.[Module].Repository { public class [Module]Repository : I[Module]Repository, ITransientService { diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/[Owner].[Module].Server.csproj b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/[Owner].Module.[Module].Server.csproj similarity index 84% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Server/[Owner].[Module].Server.csproj rename to Oqtane.Server/wwwroot/Modules/Templates/External/Server/[Owner].Module.[Module].Server.csproj index db68d2ef..d77b6676 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/[Owner].[Module].Server.csproj +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/[Owner].Module.[Module].Server.csproj @@ -4,12 +4,12 @@ net7.0 true 1.0.0 - [Owner].[Module] + [Owner].Module.[Module] [Owner] [Owner] [Description] [Owner] - [Owner].[Module].Server.Oqtane + [Owner].Module.[Module].Server.Oqtane true @@ -26,7 +26,7 @@ - + diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].[Module]/Module.css b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].Module.[Module]/Module.css similarity index 100% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].[Module]/Module.css rename to Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].Module.[Module]/Module.css diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].[Module]/Module.js b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].Module.[Module]/Module.js similarity index 65% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].[Module]/Module.js rename to Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].Module.[Module]/Module.js index 8f072470..11d3ded6 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].[Module]/Module.js +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Server/wwwroot/Modules/[Owner].Module.[Module]/Module.js @@ -1,5 +1,5 @@ /* Module Script */ var [Owner] = [Owner] || {}; -[Owner].[Module] = { +[Owner].Module.[Module] = { }; \ No newline at end of file diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/Models/[Module].cs b/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/Models/[Module].cs index 45b0f2f2..ddba10ad 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/Models/[Module].cs +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/Models/[Module].cs @@ -3,7 +3,7 @@ using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using Oqtane.Models; -namespace [Owner].[Module].Models +namespace [Owner].Module.[Module].Models { [Table("[Owner][Module]")] public class [Module] : IAuditable diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/[Owner].[Module].Shared.csproj b/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/[Owner].Module.[Module].Shared.csproj similarity index 80% rename from Oqtane.Server/wwwroot/Modules/Templates/External/Shared/[Owner].[Module].Shared.csproj rename to Oqtane.Server/wwwroot/Modules/Templates/External/Shared/[Owner].Module.[Module].Shared.csproj index c638241d..e59810e0 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/[Owner].[Module].Shared.csproj +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/Shared/[Owner].Module.[Module].Shared.csproj @@ -3,12 +3,12 @@ net7.0 1.0.0 - [Owner].[Module] + [Owner].Module.[Module] [Owner] [Owner] [Description] [Owner] - [Owner].[Module].Shared.Oqtane + [Owner].Module.[Module].Shared.Oqtane diff --git a/Oqtane.Server/wwwroot/Modules/Templates/External/[Owner].[Module].sln b/Oqtane.Server/wwwroot/Modules/Templates/External/[Owner].Module.[Module].sln similarity index 77% rename from Oqtane.Server/wwwroot/Modules/Templates/External/[Owner].[Module].sln rename to Oqtane.Server/wwwroot/Modules/Templates/External/[Owner].Module.[Module].sln index 39259437..a9cbde70 100644 --- a/Oqtane.Server/wwwroot/Modules/Templates/External/[Owner].[Module].sln +++ b/Oqtane.Server/wwwroot/Modules/Templates/External/[Owner].Module.[Module].sln @@ -1,17 +1,17 @@ - + Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio Version 16 VisualStudioVersion = 16.0.28621.142 MinimumVisualStudioVersion = 10.0.40219.1 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Oqtane.Server", "..\[RootFolder]\Oqtane.Server\Oqtane.Server.csproj", "{3AB6FCC9-EFEB-4C0E-A2CF-8103914C5196}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].[Module].Client", "Client\[Owner].[Module].Client.csproj", "{AA8E58A1-CD09-4208-BF66-A8BB341FD669}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].Module.[Module].Client", "Client\[Owner].Module.[Module].Client.csproj", "{AA8E58A1-CD09-4208-BF66-A8BB341FD669}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].[Module].Server", "Server\[Owner].[Module].Server.csproj", "{04B05448-788F-433D-92C0-FED35122D45A}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].Module.[Module].Server", "Server\[Owner].Module.[Module].Server.csproj", "{04B05448-788F-433D-92C0-FED35122D45A}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].[Module].Shared", "Shared\[Owner].[Module].Shared.csproj", "{18D73F73-D7BE-4388-85BA-FBD9AC96FCA2}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].Module.[Module].Shared", "Shared\[Owner].Module.[Module].Shared.csproj", "{18D73F73-D7BE-4388-85BA-FBD9AC96FCA2}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].[Module].Package", "Package\[Owner].[Module].Package.csproj", "{C5CE512D-CBB7-4545-AF0F-9B6591A0C3A7}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "[Owner].Module.[Module].Package", "Package\[Owner].Module.[Module].Package.csproj", "{C5CE512D-CBB7-4545-AF0F-9B6591A0C3A7}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution