CourseWork_BankYouBankrupt/BankYouBankrupt/BankYouBankruptCashierApp/Views/Home/Index.cshtml

67 lines
1.2 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@using BankYouBankruptContracts.ViewModels
@model List<AccountViewModel>
@{
ViewData["Title"] = "Cписок счетов";
}
<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 asp-action="Create">Открыть счёт</a>
</p>
<table class="table">
<thead>
<tr>
<th>
Номер счёта
</th>
<th>
Имя владельца
</th>
<th>
Отчество владельца
</th>
<th>
Балланс
</th>
<th>
Дата открытия
</th>
</tr>
</thead>
<tbody>
@foreach (var item in Model)
{
<tr>
<td>
@Html.DisplayFor(modelItem => item.AccountNumber)
</td>
<td>
@Html.DisplayFor(modelItem => item.Name)
</td>
<td>
@Html.DisplayFor(modelItem => item.Patronymic)
</td>
<td>
@Html.DisplayFor(modelItem => item.Balance)
</td>
<td>
@Html.DisplayFor(modelItem => item.DateOpen)
</td>
</tr>
}
</tbody>
</table>
}
</div>