57 lines
1.3 KiB
Plaintext
57 lines
1.3 KiB
Plaintext
|
@using ComputerHardwareStoreContracts.ViewModels
|
||
|
@model List<PurchaseViewModel>
|
||
|
@{
|
||
|
ViewData["Title"] = "Purchases";
|
||
|
}
|
||
|
<div class="text-center">
|
||
|
<h1 class="display-4">Покупки товаров и сборок</h1>
|
||
|
</div>
|
||
|
<div class="text-center">
|
||
|
@{
|
||
|
if (Model == null)
|
||
|
{
|
||
|
<h3 class="display-4">Надо войти!</h3>
|
||
|
return;
|
||
|
}
|
||
|
<p>
|
||
|
<a class="text-decoration-none me-3 text-black h5" asp-action="CreatePurchase">Создать покупку</a>
|
||
|
<a class="text-decoration-none me-3 text-black h5" asp-action="UpdatePurchase">Изменить покупку</a>
|
||
|
<a class="text-decoration-none text-black h5" asp-action="DeletePurchase">Удалить покупку</a>
|
||
|
</p>
|
||
|
|
||
|
<table class="PurchaseTable">
|
||
|
<thead>
|
||
|
<tr>
|
||
|
<th>
|
||
|
Номер
|
||
|
</th>
|
||
|
<th>
|
||
|
Дата создания
|
||
|
</th>
|
||
|
<th>
|
||
|
Дата выполнения
|
||
|
</th>
|
||
|
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
<tbody>
|
||
|
@foreach (var purchase in Model)
|
||
|
{
|
||
|
<tr>
|
||
|
<td>
|
||
|
@Html.DisplayFor(modelItem => purchase.Id)
|
||
|
</td>
|
||
|
<td>
|
||
|
@Html.DisplayFor(modelItem => purchase.DateCreate)
|
||
|
</td>
|
||
|
<td>
|
||
|
@Html.DisplayFor(modelItem => purchase.DateImplement)
|
||
|
</td>
|
||
|
</tr>
|
||
|
}
|
||
|
</tbody>
|
||
|
</tbody>
|
||
|
</table>
|
||
|
}
|
||
|
</div>
|