Filter vehicle services
This commit is contained in:
@@ -5,8 +5,26 @@
|
||||
var grid = new WebGrid(Model.ServiceItems, rowsPerPage: 45);
|
||||
}
|
||||
|
||||
@section Scripts {
|
||||
<script type="text/javascript">
|
||||
var availableLogYearMonths = @Html.Raw(Json.Encode(Model.AvailableYearMonths));
|
||||
@if (Model.Year != null)
|
||||
{
|
||||
<text>var selectedYear = "@Model.Year";</text>
|
||||
<text>var selectedMonth = "@Model.Month";</text>
|
||||
}
|
||||
</script>
|
||||
}
|
||||
|
||||
@Html.Partial("_StatusMessage")
|
||||
|
||||
<div class="btn-toolbar pull-right" style="width:400px">
|
||||
@using (Html.BeginForm("Index", "VehicleService", FormMethod.Get, new { id = "filter", @class = "form" }))
|
||||
{
|
||||
@Html.EditorForModel()
|
||||
}
|
||||
</div>
|
||||
|
||||
<h2 id="vehicle-title"><i class="fa fa-wrench"></i> @ViewBag.Title</h2>
|
||||
|
||||
<div class="btn-toolbar pull-left">
|
||||
@@ -16,7 +34,7 @@
|
||||
|
||||
@grid.GetHtml(columns:
|
||||
grid.Columns(
|
||||
grid.Column("InvoiceDate", "Invoice Date"),
|
||||
grid.Column("InvoiceDate", "Invoice Date", item => item.InvoiceDate.ToString("d")),
|
||||
grid.Column("VehicleID", "Vehicle Id"),
|
||||
grid.Column("ServiceCenterName", "Service Center Name"),
|
||||
grid.Column("Price", "Price"),
|
||||
|
||||
Reference in New Issue
Block a user