demo20230512/Areas/admin/Views/LCA/Index.cshtml

73 lines
2.9 KiB
Plaintext
Raw Normal View History

2023-05-12 10:20:28 +08:00
@using Weee.Models.ExtensionMethods
@using PagedList.Mvc
@using PagedList
@using Resources
@model IEnumerable<Weee.Models.LCA>
@{
ViewBag.Title = Resource.StaticLabelLCAList;
Layout = "~/Areas/admin/Views/Shared/_AdminLayout.cshtml";
}
<div class="col-md-12">
<div class="row docs-row">
<div class="col-xs-5">
<h2 class="docs-h2">@Resource.StaticLabelLCAList</h2>
</div>
<div class="col-xs-7">
@using (Html.BeginForm("Index", "LCA", FormMethod.Get, new { @class = "form-horizontal" }))
{
<div class="form-group">
<div class="col-sm-1"></div>
<div class="col-sm-8">
<input name="companyName" type="text" class="form-control" />
</div>
<div class="col-sm-3">
<input type="submit" value="@Resource.StaticLabelGlobal_Search" class="btn btn-default" />
@Html.ActionLink(Resource.StaticLabelGlobal_Cancel, "index", new { }, new { @class = "btn btn-default" })
</div>
</div>
}
</div>
</div>
<div>
<table class="table text-center">
<tr>
<th>@Html.DisplayNameFor(model=>model.Description)</th>
<th>@Html.DisplayNameFor(model => model.Owner)</th>
<th>@Html.DisplayNameFor(model => model.VerifyBy)</th>
<th>@Html.DisplayNameFor(model => model.CreatedDate)</th>
<th>@Html.DisplayNameFor(model => model.StartDate)</th>
<th>@Html.DisplayNameFor(model => model.EndDate)</th>
<th>@Html.DisplayNameFor(model => model.DeadLine)</th>
<th>@Html.DisplayNameFor(model=>model.LCAType)</th>
<th>@Html.DisplayNameFor(model => model.Status)</th>
<th></th>
</tr>
@foreach (var item in Model)
{
<tr>
<td>@item.Description</td>
<td>@(item.Owner == null ? "" : item.Owner.Name)</td>
<td>@(item.VerifyBy == null ? "" : item.VerifyBy.Name)</td>
<td>@item.CreatedDate.ToShortDateString()</td>
<td>@item.StartDate.ToShortDateString()</td>
<td>@item.EndDate.ToShortDateString()</td>
<td>@(item.DeadLine.HasValue ? item.DeadLine.Value.ToShortDateString() : "")</td>
<td>@item.LCATypeDisplayName</td>
<td>@item.Status.DisplayString()</td>
<td>
@Html.ActionLink(Resource.StaticLabelGlobal_Detail, "Details", new { id = item.ID }, new { @class = "btn btn-xs btn-default" })
</td>
</tr>
}
</table>
</div>
<div class="text-center">
@Html.PagedListPager((IPagedList)Model, page => Url.Action("index", new { page, companyName = ViewBag.CompanyName }))
</div>
</div>
<div class="col-md-1"></div>