diff --git a/Archive/Controllers/PagesController.cs b/Archive/Controllers/PagesController.cs index 9a6577c..aa400fb 100644 --- a/Archive/Controllers/PagesController.cs +++ b/Archive/Controllers/PagesController.cs @@ -4,6 +4,7 @@ using OI.Metrology.Archive.Models; using OI.Metrology.Shared.Repositories; using OI.Metrology.Shared.ViewModels; using System; +using IO = System.IO; namespace OI.Metrology.Archive.Controllers; @@ -60,4 +61,44 @@ public class PagesController : Controller [HttpGet] [Route("/Crash")] public IActionResult Crash() => throw new Exception("Test unhandled exception"); + + [HttpGet] + [Route("/Step1")] + [Route("/Metrology/Step1")] + public IActionResult Step1(string mod = "", string equipment = "", string layer = "", string zone = "", string rds = "", string initials = "") + { + string directory = "D:/Tmp/Metrology"; + if (!IO.Directory.Exists(directory)) + _ = IO.Directory.CreateDirectory(directory); + string[] model = new string[] { mod, equipment, layer, zone, rds, initials }; + if (!string.IsNullOrEmpty(initials)) + IO.File.WriteAllLines(IO.Path.Combine(directory, $"{DateTime.Now.Ticks}.rsv"), model); + return View(model); + } + + [HttpGet] + [Route("/Step2")] + [Route("/Metrology/Step2")] + public IActionResult Step2(string mod) => View(new string[] { mod }); + + [HttpGet] + [Route("/Step3")] + [Route("/Metrology/Step3")] + public IActionResult Step3(string mod, string equipment) => View(new string[] { mod, equipment }); + + [HttpGet] + [Route("/Step4")] + [Route("/Metrology/Step4")] + public IActionResult Step4(string mod, string equipment, string layer) => View(new string[] { mod, equipment, layer }); + + [HttpGet] + [Route("/Step5")] + [Route("/Metrology/Step5")] + public IActionResult Step5(string mod, string equipment, string layer, string zone) => View(new string[] { mod, equipment, layer, zone }); + + [HttpGet] + [Route("/Step6")] + [Route("/Metrology/Step6")] + public IActionResult Step6(string mod, string equipment, string layer, string zone, string rds) => View(new string[] { mod, equipment, layer, zone, rds }); + } \ No newline at end of file diff --git a/Archive/Views/Pages/Step1.cshtml b/Archive/Views/Pages/Step1.cshtml new file mode 100644 index 0000000..b2397d4 --- /dev/null +++ b/Archive/Views/Pages/Step1.cshtml @@ -0,0 +1,96 @@ +@model string[] +@{ + ViewData["Title"] = "Step 1"; + string side = Model[0] == "0" ? "Even" : "Odd"; +} + + + +@if (!string.IsNullOrEmpty(Model[5])) +{ +
+ + | ++ + | ++ + | +
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+ + | ++ + | +
+
+
+
+ |
+
+ + | ++ + | ++ + | +|
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+ + | ++ + | +
+
+
+
+ |
+
+ + | ++ + | ++ + | +|
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+ + | ++ + | +
+
+
+
+ |
+
+ + | ++ + | ++ + | +|
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+ |
+ + | ++ + | ++ + | +
+
+
+ + + |
+
+ + | ++ + | +
+
+
+
+ |
+
+ + | ++ + | ++ + | +
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+ + | ++ + | +
+
+
+
+ |
+
+ + | ++ + | ++ + | +
+ + | +
+
+
+
+ |
+
+
+
+
+ |
+
+ + | ++ + | +
+
+
+
+ |
+