98 lines
2.6 KiB
Plaintext
98 lines
2.6 KiB
Plaintext
@using MileageTraker.Web.Utility
|
|
@model IEnumerable<MileageTraker.Web.Models.Vehicle>
|
|
|
|
@{
|
|
ViewBag.Title = "Vehicles";
|
|
}
|
|
|
|
@section Styles {
|
|
<link href="@Url.Content("~/Content/VehicleColors.css")" rel="stylesheet" type="text/css" />
|
|
}
|
|
|
|
<h2 id="vehicle-title">@ViewBag.Title</h2>
|
|
|
|
<div class="btn-toolbar">
|
|
@Html.ActionLink("Add another vehicle", "Create", null, new{@class="btn"})
|
|
@Html.ActionLink("Export", "Export", null, new { @class = "btn" })
|
|
</div>
|
|
<table class="table table-striped table-bordered table-hover table-condensed">
|
|
<tr>
|
|
<th>
|
|
Key
|
|
</th>
|
|
<th>
|
|
EthraId
|
|
</th>
|
|
<th>
|
|
Model Yr
|
|
</th>
|
|
<th>
|
|
Make
|
|
</th>
|
|
<th>
|
|
Model
|
|
</th>
|
|
<th>
|
|
Type
|
|
</th>
|
|
<th>
|
|
TagNumber
|
|
</th>
|
|
<th>
|
|
Prog
|
|
</th>
|
|
<th>
|
|
Assigned
|
|
</th>
|
|
<th>
|
|
ODO
|
|
</th>
|
|
<th></th>
|
|
</tr>
|
|
|
|
@foreach (var item in Model) {
|
|
<tr>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.Key)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.VehicleId)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.ModelYear)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.Make)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.CarModel)
|
|
</td>
|
|
<td class="@item.Color">
|
|
@Html.DisplayTextFor(m => item.Type)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.TagNumber)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.Prog)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.Assigned) @if(!string.IsNullOrEmpty(item.Notes)) {
|
|
<small class="muted"><em>@Html.DisplayTextFor(m => item.Notes)</em></small>
|
|
}
|
|
</td>
|
|
<td>
|
|
@Html.DisplayTextFor(m => item.CurrentOdometer)
|
|
</td>
|
|
<td>
|
|
@(new MvcHtmlString("<div class='btn-group'>")
|
|
.Concat(Html.ActionLink("Edit", "Edit", new { id = item.VehicleId }, new { @class = "btn btn-mini" }))
|
|
.Concat(Html.ActionLink("Details", "Details", new { id = item.VehicleId }, new { @class = "btn btn-mini" }))
|
|
//.Concat(Html.ActionLink("New log", "Create", new { id = item.VehicleId }, new { @class = "btn btn-mini" }))
|
|
.Concat("</div>"))
|
|
</td>
|
|
</tr>
|
|
}
|
|
|
|
</table>
|