Index.cshtml 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. @model IEnumerable<ShoeShopMvc.Models.Product>
  2. @{
  3. ViewData["Title"] = "Index";
  4. }
  5. <h1>Index</h1>
  6. <p>
  7. <a asp-action="Create">Create New</a>
  8. </p>
  9. <table class="table">
  10. <thead>
  11. <tr>
  12. <th>
  13. @Html.DisplayNameFor(model => model.ProductName)
  14. </th>
  15. <th>
  16. @Html.DisplayNameFor(model => model.EdIzm)
  17. </th>
  18. <th>
  19. @Html.DisplayNameFor(model => model.Price)
  20. </th>
  21. <th>
  22. @Html.DisplayNameFor(model => model.SupplierId)
  23. </th>
  24. <th>
  25. @Html.DisplayNameFor(model => model.ManufactureId)
  26. </th>
  27. <th>
  28. @Html.DisplayNameFor(model => model.CategoryId)
  29. </th>
  30. <th>
  31. @Html.DisplayNameFor(model => model.Skidka)
  32. </th>
  33. <th>
  34. @Html.DisplayNameFor(model => model.Colvo)
  35. </th>
  36. <th>
  37. @Html.DisplayNameFor(model => model.OpisanieProduct)
  38. </th>
  39. <th>
  40. @Html.DisplayNameFor(model => model.Image)
  41. </th>
  42. <th></th>
  43. </tr>
  44. </thead>
  45. <tbody>
  46. @foreach (var item in Model) {
  47. <tr>
  48. <td>
  49. @Html.DisplayFor(modelItem => item.ProductName)
  50. </td>
  51. <td>
  52. @Html.DisplayFor(modelItem => item.EdIzm)
  53. </td>
  54. <td>
  55. @Html.DisplayFor(modelItem => item.Price)
  56. </td>
  57. <td>
  58. @Html.DisplayFor(modelItem => item.SupplierId)
  59. </td>
  60. <td>
  61. @Html.DisplayFor(modelItem => item.ManufactureId)
  62. </td>
  63. <td>
  64. @Html.DisplayFor(modelItem => item.CategoryId)
  65. </td>
  66. <td>
  67. @Html.DisplayFor(modelItem => item.Skidka)
  68. </td>
  69. <td>
  70. @Html.DisplayFor(modelItem => item.Colvo)
  71. </td>
  72. <td>
  73. @Html.DisplayFor(modelItem => item.OpisanieProduct)
  74. </td>
  75. <td>
  76. @Html.DisplayFor(modelItem => item.Image)
  77. </td>
  78. <td>
  79. <a asp-action="Edit" asp-route-id="@item.Article">Edit</a> |
  80. <a asp-action="Details" asp-route-id="@item.Article">Details</a> |
  81. <a asp-action="Delete" asp-route-id="@item.Article">Delete</a>
  82. </td>
  83. </tr>
  84. }
  85. </tbody>
  86. </table>