diff --git a/AutoWorkshopShopApp/Controllers/HomeController.cs b/AutoWorkshopShopApp/Controllers/HomeController.cs index 0af6219..2b51c13 100644 --- a/AutoWorkshopShopApp/Controllers/HomeController.cs +++ b/AutoWorkshopShopApp/Controllers/HomeController.cs @@ -124,7 +124,7 @@ namespace AutoWorkshopShopApp.Controllers } ViewBag.Shops = ApiClient.GetRequest>($"api/shop/getshoplist?password={ApiClient.Password}"); - ViewBag.Pizzas = ApiClient.GetRequest>($"api/main/getpizzalist"); + ViewBag.Repairs = ApiClient.GetRequest>($"api/main/getrepairlist"); return View(); } diff --git a/AutoWorkshopShopApp/Views/Home/Enter.cshtml b/AutoWorkshopShopApp/Views/Home/Enter.cshtml new file mode 100644 index 0000000..5dca626 --- /dev/null +++ b/AutoWorkshopShopApp/Views/Home/Enter.cshtml @@ -0,0 +1,15 @@ +@{ + ViewData["Title"] = "Enter"; +} + +
+

Вход в систему

+
+ +
+
+ + +
+ +
\ No newline at end of file diff --git a/AutoWorkshopShopApp/Views/Home/Index.cshtml b/AutoWorkshopShopApp/Views/Home/Index.cshtml index d2d19bd..600c2d7 100644 --- a/AutoWorkshopShopApp/Views/Home/Index.cshtml +++ b/AutoWorkshopShopApp/Views/Home/Index.cshtml @@ -1,8 +1,68 @@ -@{ +@using AutoWorkshopContracts.ViewModels + +@model List + +@{ ViewData["Title"] = "Home Page"; }
-

Welcome

-

Learn about building Web apps with ASP.NET Core.

+

Магазины

+ + +
+

+ Создать магазин +

+ + + + + + + + + + + + + + @foreach (var Item in Model) + { + + + + + + + + + } + +
+ Номер + + Название + + Адрес + + Дата открытия + + Максимальная вместимость + + +
+ @Html.DisplayFor(ModelItem => Item.Id) + + @Html.DisplayFor(ModelItem => Item.ShopName) + + @Html.DisplayFor(ModelItem => Item.Address) + + @Html.DisplayFor(ModelItem => Item.OpeningDate) + + @Html.DisplayFor(ModelItem => Item.RepairsMaxCount) + + Изменить +
+
\ No newline at end of file diff --git a/AutoWorkshopShopApp/Views/Home/Privacy.cshtml b/AutoWorkshopShopApp/Views/Home/Privacy.cshtml deleted file mode 100644 index af4fb19..0000000 --- a/AutoWorkshopShopApp/Views/Home/Privacy.cshtml +++ /dev/null @@ -1,6 +0,0 @@ -@{ - ViewData["Title"] = "Privacy Policy"; -} -

@ViewData["Title"]

- -

Use this page to detail your site's privacy policy.

diff --git a/AutoWorkshopShopApp/Views/Home/Shop.cshtml b/AutoWorkshopShopApp/Views/Home/Shop.cshtml new file mode 100644 index 0000000..d97f45f --- /dev/null +++ b/AutoWorkshopShopApp/Views/Home/Shop.cshtml @@ -0,0 +1,75 @@ +@using AutoWorkshopDataModels.Models; +@using AutoWorkshopContracts.ViewModels; + +@model ShopRepairViewModel + +@{ + ViewData["Title"] = "Shop"; +} + +
+ @{ + if (Model == null) + { +

Создание магазина

+ } + else + { +

Изменение магазина

+ } + } +
+ +
+
+ + +
+
+ + +
+
+ + +
+
+ + +
+
+ + @{ + if (Model != null && Model.Shop != null) + { + + } + } +
+
+@{ + if (Model != null && Model.Shop != null) + { +
+
Содержимое магазина
+
+ + + + + + + + + @foreach (var item in Model.ShopRepairs) + { + + + + + } + + +
НазваниеКоличество
@Html.DisplayFor(modelItem => item.Value.Repair.RepairName)@Html.DisplayFor(modelItem => item.Value.Count)
+ } +} \ No newline at end of file diff --git a/AutoWorkshopShopApp/Views/Home/Supply.cshtml b/AutoWorkshopShopApp/Views/Home/Supply.cshtml new file mode 100644 index 0000000..a8d529f --- /dev/null +++ b/AutoWorkshopShopApp/Views/Home/Supply.cshtml @@ -0,0 +1,22 @@ +@{ + ViewData["Title"] = "Supply"; +} +
+

Создание поставки

+
+
+
+ + +
+
+ + +
+
+ + +
+ + Отмена +
\ No newline at end of file diff --git a/AutoWorkshopShopApp/Views/Shared/_Layout.cshtml b/AutoWorkshopShopApp/Views/Shared/_Layout.cshtml index 543c883..dff6c61 100644 --- a/AutoWorkshopShopApp/Views/Shared/_Layout.cshtml +++ b/AutoWorkshopShopApp/Views/Shared/_Layout.cshtml @@ -12,7 +12,7 @@