егор начало работы с веб сайтом (вроде шаблон готов)

This commit is contained in:
GokaPek 2024-04-28 16:30:27 +04:00
parent e0ce7e52cb
commit 599e7ee20a
8 changed files with 346 additions and 3 deletions

View File

@ -19,6 +19,35 @@ namespace UniversityClientApp.Controllers
}
public IActionResult Privacy()
{
return View();
}
public IActionResult Enter()
{
return View();
}
public IActionResult Disciplines()
{
return View();
}
public IActionResult Statements()
{
return View();
}
public IActionResult Teachers()
{
return View();
}
public IActionResult Report() {
return View();
}
public IActionResult Register()
{
return View();
}

View File

@ -0,0 +1,68 @@
@{
ViewData["Title"] = "Manage Disciplines";
}
<div class="text-center">
<h2 class="display-4">@ViewData["Title"]</h2>
</div>
<form method="post">
<div class="row">
<div class="col-4">Name:</div>
<div class="col-8">
<input type="text" name="name" id="name" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-4">Description:</div>
<div class="col-8">
<textarea name="description" id="description" class="form-control"></textarea>
</div>
</div>
<div class="row">
<div class="col-4">Students:</div>
<div class="col-8">
<select id="students" name="students" class="form-control" multiple asp-items="ViewBag.Students"></select>
</div>
</div>
<div class="row">
<div class="col-8"></div>
<div class="col-4">
<input type="submit" value="Create Discipline" class="btn btn-primary" />
</div>
</div>
</form>
<table class="table">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
<th>Students</th>
<th>Actions</th>
</tr>
</thead>
<tbody>
@* @foreach (var discipline in Model)
{
<tr>
<td>@discipline.Name</td>
<td>@discipline.Description</td>
<td>
@foreach (var student in discipline.Students)
{
<span>@student.Name</span>
}
</td>
<td>
<a asp-action="Edit" asp-route-id="@discipline.Id" class="btn btn-warning">Edit</a>
<a asp-action="Details" asp-route-id="@discipline.Id" class="btn btn-info">Details</a>
<a asp-action="Delete" asp-route-id="@discipline.Id" class="btn btn-danger">Delete</a>
</td>
</tr>
} *@
</tbody>
</table>

View File

@ -0,0 +1,20 @@
@{
ViewData["Title"] = "Enter";
}
<div class="text-center">
<h2 class="display-4">Вход в приложение</h2>
</div>
<form method="post">
<div class="row">
<div class="col-4">Логин:</div>
<div class="col-8"><input type="text" name="login" /></div>
</div>
<div class="row">
<div class="col-4">Пароль:</div>
<div class="col-8"><input type="password" name="password" /></div>
</div>
<div class="row">
<div class="col-8"></div>
<div class="col-4"><input type="submit" value="Вход" class="btn btnprimary" /></div>
</div>
</form>

View File

@ -3,6 +3,14 @@
}
<div class="text-center">
<h1 class="display-4">Welcome</h1>
<p>Learn about <a href="https://learn.microsoft.com/aspnet/core">building Web apps with ASP.NET Core</a>.</p>
<div class="menu">
<a href="/Home/Disciplines">Disciplines</a>
<a href="/Home/Teachers">Teachers</a>
<a href="/Home/Statements">Statements</a>
<a href="/Home/Report">Report</a>
</div>
<div class="header">
<img src="" alt="Logo" class="logo">
</div>
</div>

View File

@ -0,0 +1,37 @@
@{
ViewData["Title"] = "Register";
}
<div class="text-center">
<h2 class="display-4">Регистрация</h2>
</div>
<form method="post">
<div class="row">
<div class="col-4">Логин:</div>
<div class="col-8"><input type="text" name="email" /></div>
</div>
<div class="row">
<div class="col-4">Пароль:</div>
<div class="col-8"><input type="password" name="password" /></div>
</div>
<div class="row">
<div class="col-4">Фамилия:</div>
<div class="col-8"><input type="text" name="lastName" /></div>
</div>
<div class="row">
<div class="col-4">Имя:</div>
<div class="col-8"><input type="text" name="firstName" /></div>
</div>
<div class="row">
<div class="col-4">Отчество:</div>
<div class="col-8"><input type="text" name="midleName" /></div>
</div>
<div class="row">
<div class="col-4">Телефон:</div>
<div class="col-8"><input type="text" name="phoneNumber" /></div>
</div>
<div class="row">
<div class="col-8"></div>
<div class="col-4"><input type="submit" value="Регистрация"
class="btn btn-primary" /></div>
</div>
</form>

View File

@ -0,0 +1,40 @@
@{
ViewData["Title"] = "Student List by Teacher";
}
<div class="text-center">
<h2 class="display-4">@ViewData["Title"]</h2>
</div>
<form method="post">
<div class="row">
<div class="col-4">Teachers:</div>
<div class="col-8">
<select id="teachers" name="teachers" class="form-control" multiple asp-items="ViewBag.Teachers"></select>
</div>
</div>
<div class="row">
<div class="col-4">File Format:</div>
<div class="col-8">
<select id="fileFormat" name="fileFormat" class="form-control" asp-items="ViewBag.FileFormats"></select>
</div>
</div>
<div class="row">
<div class="col-4">File Name:</div>
<div class="col-8">
<input type="text" name="fileName" id="fileName" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-4">File Location:</div>
<div class="col-8">
<input type="text" name="fileLocation" id="fileLocation" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-8"></div>
<div class="col-4">
<input type="submit" value="Get Student List" class="btn btn-primary" />
</div>
</div>
</form>

View File

@ -0,0 +1,63 @@
@{
ViewData["Title"] = "Manage Statement Records";
}
<div class="text-center">
<h2 class="display-4">@ViewData["Title"]</h2>
</div>
<form method="post">
<div class="row">
<div class="col-4">Title:</div>
<div class="col-8">
<input type="text" name="title" id="title" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-4">Date:</div>
<div class="col-8">
<input type="date" name="date" id="date" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-4">Teacher:</div>
<div class="col-8">
<select id="teacherId" name="teacherId" class="form-control" asp-items="ViewBag.Teachers"></select>
</div>
</div>
<div class="row">
<div class="col-8"></div>
<div class="col-4">
<input type="submit" value="Create Statement Record" class="btn btn-primary" />
</div>
</div>
</form>
<table class="table">
<thead>
<tr>
<th>Title</th>
<th>Date</th>
<th>Teacher</th>
<th>Actions</th>
</tr>
</thead>
<tbody>
@* @foreach (var record in Model)
{
<tr>
<td>@record.Title</td>
<td>@record.Date.ToString("d")</td>
<td>@record.Teacher.Name</td>
<td>
<a asp-action="Edit" asp-route-id="@record.Id" class="btn btn-warning">Edit</a>
<a asp-action="Details" asp-route-id="@record.Id" class="btn btn-info">Details</a>
<a asp-action="Delete" asp-route-id="@record.Id" class="btn btn-danger">Delete</a>
</td>
</tr>
} *@
</tbody>
</table>

View File

@ -0,0 +1,78 @@
@{
ViewData["Title"] = "Manage Teachers";
}
<div class="text-center">
<h2 class="display-4">@ViewData["Title"]</h2>
</div>
<form method="post">
<div class="row">
<div class="col-4">Name:</div>
<div class="col-8">
<input type="text" name="name" id="name" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-4">Academic Degree:</div>
<div class="col-8">
<input type="text" name="academicDegree" id="academicDegree" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-4">Position:</div>
<div class="col-8">
<input type="text" name="position" id="position" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-4">Disciplines:</div>
<div class="col-8">
<select id="disciplines" name="disciplines" class="form-control" multiple asp-items="ViewBag.Disciplines"></select>
</div>
</div>
<div class="row">
<div class="col-8"></div>
<div class="col-4">
<input type="submit" value="Create Teacher" class="btn btn-primary" />
</div>
</div>
</form>
<table class="table">
<thead>
<tr>
<th>Name</th>
<th>Academic Degree</th>
<th>Position</th>
<th>Disciplines</th>
<th>Actions</th>
</tr>
</thead>
<tbody>
@* @foreach (var teacher in Model)
{
<tr>
<td>@teacher.Name</td>
<td>@teacher.AcademicDegree</td>
<td>@teacher.Position</td>
<td>
@foreach (var discipline in teacher.Disciplines)
{
<span>@discipline.Name</span>
}
</td>
<td>
<a asp-action="Edit" asp-route-id="@teacher.Id" class="btn btn-warning">Edit</a>
<a asp-action="Details" asp-route-id="@teacher.Id" class="btn btn-info">Details</a>
<a asp-action="Delete" asp-route-id="@teacher.Id" class="btn btn-danger">Delete</a>
</td>
</tr>
} *@
</tbody>
</table>