diff options
author | Sergey Chebotar <s.chebotar@gmail.com> | 2023-02-16 08:28:59 +0300 |
---|---|---|
committer | Sergey Chebotar <s.chebotar@gmail.com> | 2023-02-16 08:28:59 +0300 |
commit | e4b4105ec0802dd0f1b735e5cb7fba083a0ffe0c (patch) | |
tree | d857967fb3f6bf5ce7caa7359d4b4f864d5b2bc9 /Views/Bundles | |
parent | 9107bb6788428a3504adbeea2bc5c060e17f895d (diff) |
Add edit page
Diffstat (limited to 'Views/Bundles')
-rw-r--r-- | Views/Bundles/Edit.cshtml | 34 | ||||
-rw-r--r-- | Views/Bundles/Index.cshtml | 2 |
2 files changed, 35 insertions, 1 deletions
diff --git a/Views/Bundles/Edit.cshtml b/Views/Bundles/Edit.cshtml new file mode 100644 index 0000000..60a2420 --- /dev/null +++ b/Views/Bundles/Edit.cshtml @@ -0,0 +1,34 @@ +@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers + +<!DOCTYPE html> +<html> + +<head> + <title>Bundles list</title> + <link href="/lib/bootstrap/css/bootstrap.min.css" rel="stylesheet" /> +</head> + +<body> + <container> + <table class="table table-striped"> + <thead> + <tr> + <th scope="col">#</th> + <th scope="col">Name</th> + <th scope="col">Descrition</th> + <th scope="col">Price</th> + </tr> + </thead> + <tbody> + <tr> + <th scope="row">@Model.Id</th> + <td>@Model.Name</a></td> + <td>@Model.Description</td> + <td>@Model.Price</td> + </tr> + </tbody> + </table> + </container> +</body> + +</html>
\ No newline at end of file diff --git a/Views/Bundles/Index.cshtml b/Views/Bundles/Index.cshtml index 4f3a120..6c36cb7 100644 --- a/Views/Bundles/Index.cshtml +++ b/Views/Bundles/Index.cshtml @@ -25,7 +25,7 @@ { <tr> <th scope="row">@bundle.Id</th> - <td>@bundle.Name</td> + <td><a asp-action="Edit" asp-route-id="@bundle.Id">@bundle.Name</a></td> <td>@bundle.Description</td> <td>@bundle.Price</td> </tr> |