@using BankContracts.ViewModels

@model List<PaymentViewModel>

@{
	ViewData["Title"] = "Payments";
}

<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="CreatePayment">Создать выплату</a>
				</p>
				<table class="table">
					<thead>
						<tr>
							<th>
								Номер выплаты
							</th>
							<th>
								ФИО оператора
							</th>
							<th>
								Дата
							</th>
						</tr>
					</thead>
					<tbody>
				@foreach (var item in Model)
				{
									<tr>
										<td>
							@Html.DisplayFor(modelItem => item.Id)
										</td>
										<td>
							@Html.DisplayFor(modelItem => item.OperatorName)
										</td>
										<td>
							@Html.DisplayFor(modelItem => item.PaymentDate)
										</td>
									</tr>
				}
					</tbody>
				</table>
	}
</div>