School Commit Init
This commit is contained in:
@@ -0,0 +1,68 @@
|
||||
@model IList<Lab9.Models.News>
|
||||
|
||||
<!DOCTYPE <html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>
|
||||
Admin
|
||||
</title>
|
||||
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css">
|
||||
</head>
|
||||
<body>
|
||||
<div class="container text-center">
|
||||
<h3>Welcome</h3>
|
||||
<table class="container"
|
||||
id="newsTable"
|
||||
style="
|
||||
margin: 30px;
|
||||
border: 1px solid;
|
||||
border-color: black;
|
||||
border-collapse: collapse;
|
||||
">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Title</th>
|
||||
<th>Content</th>
|
||||
<th>Category</th>
|
||||
<th>Date</th>
|
||||
<th>Producer</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach(var item in Model)
|
||||
{
|
||||
<tr>
|
||||
<td>@item.Title </td>
|
||||
<td>@item.NewsText </td>
|
||||
<td>@item.Category </td>
|
||||
<td>@item.Date.ToString("dd-MM-yyyy") </td>
|
||||
<td>@item.Producer</td>
|
||||
<td>
|
||||
<a class="btn btn-danger"
|
||||
name="deleteButton"
|
||||
href="/edit/@item.Id">
|
||||
Edit
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
<a type="button"
|
||||
class="btn btn-primary"
|
||||
name="addNewsButton"
|
||||
href="/add"
|
||||
style="margin: 30px">
|
||||
Add news
|
||||
</a>
|
||||
<a type="button"
|
||||
class="btn btn-dark"
|
||||
name="logoutButton"
|
||||
href="/logout"
|
||||
style="margin: 30px">
|
||||
Log out
|
||||
</a>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user