Upload project.

This commit is contained in:
StevenJW
2020-06-07 22:36:12 +01:00
parent 0df30b8f36
commit 5829fb5504
170 changed files with 31989 additions and 0 deletions

View File

@@ -0,0 +1,50 @@
@model ThAmCo.Events.Data.Staff
@{
ViewData["Title"] = "Create";
}
<h2>Create</h2>
<h4>Staff</h4>
<hr />
<div class="row">
<div class="col-md-4">
<form asp-action="Create">
<div asp-validation-summary="ModelOnly" class="text-danger"></div>
<div class="form-group">
<label asp-for="Surname" class="control-label"></label>
<input asp-for="Surname" class="form-control" />
<span asp-validation-for="Surname" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="FirstName" class="control-label"></label>
<input asp-for="FirstName" class="form-control" />
<span asp-validation-for="FirstName" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="Email" class="control-label"></label>
<input asp-for="Email" class="form-control" />
<span asp-validation-for="Email" class="text-danger"></span>
</div>
<div class="form-group">
<div class="checkbox">
<label>
<input asp-for="FirstAid" /> @Html.DisplayNameFor(model => model.FirstAid)
</label>
</div>
</div>
<div class="form-group">
<input type="submit" value="Create" class="btn btn-default" />
</div>
</form>
</div>
</div>
<div>
<a asp-action="Index">Back to List</a>
</div>
@section Scripts {
@{await Html.RenderPartialAsync("_ValidationScriptsPartial");}
}

View File

@@ -0,0 +1,45 @@
@model ThAmCo.Events.Data.Staff
@{
ViewData["Title"] = "Delete";
}
<h2>Delete</h2>
<h3>Are you sure you want to delete this?</h3>
<div>
<h4>Staff</h4>
<hr />
<dl class="dl-horizontal">
<dt>
@Html.DisplayNameFor(model => model.Surname)
</dt>
<dd>
@Html.DisplayFor(model => model.Surname)
</dd>
<dt>
@Html.DisplayNameFor(model => model.FirstName)
</dt>
<dd>
@Html.DisplayFor(model => model.FirstName)
</dd>
<dt>
@Html.DisplayNameFor(model => model.Email)
</dt>
<dd>
@Html.DisplayFor(model => model.Email)
</dd>
<dt>
@Html.DisplayNameFor(model => model.FirstAid)
</dt>
<dd>
@Html.DisplayFor(model => model.FirstAid)
</dd>
</dl>
<form asp-action="Delete">
<input type="hidden" asp-for="Id" />
<input type="submit" value="Delete" class="btn btn-default" /> |
<a asp-action="Index">Back to List</a>
</form>
</div>

View File

@@ -0,0 +1,81 @@
@model ThAmCo.Events.Data.Staff
@{
ViewData["Title"] = "Details";
}
<h2>Details</h2>
<div>
<h4>Staff</h4>
<hr />
<dl class="dl-horizontal">
<dt>
@Html.DisplayNameFor(model => model.Surname)
</dt>
<dd>
@Html.DisplayFor(model => model.Surname)
</dd>
<dt>
@Html.DisplayNameFor(model => model.FirstName)
</dt>
<dd>
@Html.DisplayFor(model => model.FirstName)
</dd>
<dt>
@Html.DisplayNameFor(model => model.Email)
</dt>
<dd>
@Html.DisplayFor(model => model.Email)
</dd>
<dt>
@Html.DisplayNameFor(model => model.FirstAid)
</dt>
<dd>
@Html.DisplayFor(model => model.FirstAid)
</dd>
</dl>
</div>
<div>
<a asp-action="Edit" asp-route-id="@Model.Id">Edit</a> |
<a asp-action="Index">Back to List</a>
</div>
<table class="table">
<thead>
<tr>
<th>
@Html.DisplayNameFor(model => model.Staffings.FirstOrDefault().Event.Title)
</th>
<th>
@Html.DisplayNameFor(model => model.Staffings.FirstOrDefault().Event.Date)
</th>
<th>
@Html.DisplayNameFor(model => model.Staffings.FirstOrDefault().Event.Duration)
</th>
<th>
@Html.DisplayNameFor(model => model.Staffings.FirstOrDefault().Event.TypeId)
</th>
<th></th>
</tr>
</thead>
<tbody>
@foreach (var item in Model.Staffings)
{
<tr>
<td>
@Html.DisplayFor(modelItem => item.Event.Title)
</td>
<td>
@Html.DisplayFor(modelItem => item.Event.Date)
</td>
<td>
@Html.DisplayFor(modelItem => item.Event.Duration)
</td>
<td>
@Html.DisplayFor(modelItem => item.Event.TypeId)
</td>
</tr>
}
</tbody>
</table>

View File

@@ -0,0 +1,51 @@
@model ThAmCo.Events.Data.Staff
@{
ViewData["Title"] = "Edit";
}
<h2>Edit</h2>
<h4>Staff</h4>
<hr />
<div class="row">
<div class="col-md-4">
<form asp-action="Edit">
<div asp-validation-summary="ModelOnly" class="text-danger"></div>
<input type="hidden" asp-for="Id" />
<div class="form-group">
<label asp-for="Surname" class="control-label"></label>
<input asp-for="Surname" class="form-control" />
<span asp-validation-for="Surname" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="FirstName" class="control-label"></label>
<input asp-for="FirstName" class="form-control" />
<span asp-validation-for="FirstName" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="Email" class="control-label"></label>
<input asp-for="Email" class="form-control" />
<span asp-validation-for="Email" class="text-danger"></span>
</div>
<div class="form-group">
<div class="checkbox">
<label>
<input asp-for="FirstAid" /> @Html.DisplayNameFor(model => model.FirstAid)
</label>
</div>
</div>
<div class="form-group">
<input type="submit" value="Save" class="btn btn-default" />
</div>
</form>
</div>
</div>
<div>
<a asp-action="Index">Back to List</a>
</div>
@section Scripts {
@{await Html.RenderPartialAsync("_ValidationScriptsPartial");}
}

View File

@@ -0,0 +1,53 @@
@model IEnumerable<ThAmCo.Events.Data.Staff>
@{
ViewData["Title"] = "Index";
}
<h2>Index</h2>
<p>
<a asp-action="Create">Create New</a>
</p>
<table class="table">
<thead>
<tr>
<th>
@Html.DisplayNameFor(model => model.Surname)
</th>
<th>
@Html.DisplayNameFor(model => model.FirstName)
</th>
<th>
@Html.DisplayNameFor(model => model.Email)
</th>
<th>
@Html.DisplayNameFor(model => model.FirstAid)
</th>
<th></th>
</tr>
</thead>
<tbody>
@foreach (var item in Model) {
<tr>
<td>
@Html.DisplayFor(modelItem => item.Surname)
</td>
<td>
@Html.DisplayFor(modelItem => item.FirstName)
</td>
<td>
@Html.DisplayFor(modelItem => item.Email)
</td>
<td>
@Html.DisplayFor(modelItem => item.FirstAid)
</td>
<td>
<a asp-action="Edit" asp-route-id="@item.Id">Edit</a> |
<a asp-action="Details" asp-route-id="@item.Id">Details</a> |
<a asp-action="Delete" asp-route-id="@item.Id">Delete</a>
</td>
</tr>
}
</tbody>
</table>