CourseWork_SchoolStudyAgain/SchoolAgainStudy/TeacherWebClient/Views/Home/TaskSetting.cshtml

36 lines
1.4 KiB
Plaintext
Raw Normal View History

2023-05-18 20:00:05 +04:00
@using SchoolAgainStudyContracts.ViewModel;
@model TaskViewModel
@{
ViewData["Title"] = "Setting";
}
<div class="text-center">
<h2 class="display-4">@Model.Title</h2>
</div>
<form method="post" action="@Url.Action("UpdateTask", "Home", new{idTask=Model.Id, title="#title", dateIssue="#dateIssue", dateDelivery="#dateDelivery", materials="#materials"})">
<div class="row m-3">
<div class="col-8">
<input type="submit" value="Обновить" class="col-md-4 btn btn-primary" />
<input type="button" class="col-md-4 ms-auto btn btn-danger" value="Удалить" onclick="location.href='@Url.Action("DeleteTask","Home", new {id=Model.Id })'" />
</div>
</div>
<div class="row m-3">
<div class="col-4">Название:</div>
<div class="col-8"><input type="text" name="title" id="title" value="@Model.Title" /></div>
</div>
<div class="row">
<div class="col-4">Дата выдачи:</div>
<div class="col-8">@Html.TextBox("dateIssue" ,Model.DateIssue.Date.ToString("yyyy-MM-dd") ,new {type="Date"})</div>
</div>
<div class="row">
<div class="col-4">Срок сдачи:</div>
<div class="col-8">@Html.TextBox("dateDelivery" ,Model.DateDelivery.Date.ToString("yyyy-MM-dd") ,new {type="Date"})</div>
</div>
<div class="row">
<div class="col-4">Материалы:</div>
<div class="col-8">
@Html.ListBox("materials", (MultiSelectList)ViewBag.Materials)
</div>
</div>
</form>