@using PowderCoating.Web.Controllers @model List @{ ViewData["Title"] = "Jobs Board"; bool showTerminal = ViewBag.ShowTerminal == true; int totalTerminal = (int)(ViewBag.TotalTerminal ?? 0); } @section Styles { }
@* Toolbar *@ @{ var _totalOnFloor = Model.Sum(c => c.Jobs.Count); var _hotCount = Model.Sum(c => c.Jobs.Count(j => j.IsOverdue)); }
@* Left: view switch + live stats *@
@_totalOnFloor job@(_totalOnFloor == 1 ? "" : "s") on floor @if (_hotCount > 0) { · @_hotCount overdue }
@* Right: actions *@
@if (showTerminal) { Hide Completed } else if (totalTerminal > 0) { Completed (@totalTerminal) } else { Completed } @* Column visibility dropdown *@ New Job
@* Board columns *@
@foreach (var col in Model) { var isOvenPhase = col.DisplayName is "In Oven" or "Coating" or "Curing";
@col.DisplayName @col.Jobs.Count
@if (isOvenPhase && col.Jobs.Count > 0) {
@col.Jobs.Count ACTIVE
}
}
@* Toast for move feedback *@
@section Scripts { }