400 lines
14 KiB
Plaintext
400 lines
14 KiB
Plaintext
@* @model IEnumerable<SoftwayWeb.Models.Destinazioni_Out> *@
|
|
@* @model SoftwayWeb.Models.Destinazioni_Out *@
|
|
@model IPagedList<SoftwayWeb.Models.Destinazioni_Out>
|
|
@using X.PagedList;
|
|
@using X.PagedList.Mvc.Core;
|
|
@using X.PagedList;
|
|
|
|
@{
|
|
ViewData["Title"] = "Lista Destinazioni";
|
|
Layout = "~/Views/Shared/_LayoutAreaRis.cshtml";
|
|
}
|
|
|
|
<h1>Lista destinazioni</h1>
|
|
|
|
<p>
|
|
<b>Data giro: @ViewBag.dataGiro</b>
|
|
<br />
|
|
<b>Autista: @ViewBag.CodAutista - @ViewBag.Autista</b>
|
|
<br />
|
|
<b>Automezzo: @ViewBag.CodMezzo - @ViewBag.Automezzo</b>
|
|
</p>
|
|
<a asp-action="Index" asp-controller="Giri" value="Torna alla lista" class="btn btn-primary">Torna alla lista</a>
|
|
<br />
|
|
<br />
|
|
<!-- Striped Rows -->
|
|
<div class="card" >
|
|
<h5 class="card-header">Lista destinazioni</h5>
|
|
<div class="table-responsive text-nowrap">
|
|
<table class="table table-striped">
|
|
<thead>
|
|
<tr>
|
|
@*<th> </th>*@
|
|
<th>S.</th>
|
|
<th>Committente</th>
|
|
<th>Sede</th>
|
|
<th>Indirizzo sede</th>
|
|
<th>Ca.</th>
|
|
<th>Tr.</th>
|
|
<th>Co.</th>
|
|
<th>Nr.Co.</th>
|
|
<th>Uo</th>
|
|
<th>Ci.</th>
|
|
<th>Note</th>
|
|
<th>Bc - Bs</th>
|
|
<th> </th>
|
|
<th> </th>
|
|
</tr>
|
|
</thead>
|
|
<tbody class="table-border-bottom-0">
|
|
@foreach (var item in Model) {
|
|
int diffBancali = 0;
|
|
string cl = string.Empty;
|
|
@if (item.ConsFatta != null)
|
|
{
|
|
|
|
@Html.HiddenFor(modelItem => item.ConsFatta.consFattaFlagCons)
|
|
|
|
@if (item.ConsFatta.consFattaFlagCons != null && item.ConsFatta.consFattaFlagCons.Contains("S"))
|
|
{
|
|
@*<img alt="cons" src="@Url.Content("~/images/Green.png")" style="width:16px;height:16px">*@
|
|
cl = "table-success";
|
|
}
|
|
else
|
|
{
|
|
cl = "table-danger";
|
|
@*<img alt="nocons" src="@Url.Content("~/images/Red.png")" style="width:16px;height:16px;">*@
|
|
}
|
|
|
|
}
|
|
else
|
|
{
|
|
@* <td>
|
|
<img alt="notyet" src="@Url.Content("~/images/yellow.png")" style="width:16px;height:16px;">
|
|
</td>*@
|
|
}
|
|
|
|
<tr class="@cl">
|
|
|
|
|
|
@* @if (item.ConsFatta != null)
|
|
{
|
|
<td >
|
|
@Html.HiddenFor(modelItem => item.ConsFatta.consFattaFlagCons)
|
|
|
|
@if (item.ConsFatta.consFattaFlagCons!=null && item.ConsFatta.consFattaFlagCons.Contains("S"))
|
|
{
|
|
<img alt="cons" src="@Url.Content("~/images/Green.png")" style="width:16px;height:16px">
|
|
}
|
|
else
|
|
{
|
|
<img alt="nocons" src="@Url.Content("~/images/Red.png")" style="width:16px;height:16px;">
|
|
}
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td>
|
|
<img alt="notyet" src="@Url.Content("~/images/yellow.png")" style="width:16px;height:16px;">
|
|
</td>
|
|
}*@
|
|
|
|
|
|
<td style="font-size:12px;"><i class="bx bxl-angular bx-sm text-danger me-3"></i>@Html.DisplayFor(modelItem => item.Seq)</td>
|
|
<td>@Html.DisplayFor(modelItem => item.Committente)</td>
|
|
<td>@*@Html.DisplayFor(modelItem => item.CodSede) - *@@Html.DisplayFor(modelItem => item.Sede)</td>
|
|
<td>@Html.DisplayFor(modelItem => item.IndirizzoSede)</td>
|
|
@if (item.Casse != null && item.Casse > 0)
|
|
{
|
|
int icasse = 0;
|
|
icasse = Convert.ToInt32(item.Casse);
|
|
<td style="font-size:12px;">
|
|
@icasse
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Trasf != null && item.Trasf > 0)
|
|
{
|
|
<td style="font-size:12px;">
|
|
@Html.DisplayFor(modelItem => item.Trasf)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Colli != null && item.Colli > 0)
|
|
{
|
|
int icolli = 0;
|
|
icolli = Convert.ToInt32(item.Colli);
|
|
<td style="font-size:12px;">
|
|
@icolli
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.num_cons != null && item.num_cons > 0)
|
|
{
|
|
<td style="font-size:12px;">
|
|
@Html.DisplayFor(modelItem => item.num_cons)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Uova != null && item.Uova > 0)
|
|
{
|
|
<td style="font-size:12px;">
|
|
@Html.DisplayFor(modelItem => item.Uova)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Cist != null && item.Cist > 0)
|
|
{
|
|
<td style="font-size:12px;">
|
|
@Html.DisplayFor(modelItem => item.Cist)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
|
|
<td style="font-size:12px;">
|
|
@Html.DisplayFor(modelItem => item.Note)
|
|
</td>
|
|
@if (item.ConsFatta != null)
|
|
{
|
|
diffBancali = item.ConsFatta.consFattaBanCar.Value - item.ConsFatta.consFattaBanSca.Value;
|
|
|
|
<td>
|
|
<a href="@Url.ActionLink("Index","Consegne", new{id = item.Brserial,
|
|
codAutista = item.CodAutista,
|
|
dataGiro = item.DataCarico,
|
|
codMezzo = item.CodAutomezzo})" class="links">@diffBancali</a>
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.ConsFatta == null)
|
|
{
|
|
<td>
|
|
@if (!string.IsNullOrEmpty(item.Prog))
|
|
{
|
|
<img alt="nocons" src="@Url.Content("~/images/warning.png")" style="width:16px;height:16px;">
|
|
}
|
|
|
|
<a href="@Url.ActionLink("EliminaDestinazione", "Destinazioni", new { serial=item.Brserial })" title="Elimina Destinazione" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-rimuovere-24.png")" style="width:16px;height:16px;"></a>
|
|
</td>
|
|
<td>
|
|
<a href="@Url.ActionLink("ModificaDestinazione", "Destinazioni", new { serial=item.Brserial })" title="Modifica Destinazione" class="links"><img alt="nocons" src="@Url.Content("~/images/system.png")" style="width:16px;height:16px;"></a>
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
<td> </td>
|
|
}
|
|
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<br />
|
|
<span style=" height: 16px;
|
|
width: 16px;
|
|
background-color: #dfc2c4;
|
|
border-radius: 50%;
|
|
display: inline-block;"></span>
|
|
<span> Consegna non effettuata</span>
|
|
<span style=" height: 16px;
|
|
width: 16px;
|
|
background-color: #c7dbd2;
|
|
border-radius: 50%;
|
|
display: inline-block;"></span>
|
|
<span> Consegna completata</span>
|
|
<span style=" height: 16px;
|
|
width: 16px;
|
|
background-color: #dee2e6;
|
|
border-radius: 50%;
|
|
display: inline-block;"></span>
|
|
<span> Consegna da effettuare</span>
|
|
<span>
|
|
<img alt="nocons" src="@Url.Content("~/images/warning.png")" style="width:16px;height:16px;">
|
|
</span>
|
|
<span> Destinazione modificata</span>
|
|
|
|
<!--/ Striped Rows -->
|
|
|
|
@*<table class="table" style="width:100%">
|
|
<thead>
|
|
<tr>
|
|
<th> </th>
|
|
<th>Seq</th>
|
|
<th>Committente</th>
|
|
<th>Sede</th>
|
|
<th>Indirizzo sede</th>
|
|
<th>Casse</th>
|
|
<th>Trasf.</th>
|
|
<th>Colli</th>
|
|
<th>Nr.Cons.</th>
|
|
<th>Uova</th>
|
|
<th>Cist</th>
|
|
<th>Note</th>
|
|
<th> </th>
|
|
<th> </th>
|
|
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach (var item in Model) {
|
|
<tr>
|
|
@if (item.ConsFatta != null)
|
|
{
|
|
<td>
|
|
@Html.HiddenFor(modelItem => item.ConsFatta.consFattaFlagCons)
|
|
|
|
@if (item.ConsFatta.consFattaFlagCons.Contains("S"))
|
|
{
|
|
<img alt="cons" src="@Url.Content("~/images/Green.png")" style="width:24px;height:24px">
|
|
}
|
|
else
|
|
{
|
|
<img alt="nocons" src="@Url.Content("~/images/Red.png")" style="width:24px;height:24px;">
|
|
}
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td>
|
|
<img alt="notyet" src="@Url.Content("~/images/yellow.png")" style="width:24px;height:24px;">
|
|
</td>
|
|
}
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.Seq)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.CodCommittente) - @Html.DisplayFor(modelItem => item.Committente)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.CodSede) - @Html.DisplayFor(modelItem => item.Sede)
|
|
</td>
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.IndirizzoSede)
|
|
</td>
|
|
@if (item.Casse != null && item.Casse>0)
|
|
{
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.Casse)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Trasf != null && item.Trasf > 0)
|
|
{
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.Trasf)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Colli != null && item.Colli > 0)
|
|
{
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.Colli)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.num_cons != null && item.num_cons > 0)
|
|
{
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.num_cons)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Uova != null && item.Uova > 0)
|
|
{
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.Uova)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
@if (item.Cist != null && item.Cist > 0)
|
|
{
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.Cist)
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
}
|
|
|
|
<td>
|
|
@Html.DisplayFor(modelItem => item.Note)
|
|
</td>
|
|
|
|
@if (item.ConsFatta == null)
|
|
{
|
|
<td>
|
|
@if (!string.IsNullOrEmpty(item.Prog))
|
|
{
|
|
<img alt="nocons" src="@Url.Content("~/images/warning.png")" style="width:24px;height:24px;">
|
|
}
|
|
|
|
<a href="@Url.ActionLink("EliminaDestinazione", "Destinazioni", new { serial=item.Brserial })" title="Elimina Destinazione" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-rimuovere-24.png")" style="width:24px;height:24px;"></a>
|
|
</td>
|
|
<td>
|
|
<a href="@Url.ActionLink("ModificaDestinazione", "Destinazioni", new { serial=item.Brserial })" title="Modifica Destinazione" class="links"><img alt="nocons" src="@Url.Content("~/images/system.png")" style="width:24px;height:24px;"></a>
|
|
</td>
|
|
}
|
|
else
|
|
{
|
|
<td> </td>
|
|
<td> </td>
|
|
}
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>*@
|
|
<br />
|
|
<nav>
|
|
@Html.PagedListPager(Model, page => Url.Action("index", new { page = page, Model/* searchString = @ViewData["CurrentFilter"] */ }), new PagedListRenderOptions()
|
|
{
|
|
ActiveLiElementClass = "active",
|
|
PageClasses = new[] { "page-link" },
|
|
LiElementClasses = new[] { "page-item" },
|
|
UlElementClasses = new[] { "pagination", "justify-content-center", "mt-3" },
|
|
LinkToNextPageFormat = "Successiva",
|
|
LinkToPreviousPageFormat = "Precedente",
|
|
MaximumPageNumbersToDisplay = 5,
|
|
DisplayLinkToPreviousPage = PagedListDisplayMode.Always,
|
|
DisplayLinkToNextPage = PagedListDisplayMode.Always
|
|
})
|
|
</nav> |