From f47d0674d64ede187219bbf1f7ee777f32fbf360 Mon Sep 17 00:00:00 2001 From: Denis Prokhorchik Date: Tue, 26 Oct 2021 05:19:15 +0300 Subject: [PATCH 1/7] Services/c-gen/O2NextGen: create sln & empty project of netcore 2.1 --- src/Services/c-gen/O2NextGen.CGen.sln | 25 ++++++++++++++ ...O2NextGen.CertificateManagement.Web.csproj | 15 ++++++++ .../Program.cs | 24 +++++++++++++ .../Properties/launchSettings.json | 27 +++++++++++++++ .../Startup.cs | 34 +++++++++++++++++++ 5 files changed, 125 insertions(+) create mode 100644 src/Services/c-gen/O2NextGen.CGen.sln create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs diff --git a/src/Services/c-gen/O2NextGen.CGen.sln b/src/Services/c-gen/O2NextGen.CGen.sln new file mode 100644 index 00000000..3fcda6f5 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CGen.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.810.10 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "O2NextGen.CertificateManagement.Web", "O2NextGen.CertificateManagement.Web\O2NextGen.CertificateManagement.Web.csproj", "{EA540B06-8A73-49C7-A799-49423B316458}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {EA540B06-8A73-49C7-A799-49423B316458}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {EA540B06-8A73-49C7-A799-49423B316458}.Debug|Any CPU.Build.0 = Debug|Any CPU + {EA540B06-8A73-49C7-A799-49423B316458}.Release|Any CPU.ActiveCfg = Release|Any CPU + {EA540B06-8A73-49C7-A799-49423B316458}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {A6DFC9F0-3FA7-492B-ACE9-3EFBF3477712} + EndGlobalSection +EndGlobal diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj new file mode 100644 index 00000000..d62ba8be --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj @@ -0,0 +1,15 @@ + + + + netcoreapp2.1 + + + + + + + + + + + diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs new file mode 100644 index 00000000..e65d7ec5 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs @@ -0,0 +1,24 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore; +using Microsoft.AspNetCore.Hosting; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Logging; + +namespace O2NextGen.CertificateManagement.Web +{ + public class Program + { + public static void Main(string[] args) + { + CreateWebHostBuilder(args).Build().Run(); + } + + public static IWebHostBuilder CreateWebHostBuilder(string[] args) => + WebHost.CreateDefaultBuilder(args) + .UseStartup(); + } +} diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json new file mode 100644 index 00000000..54d71450 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json @@ -0,0 +1,27 @@ +{ + "iisSettings": { + "windowsAuthentication": false, + "anonymousAuthentication": true, + "iisExpress": { + "applicationUrl": "http://localhost:21259", + "sslPort": 44316 + } + }, + "profiles": { + "IIS Express": { + "commandName": "IISExpress", + "launchBrowser": true, + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + }, + "O2NextGen.CertificateManagement.Web": { + "commandName": "Project", + "launchBrowser": true, + "applicationUrl": "https://localhost:5001;http://localhost:5000", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + } + } +} diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs new file mode 100644 index 00000000..a9802c67 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs @@ -0,0 +1,34 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Builder; +using Microsoft.AspNetCore.Hosting; +using Microsoft.AspNetCore.Http; +using Microsoft.Extensions.DependencyInjection; + +namespace O2NextGen.CertificateManagement.Web +{ + public class Startup + { + // This method gets called by the runtime. Use this method to add services to the container. + // For more information on how to configure your application, visit https://go.microsoft.com/fwlink/?LinkID=398940 + public void ConfigureServices(IServiceCollection services) + { + } + + // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. + public void Configure(IApplicationBuilder app, IHostingEnvironment env) + { + if (env.IsDevelopment()) + { + app.UseDeveloperExceptionPage(); + } + + app.Run(async (context) => + { + await context.Response.WriteAsync("Hello World!"); + }); + } + } +} From 5c90e96dd825693d02f31c7a1ecbe664856ec52e Mon Sep 17 00:00:00 2001 From: Denis Prokhorchik Date: Tue, 26 Oct 2021 05:22:21 +0300 Subject: [PATCH 2/7] Services/c-gen/O2NextGen.CertificateManagement.Web/Startup: code cleanup --- .../c-gen/O2NextGen.CertificateManagement.Web/Startup.cs | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs index a9802c67..5b7dcb5f 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs @@ -11,13 +11,10 @@ namespace O2NextGen.CertificateManagement.Web { public class Startup { - // This method gets called by the runtime. Use this method to add services to the container. - // For more information on how to configure your application, visit https://go.microsoft.com/fwlink/?LinkID=398940 public void ConfigureServices(IServiceCollection services) { } - // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IHostingEnvironment env) { if (env.IsDevelopment()) From 0fb3f46512568fc1c4475e693de5cf09fdd36aa7 Mon Sep 17 00:00:00 2001 From: Denis Prokhorchik Date: Tue, 26 Oct 2021 06:50:17 +0300 Subject: [PATCH 3/7] Services/c-gen: implement simple mvc logic --- .../.idea.O2NextGen.CGen/.idea/.gitignore | 13 ++++ .../.idea/.idea.O2NextGen.CGen/.idea/.name | 1 + .../.idea.O2NextGen.CGen/.idea/encodings.xml | 4 ++ .../.idea/indexLayout.xml | 8 +++ .../.idea/.idea.O2NextGen.CGen/.idea/vcs.xml | 6 ++ .../Controllers/CertificatesController.cs | 67 +++++++++++++++++++ .../Models/CertificateViewModel.cs | 8 +++ .../Startup.cs | 15 ++--- .../Views/Certificates/Create.cshtml | 7 ++ .../Views/Certificates/Detail.cshtml | 7 ++ .../Views/Certificates/Index.cshtml | 10 +++ .../Views/_ViewImports.cshtml | 2 + 12 files changed, 137 insertions(+), 11 deletions(-) create mode 100644 src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.gitignore create mode 100644 src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.name create mode 100644 src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/encodings.xml create mode 100644 src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/indexLayout.xml create mode 100644 src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/vcs.xml create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Models/CertificateViewModel.cs create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Create.cshtml create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Detail.cshtml create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Index.cshtml create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/_ViewImports.cshtml diff --git a/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.gitignore b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.gitignore new file mode 100644 index 00000000..bcdff6b0 --- /dev/null +++ b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.gitignore @@ -0,0 +1,13 @@ +# Default ignored files +/shelf/ +/workspace.xml +# Rider ignored files +/projectSettingsUpdater.xml +/.idea.O2NextGen.CGen.iml +/modules.xml +/contentModel.xml +# Datasource local storage ignored files +/dataSources/ +/dataSources.local.xml +# Editor-based HTTP Client requests +/httpRequests/ diff --git a/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.name b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.name new file mode 100644 index 00000000..0f7c9d3c --- /dev/null +++ b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/.name @@ -0,0 +1 @@ +O2NextGen.CGen \ No newline at end of file diff --git a/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/encodings.xml b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/encodings.xml new file mode 100644 index 00000000..df87cf95 --- /dev/null +++ b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/encodings.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/indexLayout.xml b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/indexLayout.xml new file mode 100644 index 00000000..7b08163c --- /dev/null +++ b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/indexLayout.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/vcs.xml b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/vcs.xml new file mode 100644 index 00000000..c2365ab1 --- /dev/null +++ b/src/Services/c-gen/.idea/.idea.O2NextGen.CGen/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs new file mode 100644 index 00000000..21481cc4 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs @@ -0,0 +1,67 @@ +using System.Collections.Generic; +using System.Linq; +using Microsoft.AspNetCore.Antiforgery.Internal; +using Microsoft.AspNetCore.Mvc; +using Microsoft.AspNetCore.Routing; +using O2NextGen.CertificateManagement.Web.Models; + +namespace O2NextGen.CertificateManagement.Web.Controllers +{ + [Route("certificates")] + public class CertificatesController : Controller + { + private static long _currentCertificateId = 1; + + private static List _certificates = new List() + { + new CertificateViewModel() {Id = 1, Name = "First"}, + new CertificateViewModel() {Id = 2, Name = "Second "} + }; + + [HttpGet] + [Route("")] + public IActionResult Index() + { + return View(_certificates); + } + + [HttpGet] + [Route("{id}")] + public IActionResult Detail(long id) + { + var certificate = _certificates.SingleOrDefault(_ => _.Id == id); + if (certificate == null) + return NotFound(); + return View(certificate); + } + + [HttpPost] + [Route("id")] + [ValidateAntiForgeryToken] + public IActionResult Edit(long id, CertificateViewModel model) + { + var certificate = _certificates.SingleOrDefault(_ => _.Id == id); + if (certificate == null) + return NotFound(); + certificate.Name = model.Name; + + return RedirectToAction("Index"); + } + + [HttpGet] + [Route("create")] + public IActionResult Create() + { + return View(); + } + + [HttpPost] + [Route("")] + public IActionResult CreateReally(CertificateViewModel model) + { + model.Id = _currentCertificateId++; + _certificates.Add(model); + return RedirectToAction("Index"); + } + } +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Models/CertificateViewModel.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Models/CertificateViewModel.cs new file mode 100644 index 00000000..aa93cab7 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Models/CertificateViewModel.cs @@ -0,0 +1,8 @@ +namespace O2NextGen.CertificateManagement.Web.Models +{ + public class CertificateViewModel + { + public long Id { get; set; } + public string Name { get; set; } + } +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs index 5b7dcb5f..f0527e8b 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs @@ -1,10 +1,5 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Builder; +using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Hosting; -using Microsoft.AspNetCore.Http; using Microsoft.Extensions.DependencyInjection; namespace O2NextGen.CertificateManagement.Web @@ -13,6 +8,7 @@ public class Startup { public void ConfigureServices(IServiceCollection services) { + services.AddMvc(); } public void Configure(IApplicationBuilder app, IHostingEnvironment env) @@ -21,11 +17,8 @@ public void Configure(IApplicationBuilder app, IHostingEnvironment env) { app.UseDeveloperExceptionPage(); } - - app.Run(async (context) => - { - await context.Response.WriteAsync("Hello World!"); - }); + + app.UseMvc(); } } } diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Create.cshtml b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Create.cshtml new file mode 100644 index 00000000..ea0630c9 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Create.cshtml @@ -0,0 +1,7 @@ +@model CertificateViewModel + +
+ + + +
diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Detail.cshtml b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Detail.cshtml new file mode 100644 index 00000000..6f2ec2a8 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Detail.cshtml @@ -0,0 +1,7 @@ +@model CertificateViewModel + +
+ + + +
diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Index.cshtml b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Index.cshtml new file mode 100644 index 00000000..da3ae7da --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/Certificates/Index.cshtml @@ -0,0 +1,10 @@ +@model IEnumerable + +@foreach (var certificate in Model) +{ +
  • + @certificate.Id @certificate.Name | Edit +
  • +} + +Create \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/_ViewImports.cshtml b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/_ViewImports.cshtml new file mode 100644 index 00000000..8020032e --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Views/_ViewImports.cshtml @@ -0,0 +1,2 @@ +@using O2NextGen.CertificateManagement.Web.Models +@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers \ No newline at end of file From a6ea4f9d69ceae4785122512e10eb5eea465d236 Mon Sep 17 00:00:00 2001 From: Denis Prokhorchik Date: Tue, 26 Oct 2021 15:47:21 +0300 Subject: [PATCH 4/7] Services/c-gen/O2NextGen: it's demo mvc --- src/Services/c-gen/O2NextGen.CGen.sln | 6 +++ .../Models/Certificate.cs | 8 ++++ ...tGen.CertificateManagement.Business.csproj | 13 +++++++ .../Services/ICertificatesService.cs | 13 +++++++ .../Controllers/CertificatesController.cs | 39 +++++++++++++------ .../Demo/CertificateIdGenerator.cs | 12 ++++++ .../Demo/ICertificateIdGenerator.cs | 7 ++++ .../Program.cs | 1 + .../Properties/launchSettings.json | 15 ------- .../Startup.cs | 22 ++++++++++- 10 files changed, 108 insertions(+), 28 deletions(-) create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Business/Models/Certificate.cs create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Business/O2NextGen.CertificateManagement.Business.csproj create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs diff --git a/src/Services/c-gen/O2NextGen.CGen.sln b/src/Services/c-gen/O2NextGen.CGen.sln index 3fcda6f5..9f8c3aad 100644 --- a/src/Services/c-gen/O2NextGen.CGen.sln +++ b/src/Services/c-gen/O2NextGen.CGen.sln @@ -5,6 +5,8 @@ VisualStudioVersion = 16.0.810.10 MinimumVisualStudioVersion = 10.0.40219.1 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "O2NextGen.CertificateManagement.Web", "O2NextGen.CertificateManagement.Web\O2NextGen.CertificateManagement.Web.csproj", "{EA540B06-8A73-49C7-A799-49423B316458}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "O2NextGen.CertificateManagement.Business", "O2NextGen.CertificateManagement.Business\O2NextGen.CertificateManagement.Business.csproj", "{C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -15,6 +17,10 @@ Global {EA540B06-8A73-49C7-A799-49423B316458}.Debug|Any CPU.Build.0 = Debug|Any CPU {EA540B06-8A73-49C7-A799-49423B316458}.Release|Any CPU.ActiveCfg = Release|Any CPU {EA540B06-8A73-49C7-A799-49423B316458}.Release|Any CPU.Build.0 = Release|Any CPU + {C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}.Debug|Any CPU.Build.0 = Debug|Any CPU + {C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}.Release|Any CPU.ActiveCfg = Release|Any CPU + {C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Models/Certificate.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Models/Certificate.cs new file mode 100644 index 00000000..01fd4850 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Models/Certificate.cs @@ -0,0 +1,8 @@ +namespace O2NextGen.CertificateManagement.Business.Models +{ + public class Certificate + { + public long Id { get; set; } + public string Name { get; set; } + } +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Business/O2NextGen.CertificateManagement.Business.csproj b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/O2NextGen.CertificateManagement.Business.csproj new file mode 100644 index 00000000..56768ce6 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/O2NextGen.CertificateManagement.Business.csproj @@ -0,0 +1,13 @@ + + + + netcoreapp2.1 + + + + + + + + + diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs new file mode 100644 index 00000000..c968b7bf --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs @@ -0,0 +1,13 @@ +using System.Collections.Generic; +using O2NextGen.CertificateManagement.Business.Models; + +namespace O2NextGen.CertificateManagement.Business.Services +{ + public interface ICertificatesService + { + IReadOnlyCollection GetAll(); + Certificate GetById(long id); + Certificate Update(Certificate certificate); + Certificate Add(Certificate certificate); + } +} diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs index 21481cc4..956eaa5d 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs @@ -1,8 +1,7 @@ using System.Collections.Generic; using System.Linq; -using Microsoft.AspNetCore.Antiforgery.Internal; using Microsoft.AspNetCore.Mvc; -using Microsoft.AspNetCore.Routing; +using O2NextGen.CertificateManagement.Web.Demo; using O2NextGen.CertificateManagement.Web.Models; namespace O2NextGen.CertificateManagement.Web.Controllers @@ -10,26 +9,42 @@ namespace O2NextGen.CertificateManagement.Web.Controllers [Route("certificates")] public class CertificatesController : Controller { - private static long _currentCertificateId = 1; + #region Fields - private static List _certificates = new List() + private readonly ICertificateIdGenerator _generator; + + private static readonly List Certificates = new List() { - new CertificateViewModel() {Id = 1, Name = "First"}, - new CertificateViewModel() {Id = 2, Name = "Second "} + new CertificateViewModel() {Id = 1, Name = "First"} }; + + #endregion + + + #region Ctors + + public CertificatesController( ICertificateIdGenerator generator) + { + _generator = generator; + } + + #endregion + + + #region Methods [HttpGet] [Route("")] public IActionResult Index() { - return View(_certificates); + return View(Certificates); } [HttpGet] [Route("{id}")] public IActionResult Detail(long id) { - var certificate = _certificates.SingleOrDefault(_ => _.Id == id); + var certificate = Certificates.SingleOrDefault(_ => _.Id == id); if (certificate == null) return NotFound(); return View(certificate); @@ -40,7 +55,7 @@ public IActionResult Detail(long id) [ValidateAntiForgeryToken] public IActionResult Edit(long id, CertificateViewModel model) { - var certificate = _certificates.SingleOrDefault(_ => _.Id == id); + var certificate = Certificates.SingleOrDefault(_ => _.Id == id); if (certificate == null) return NotFound(); certificate.Name = model.Name; @@ -59,9 +74,11 @@ public IActionResult Create() [Route("")] public IActionResult CreateReally(CertificateViewModel model) { - model.Id = _currentCertificateId++; - _certificates.Add(model); + model.Id = _generator.Next(); + Certificates.Add(model); return RedirectToAction("Index"); } + + #endregion } } \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs new file mode 100644 index 00000000..45d6aeb4 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs @@ -0,0 +1,12 @@ +namespace O2NextGen.CertificateManagement.Web.Demo +{ + public class CertificateIdGenerator : ICertificateIdGenerator + { + private long _currentId = 1; + + public long Next() + { + return ++_currentId; + } + } +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs new file mode 100644 index 00000000..7dfe01b4 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs @@ -0,0 +1,7 @@ +namespace O2NextGen.CertificateManagement.Web.Demo +{ + public interface ICertificateIdGenerator + { + long Next(); + } +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs index e65d7ec5..39abb3ce 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Program.cs @@ -14,6 +14,7 @@ public class Program { public static void Main(string[] args) { + Console.WriteLine("################# Starting Application #################"); CreateWebHostBuilder(args).Build().Run(); } diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json index 54d71450..f9858d76 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Properties/launchSettings.json @@ -1,20 +1,5 @@ { - "iisSettings": { - "windowsAuthentication": false, - "anonymousAuthentication": true, - "iisExpress": { - "applicationUrl": "http://localhost:21259", - "sslPort": 44316 - } - }, "profiles": { - "IIS Express": { - "commandName": "IISExpress", - "launchBrowser": true, - "environmentVariables": { - "ASPNETCORE_ENVIRONMENT": "Development" - } - }, "O2NextGen.CertificateManagement.Web": { "commandName": "Project", "launchBrowser": true, diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs index f0527e8b..be5def18 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs @@ -1,6 +1,8 @@ -using Microsoft.AspNetCore.Builder; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Hosting; using Microsoft.Extensions.DependencyInjection; +using O2NextGen.CertificateManagement.Web.Demo; namespace O2NextGen.CertificateManagement.Web { @@ -9,6 +11,9 @@ public class Startup public void ConfigureServices(IServiceCollection services) { services.AddMvc(); + + services.AddSingleton(); + } public void Configure(IApplicationBuilder app, IHostingEnvironment env) @@ -17,8 +22,21 @@ public void Configure(IApplicationBuilder app, IHostingEnvironment env) { app.UseDeveloperExceptionPage(); } + + app.UseStaticFiles(); + app.Use(async (context, next) => + { + context.Response.OnStarting(() => + { + context.Response.Headers.Add("X-Power-By", "O2NextGen: C-Gen"); + return Task.CompletedTask; + }); + + await next.Invoke(); + }); + app.UseMvc(); } } -} +} \ No newline at end of file From a2dcd91a3613d6a00e8eae0674c295b8b29524f4 Mon Sep 17 00:00:00 2001 From: Denis Prokhorchik Date: Tue, 26 Oct 2021 16:43:09 +0300 Subject: [PATCH 5/7] Services/c-gen/O2NextGen: implement the InMemoryCertificatesService.cs --- src/Services/c-gen/O2NextGen.CGen.sln | 8 +++ .../Services/ICertificatesService.cs | 5 +- ...2NextGen.CertificateManagement.Impl.csproj | 16 +++++ .../Services/InMemoryCertificatesService.cs | 61 +++++++++++++++++++ .../Controllers/CertificatesController.cs | 49 ++++++++------- .../Demo/CertificateIdGenerator.cs | 2 +- .../Mappings/CertificateMappings.cs | 58 ++++++++++++++++++ ...O2NextGen.CertificateManagement.Web.csproj | 7 +++ .../Startup.cs | 8 +-- 9 files changed, 183 insertions(+), 31 deletions(-) create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Impl/O2NextGen.CertificateManagement.Impl.csproj create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Impl/Services/InMemoryCertificatesService.cs create mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Mappings/CertificateMappings.cs diff --git a/src/Services/c-gen/O2NextGen.CGen.sln b/src/Services/c-gen/O2NextGen.CGen.sln index 9f8c3aad..683b9695 100644 --- a/src/Services/c-gen/O2NextGen.CGen.sln +++ b/src/Services/c-gen/O2NextGen.CGen.sln @@ -7,6 +7,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "O2NextGen.CertificateManage EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "O2NextGen.CertificateManagement.Business", "O2NextGen.CertificateManagement.Business\O2NextGen.CertificateManagement.Business.csproj", "{C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "O2NextGen.CertificateManagement.Impl", "O2NextGen.CertificateManagement.Impl\O2NextGen.CertificateManagement.Impl.csproj", "{01805439-2954-49CE-93D2-5EB06B82146C}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{12E83C2A-23C7-4E71-B137-AC56CE28F9E4}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -21,6 +25,10 @@ Global {C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}.Debug|Any CPU.Build.0 = Debug|Any CPU {C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}.Release|Any CPU.ActiveCfg = Release|Any CPU {C6E0B2A5-6349-4C1D-8E14-82249AF8F58A}.Release|Any CPU.Build.0 = Release|Any CPU + {01805439-2954-49CE-93D2-5EB06B82146C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {01805439-2954-49CE-93D2-5EB06B82146C}.Debug|Any CPU.Build.0 = Debug|Any CPU + {01805439-2954-49CE-93D2-5EB06B82146C}.Release|Any CPU.ActiveCfg = Release|Any CPU + {01805439-2954-49CE-93D2-5EB06B82146C}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs index c968b7bf..9e353920 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Business/Services/ICertificatesService.cs @@ -6,8 +6,11 @@ namespace O2NextGen.CertificateManagement.Business.Services public interface ICertificatesService { IReadOnlyCollection GetAll(); + Certificate GetById(long id); + Certificate Update(Certificate certificate); + Certificate Add(Certificate certificate); } -} +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Impl/O2NextGen.CertificateManagement.Impl.csproj b/src/Services/c-gen/O2NextGen.CertificateManagement.Impl/O2NextGen.CertificateManagement.Impl.csproj new file mode 100644 index 00000000..8ae43b76 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Impl/O2NextGen.CertificateManagement.Impl.csproj @@ -0,0 +1,16 @@ + + + + netcoreapp2.1 + + + + + + + + + + + + diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Impl/Services/InMemoryCertificatesService.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Impl/Services/InMemoryCertificatesService.cs new file mode 100644 index 00000000..4e6061e0 --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Impl/Services/InMemoryCertificatesService.cs @@ -0,0 +1,61 @@ +using System.Collections.Generic; +using System.Linq; +using O2NextGen.CertificateManagement.Business.Models; +using O2NextGen.CertificateManagement.Business.Services; + +namespace O2NextGen.CertificateManagement.Impl.Services +{ + public class InMemoryCertificatesService : ICertificatesService + { + #region Fields + + private static readonly List Certificates = new List() + { + new Certificate() + { + Id = 1, Name = "First" + } + }; + private long _currentId; + + #endregion + + #region Ctors + + public InMemoryCertificatesService() + { + _currentId = Certificates.Count(); + } + #endregion + + #region Methods + public IReadOnlyCollection GetAll() + { + return Certificates.AsReadOnly(); + } + + public Certificate GetById(long id) + { + return Certificates.SingleOrDefault(g => g.Id == id); + } + + public Certificate Update(Certificate certificate) + { + var toUpdate = Certificates.SingleOrDefault(g => g.Id == certificate.Id); + if (toUpdate == null) + return null; + + toUpdate.Name = certificate.Name; + + return toUpdate; + } + + public Certificate Add(Certificate certificate) + { + certificate.Id = ++_currentId; + Certificates.Add(certificate); + return certificate; + } + #endregion + } +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs index 956eaa5d..6a517469 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs @@ -1,7 +1,6 @@ -using System.Collections.Generic; -using System.Linq; using Microsoft.AspNetCore.Mvc; -using O2NextGen.CertificateManagement.Web.Demo; +using O2NextGen.CertificateManagement.Business.Services; +using O2NextGen.CertificateManagement.Web.Mappings; using O2NextGen.CertificateManagement.Web.Models; namespace O2NextGen.CertificateManagement.Web.Controllers @@ -11,43 +10,43 @@ public class CertificatesController : Controller { #region Fields - private readonly ICertificateIdGenerator _generator; - - private static readonly List Certificates = new List() - { - new CertificateViewModel() {Id = 1, Name = "First"} - }; - + private readonly ICertificatesService _certificatesService; + + + #endregion - - + + #region Ctors - - public CertificatesController( ICertificateIdGenerator generator) + + public CertificatesController(ICertificatesService certificatesService) { - _generator = generator; + _certificatesService = certificatesService; } - + #endregion - + #region Methods [HttpGet] [Route("")] public IActionResult Index() { - return View(Certificates); + var models = _certificatesService.GetAll(); + if (models == null) + return NotFound(); + return View(models.ToViewModel()); } [HttpGet] [Route("{id}")] public IActionResult Detail(long id) { - var certificate = Certificates.SingleOrDefault(_ => _.Id == id); + var certificate = _certificatesService.GetById(id); if (certificate == null) return NotFound(); - return View(certificate); + return View(certificate.ToViewModel()); } [HttpPost] @@ -55,27 +54,27 @@ public IActionResult Detail(long id) [ValidateAntiForgeryToken] public IActionResult Edit(long id, CertificateViewModel model) { - var certificate = Certificates.SingleOrDefault(_ => _.Id == id); + var certificate = _certificatesService.Update(model.ToModel()); if (certificate == null) return NotFound(); certificate.Name = model.Name; return RedirectToAction("Index"); } - + [HttpGet] [Route("create")] public IActionResult Create() { return View(); } - + [HttpPost] [Route("")] public IActionResult CreateReally(CertificateViewModel model) { - model.Id = _generator.Next(); - Certificates.Add(model); + var certificate = _certificatesService.Add(model.ToModel()); + return RedirectToAction("Index"); } diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs index 45d6aeb4..c837a31b 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs @@ -1,6 +1,6 @@ namespace O2NextGen.CertificateManagement.Web.Demo { - public class CertificateIdGenerator : ICertificateIdGenerator + public class CertificatesService : ICertificateIdGenerator { private long _currentId = 1; diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Mappings/CertificateMappings.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Mappings/CertificateMappings.cs new file mode 100644 index 00000000..be9f8dfa --- /dev/null +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Mappings/CertificateMappings.cs @@ -0,0 +1,58 @@ +using System; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using O2NextGen.CertificateManagement.Business.Models; +using O2NextGen.CertificateManagement.Web.Models; + +namespace O2NextGen.CertificateManagement.Web.Mappings +{ + public static class CertificateMappings + { + public static CertificateViewModel ToViewModel(this Certificate model) + { + if (model == null) + return null; + + var viewModel = new CertificateViewModel(); + + //Bindings + viewModel.Id = model.Id; + viewModel.Name = model.Name; + + return viewModel; + } + + public static Certificate ToModel(this CertificateViewModel viewModel) + { + if (viewModel == null) + return null; + + var model = new Certificate(); + + //Bindings + model.Id = viewModel.Id; + model.Name = viewModel.Name; + + return model; + } + + public static IReadOnlyCollection ToViewModel( + this IReadOnlyCollection models) + { + if (models.Count == 0) + { + return Array.Empty(); + } + + var subscription = new CertificateViewModel[models.Count]; + var i = 0; + foreach (var model in models) + { + subscription[i] = ToViewModel(model); + ++i; + } + + return new ReadOnlyCollection(subscription); + } + } +} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj index d62ba8be..6a042cde 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/O2NextGen.CertificateManagement.Web.csproj @@ -12,4 +12,11 @@ + + + + + + + diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs index be5def18..9ef77ab3 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Startup.cs @@ -2,7 +2,8 @@ using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Hosting; using Microsoft.Extensions.DependencyInjection; -using O2NextGen.CertificateManagement.Web.Demo; +using O2NextGen.CertificateManagement.Business.Services; +using O2NextGen.CertificateManagement.Impl.Services; namespace O2NextGen.CertificateManagement.Web { @@ -11,9 +12,8 @@ public class Startup public void ConfigureServices(IServiceCollection services) { services.AddMvc(); - - services.AddSingleton(); - + + services.AddSingleton(); } public void Configure(IApplicationBuilder app, IHostingEnvironment env) From 88ebc2bf8fad22e23d1cfd3a1e910cbd5da29ca1 Mon Sep 17 00:00:00 2001 From: Denis Prokhorchik Date: Tue, 26 Oct 2021 16:46:27 +0300 Subject: [PATCH 6/7] chore: remove temp classes --- .../Controllers/CertificatesController.cs | 3 +-- .../Demo/CertificateIdGenerator.cs | 12 ------------ .../Demo/ICertificateIdGenerator.cs | 7 ------- 3 files changed, 1 insertion(+), 21 deletions(-) delete mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs delete mode 100644 src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs index 6a517469..60c181c3 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs @@ -73,8 +73,7 @@ public IActionResult Create() [Route("")] public IActionResult CreateReally(CertificateViewModel model) { - var certificate = _certificatesService.Add(model.ToModel()); - + _certificatesService.Add(model.ToModel()); return RedirectToAction("Index"); } diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs deleted file mode 100644 index c837a31b..00000000 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/CertificateIdGenerator.cs +++ /dev/null @@ -1,12 +0,0 @@ -namespace O2NextGen.CertificateManagement.Web.Demo -{ - public class CertificatesService : ICertificateIdGenerator - { - private long _currentId = 1; - - public long Next() - { - return ++_currentId; - } - } -} \ No newline at end of file diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs deleted file mode 100644 index 7dfe01b4..00000000 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Demo/ICertificateIdGenerator.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace O2NextGen.CertificateManagement.Web.Demo -{ - public interface ICertificateIdGenerator - { - long Next(); - } -} \ No newline at end of file From 8017d57d9123f2271ba6bd39dac02a7b00fbe5dc Mon Sep 17 00:00:00 2001 From: Denis Prokhorchik Date: Tue, 26 Oct 2021 17:01:42 +0300 Subject: [PATCH 7/7] style: update Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController --- .../Controllers/CertificatesController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs index 60c181c3..b48b8643 100644 --- a/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs +++ b/src/Services/c-gen/O2NextGen.CertificateManagement.Web/Controllers/CertificatesController.cs @@ -12,7 +12,7 @@ public class CertificatesController : Controller private readonly ICertificatesService _certificatesService; - + #endregion