diff options
Diffstat (limited to 'Views/Products/Index.cshtml')
-rw-r--r-- | Views/Products/Index.cshtml | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/Views/Products/Index.cshtml b/Views/Products/Index.cshtml new file mode 100644 index 0000000..0725bb6 --- /dev/null +++ b/Views/Products/Index.cshtml @@ -0,0 +1,43 @@ +@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers +@model IQueryable<MyDarling.Models.Product> + +<!DOCTYPE html> +<html> + +<head> + <title>My Darling Underwear</title> + <link href="/lib/bootstrap/css/bootstrap.min.css" rel="stylesheet" /> +</head> + +<body> + <nav class="navbar navbar-dark bg-primary"> + <a class="navbar-brand mx-4" href="/Products"><img height="30" src="/assets/img/logo.svg"></a> + <a href="/Account/logout"><button class="btn btn-outline-light mx-4">Выйти</button></a> + </nav> + <div class="row container-fluid justify-content-center row-cols-xl-2"> + <div class="col"> + <table class="table"> + <thead> + <tr> + <th scope="col">Название</th> + <th scope="col">Описание</th> + <th scope="col">Цена</th> + </tr> + </thead> + <tbody> + @foreach (var bundle in Model) + { + <tr> + <td><a asp-action="Details" asp-route-id="@bundle.Id">@bundle.Name</a></td> + <td>@bundle.Description</td> + <td>@bundle.Price</td> + </tr> + } + </tbody> + </table> + <a asp-action="Create"><button class="btn btn-primary">Добавить</button></a> + </div> + </div> +</body> + +</html>
\ No newline at end of file |