Parziali su lista giri

This commit is contained in:
Marco Audiffredi 2024-07-25 15:50:37 +02:00
parent 07a4e5e3fb
commit 30be1d4a66
2 changed files with 22 additions and 107 deletions

View File

@ -48,7 +48,7 @@ namespace SoftwayWeb.Models
public int? DestinazioniFatte { get; set; }
public int? DestinazioniTutte { get; set; }
public int? DestinazioniModificate { get; set; }
public int? parzialeBanSca { get; set; }
}
}

View File

@ -10,13 +10,7 @@
Layout = "~/Views/Shared/_LayoutAreaRis.cshtml";
}
@*
@{
ViewData["Title"] = "Index";
}
<h1>Giri di consegna</h1> *@
@ -66,7 +60,6 @@
}
<br />
<br />
<br />
<!-- Striped Rows -->
<div class="card">
<h5 class="card-header">Giri di consegna</h5>
@ -78,16 +71,20 @@
<th>Autista</th>
<th>Automezzo</th>
<th><img alt="Fatti/Totali" src="@Url.Content("~/images/task-list.png")" style="width:32px;height:32px;"></th>
<th><img alt="Pallet Caricati" src="@Url.Content("~/images/pallet.png")" style="width:31px;height:31px;">Par</th>
<th><img alt="Euro" src="@Url.Content("~/images/icons8-euro-30.png")" style="width:31px;height:31px;">Par</th>
<th><img alt="Pallet Fino ad ora" src="@Url.Content("~/images/pallet.png")" style="width:31px;height:31px;">Temp</th>
<th><img alt="Euro fino ad ora" src="@Url.Content("~/images/icons8-euro-30.png")" style="width:31px;height:31px;">Temp</th>
<th><img alt="Pallet Caricati" src="@Url.Content("~/images/pallet.png")" style="width:31px;height:31px;"></th>
<th><img alt="Euro" src="@Url.Content("~/images/icons8-euro-30.png")" style="width:31px;height:31px;"></th>
<th style="width:12%;">&nbsp;</th>
</tr>
</thead>
<tbody class="table-border-bottom-0">
@foreach (var item in Model)
{
int totBancaliCaricati = 0;
if (item.BancaliCaricati!=null)
{
totBancaliCaricati = item.BancaliCaricati.Value;
}
<tr>
<td><i class="bx bxl-angular bx-sm text-danger me-3"></i> <span class="fw-medium">@Html.DisplayFor(modelItem => item.DataGiro)</span></td>
<td>@Html.DisplayFor(modelItem => item.CodAutista) - @Html.DisplayFor(modelItem => item.Autista)</td>
@ -98,46 +95,34 @@
@Html.DisplayFor(modelItem => item.DestinazioniFatte)/@Html.DisplayFor(modelItem => item.DestinazioniTutte)
</td>
<td>
@Html.DisplayFor(modelItem => item.BancaliCaricati)
<span style="color:blue;">@totBancaliCaricati</span>/<span style="color:green;">@Html.DisplayFor(modelItem => item.parzialeBanRec)</span>/<span style="color:brown;">@Html.DisplayFor(modelItem => item.parzialeBanSca)</span>
</td>
<td>
@Html.DisplayFor(modelItem => item.ImportoDaRecuperare)
</td>
@if (item.parzialeBanRec != null && item.parzialeBanRec > 0)
@if (item.ImportoDaRecuperare != null && item.ImportoDaRecuperare > 0)
{
<td>
@Html.DisplayFor(modelItem => item.parzialeBanRec)
</td>
}
else
{
<td>&nbsp;</td>
}
@if (item.parzialeImpRec != null && item.parzialeImpRec > 0)
{
<td>
@Html.DisplayFor(modelItem => item.parzialeImpRec)
@Html.DisplayFor(modelItem => item.ImportoDaRecuperare)/@Html.DisplayFor(modelItem => item.parzialeImpRec)
</td>
}
else
{
<td>&nbsp;</td>
}
<td>
<a href="@Url.ActionLink("Index", "Destinazioni", new { id=item.SerialeGiro,
codAutista=item.CodAutista,
nomeAutista=item.Autista,
dataGiro=item.DataGiro,
codMezzo=item.CodMezzo,
desMezzo=item.Automezzo})" title="Destinazioni" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-oggetti-puntiforme-30.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("Bancali", "Giri", new { id=item.SerialeGiro })" title="Bancali" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-bancale-24.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("Chiudi", "GiriChiudi", new { id=item.SerialeGiro,nbanc=item.parzialeBanRec,imp=item.parzialeImpRec })" title="Chiudi" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-bandiera-a-scacchi-64.png")" style="width:24px;height:24px;"></a>
desMezzo=item.Automezzo})" title="Destinazioni" class="links"><img alt="Destinazioni" src="@Url.Content("~/images/icons8-oggetti-puntiforme-30.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("Bancali", "Giri", new { id=item.SerialeGiro })" title="Bancali" class="links"><img alt="Bancali" src="@Url.Content("~/images/icons8-bancale-24.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("Chiudi", "GiriChiudi", new { id=item.SerialeGiro,nbanc=item.parzialeBanRec,imp=item.parzialeImpRec })" title="Chiudi" class="links"><img alt="Chiudi" src="@Url.Content("~/images/icons8-bandiera-a-scacchi-64.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("ModificaTutteDestinazioni", "Giri", new { id = item.SerialeGiro,
codAutista = item.CodAutista,
nomeAutista = item.Autista,
codMezzo= item.CodMezzo,
nomeMezzo = item.Automezzo,
dataGiroCons = item.DataGiro@* id=item.SerialeGiro,nbanc=item.parzialeBanRec,imp=item.parzialeImpRec *@ })" title="Modifica tutte le destinazioni" class="links"><img alt="nocons" src="@Url.Content("~/images/system.png")" style="width:24px;height:24px;">
dataGiroCons = item.DataGiro@* id=item.SerialeGiro,nbanc=item.parzialeBanRec,imp=item.parzialeImpRec *@ })" title="Modifica tutte le destinazioni" class="links"><img alt="Modifica Tutte" src="@Url.Content("~/images/system.png")" style="width:24px;height:24px;">
</a>
@if (item.DestinazioniModificate != null && item.DestinazioniModificate > 0)
{
@ -156,86 +141,16 @@
</table>
</div>
</div>
<br />
<span><img alt="Bancali" src="@Url.Content("~/images/pallet.png")" style="width:24px;height:24px;"></span>
<span style="color:blue;">Bancali caricati</span> /<span style="color:green;">parziale bancali caricati</span> /<span style="color:brown;">parziale bancali scaricati</span>
<!--/ Striped Rows -->
@*<table class="table">
<thead>
<tr>
<th>Data</th>
<th>Autista</th>
<th>Automezzo</th>
<th><img alt="nocons" src="@Url.Content("~/images/pallet.png")" style="width:31px;height:31px;">Par</th>
<th><img alt="nocons" src="@Url.Content("~/images/icons8-euro-30.png")" style="width:31px;height:31px;">Par</th>
<th><img alt="nocons" src="@Url.Content("~/images/pallet.png")" style="width:31px;height:31px;">Temp</th>
<th><img alt="nocons" src="@Url.Content("~/images/icons8-euro-30.png")" style="width:31px;height:31px;">Temp</th>
<th style="width:12%;">&nbsp;</th>
</tr>
</thead>
<tbody>
@foreach (var item in Model)
{
<tr>
<td>
@Html.DisplayFor(modelItem => item.DataGiro)
</td>
<td>
@Html.DisplayFor(modelItem => item.CodAutista) - @Html.DisplayFor(modelItem => item.Autista)
</td>
<td>
@Html.DisplayFor(modelItem => item.CodMezzo) - @Html.DisplayFor(modelItem => item.Automezzo)
</td>
<td>
@Html.DisplayFor(modelItem => item.BancaliCaricati)
</td>
<td>
@Html.DisplayFor(modelItem => item.ImportoDaRecuperare)
</td>
@if (item.parzialeBanRec != null && item.parzialeBanRec > 0)
{
<td>
@Html.DisplayFor(modelItem => item.parzialeBanRec)
</td>
}
else
{
<td>&nbsp;</td>
}
@if (item.parzialeImpRec != null && item.parzialeImpRec > 0)
{
<td>
@Html.DisplayFor(modelItem => item.parzialeImpRec)
</td>
}
else
{
<td>&nbsp;</td>
}
<td>
<a href="@Url.ActionLink("Index", "Destinazioni", new { id=item.SerialeGiro,
codAutista=item.CodAutista,
nomeAutista=item.Autista,
dataGiro=item.DataGiro,
codMezzo=item.CodMezzo,
desMezzo=item.Automezzo})" title="Destinazioni" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-oggetti-puntiforme-30.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("Bancali", "Giri", new { id=item.SerialeGiro })" title="Bancali" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-bancale-24.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("Chiudi", "GiriChiudi", new { id=item.SerialeGiro,nbanc=item.parzialeBanRec,imp=item.parzialeImpRec })" title="Chiudi" class="links"><img alt="nocons" src="@Url.Content("~/images/icons8-bandiera-a-scacchi-64.png")" style="width:24px;height:24px;"></a>
<a href="@Url.ActionLink("ModificaTutteDestinazioni", "Giri", new { codAutista = item.CodAutista,
nomeAutista = item.Autista,
codMezzo= item.CodMezzo,
nomeMezzo = item.Automezzo@* id=item.SerialeGiro,nbanc=item.parzialeBanRec,imp=item.parzialeImpRec })" title="Modifica tutte le destinazioni" class="links"><img alt="nocons" src="@Url.Content("~/images/system.png")" style="width:24px;height:24px;"></a>
</td>
</tr>
}
</tbody>
</table>
<br />*@
<nav>
@Html.PagedListPager(Model, page => Url.Action("index", new { page = page, searchString = @ViewData["CurrentFilter"] }), new PagedListRenderOptions()
{