2023-05-17 19:16:54 +04:00
|
|
|
@using SchoolAgainStudyContracts.ViewModel;
|
|
|
|
|
|
|
|
@model List<DiyViewModel>
|
|
|
|
|
|
|
|
@{
|
|
|
|
ViewData["Title"] = "Home Page";
|
|
|
|
}
|
|
|
|
|
|
|
|
<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="CreateDiy">Создать поделку</a>
|
|
|
|
</p>
|
|
|
|
<table class="table">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>
|
|
|
|
Название
|
|
|
|
</th>
|
|
|
|
<th>
|
|
|
|
Дата создания
|
|
|
|
</th>
|
|
|
|
<th>
|
|
|
|
Задание
|
|
|
|
</th>
|
2023-05-18 00:03:47 +04:00
|
|
|
<th>
|
|
|
|
Интересы
|
|
|
|
</th>
|
2023-05-17 19:16:54 +04:00
|
|
|
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
@foreach (var item in Model)
|
|
|
|
{
|
|
|
|
<tr>
|
|
|
|
<td>
|
|
|
|
@Html.DisplayFor(modelItem => item.Title)
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
@Html.DisplayFor(modelItem => item.DateCreate)
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
@Html.DisplayFor(modelItem => item.TaskName)
|
|
|
|
</td>
|
2023-05-18 00:03:47 +04:00
|
|
|
<td>
|
|
|
|
<select asp-items="@(new SelectList(item.DiyInterests,"Key", "Value.Title"))"></select>
|
|
|
|
</td>
|
2023-05-17 19:16:54 +04:00
|
|
|
<td>
|
|
|
|
<a href="@Url.Action("DiySetting","Home", new {id=item.Id })"
|
|
|
|
class="btn btn-primary btn-lg">U</a>
|
|
|
|
</td>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
}
|
|
|
|
</div>
|