Update colorazione stato fermata
This commit is contained in:
@@ -6,19 +6,24 @@
|
||||
{
|
||||
<div class="col-12 px-1 bg-gradient py-2">
|
||||
<div class="row">
|
||||
<div class="col-4 my-2">
|
||||
@if (DayMinTot < 1440)
|
||||
{
|
||||
<button class="btn btn-success w-100" @onclick="() => AddNew()" title="Riempi periodi mancanti"><i class="fa-solid fa-plus"></i> Add New</button>
|
||||
}
|
||||
</div>
|
||||
<div class="col-4 my-2">
|
||||
@if (DayMinTot < 1440)
|
||||
{
|
||||
<button class="btn btn-secondary w-100" @onclick="() => FixMissing()" title="Riempi periodi mancanti"><i class="fa-solid fa-fill-drip"></i> Spenta</button>
|
||||
}
|
||||
</div>
|
||||
<div class="col-4 my-2">
|
||||
@if (DayMinTot < 1440)
|
||||
{
|
||||
<div class="col-3 my-2">
|
||||
<button class="btn btn-success w-100" @onclick="() => AddNew(true)" title="Inserisci produzione"><i class="fa-solid fa-plus"></i> Produzione</button>
|
||||
</div>
|
||||
<div class="col-3 my-2">
|
||||
<button class="btn btn-warning w-100" @onclick="() => AddNew(false)" title="Inserisci Fermata"><i class="fa-solid fa-plus"></i> Fermata</button>
|
||||
</div>
|
||||
<div class="col-3 my-2">
|
||||
<button class="btn btn-secondary w-100" @onclick="() => FixMissing()" title="Riempi periodi mancanti"><i class="fa-solid fa-fill-drip"></i> Spenta <i class="fa-solid fa-fill-drip"></i></button>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="col-9 my-2">
|
||||
</div>
|
||||
}
|
||||
<div class="col-3 my-2">
|
||||
<button class="btn btn-outline-light w-100" @onclick="@CloseDet"><i class="fa-solid fa-xmark"></i> Close</button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -45,43 +50,59 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@* <div class="col-12 px-1 bg-dark bg-gradient py-2">
|
||||
</div> *@
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="row">
|
||||
<div class="col-6 col-lg-3">
|
||||
<div class="form-floating">
|
||||
<input type="text" class="form-control" @bind="@EditRecord.KeyRichiesta"></input>
|
||||
<label>Commessa</label>
|
||||
@if(EditRecord.IsWork)
|
||||
{
|
||||
<div class="col-6 col-lg-3">
|
||||
<div class="form-floating">
|
||||
<input type="text" class="form-control" @bind="@EditRecord.KeyRichiesta"></input>
|
||||
<label>Commessa</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-6 col-lg-3">
|
||||
<div class="form-floating">
|
||||
<input type="text" class="form-control" @bind="@EditRecord.CodArticolo"></input>
|
||||
<label>Articolo</label>
|
||||
<div class="col-6 col-lg-3">
|
||||
<div class="form-floating">
|
||||
<input type="text" class="form-control" @bind="@EditRecord.CodArticolo"></input>
|
||||
<label>Articolo</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-4 col-lg-2 my-2">
|
||||
<div class="form-floating">
|
||||
<input type="time" class="form-control" id="floatingComm" @bind="@EditRecord.InizioStato"></input>
|
||||
<label for="floatingComm">Inizio</label>
|
||||
<div class="col-4 col-lg-2 my-2">
|
||||
<div class="form-floating">
|
||||
<input type="time" class="form-control" id="floatingComm" @bind="@EditRecord.InizioStato"></input>
|
||||
<label for="floatingComm">Inizio</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-4 col-lg-2 my-2">
|
||||
<div class="form-floating">
|
||||
<input type="number" class="form-control" id="floatingComm" @bind="@EditRecord.PzBuoni"></input>
|
||||
<label for="floatingComm">Pezzi</label>
|
||||
<div class="col-4 col-lg-2 my-2">
|
||||
<div class="form-floating">
|
||||
<input type="number" class="form-control" id="floatingComm" @bind="@EditRecord.PzBuoni"></input>
|
||||
<label for="floatingComm">Pezzi</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-4 col-lg-2 my-2">
|
||||
<div class="form-floating">
|
||||
<input type="number" class="form-control" id="floatingComm" @bind="@EditRecord.TCiclo"></input>
|
||||
<label for="floatingComm">T.Ciclo</label>
|
||||
<div class="col-4 col-lg-2 my-2">
|
||||
<div class="form-floating">
|
||||
<input type="number" class="form-control" id="floatingComm" @bind="@EditRecord.TCiclo"></input>
|
||||
<label for="floatingComm">T.Ciclo</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="col-12 col-lg-6">
|
||||
<div class="form-floating">
|
||||
<input type="text" class="form-control" @bind="@EditRecord.KeyRichiesta"></input>
|
||||
<label>Tipo Fermata</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-4 col-lg-2 my-2">
|
||||
<div class="form-floating">
|
||||
<input type="number" class="form-control" id="floatingComm" @bind="@EditRecord.MinProd"></input>
|
||||
<label for="floatingComm">Durata (min)</label>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
|
||||
<div class="col-6">
|
||||
<button class="btn btn-sm btn-success w-100" @onclick="() => DoSave()"><i class="fa-solid fa-floppy-disk"></i> Save</button>
|
||||
|
||||
@@ -45,7 +45,7 @@ namespace MP_TAB3.Components
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
protected void AddNew()
|
||||
protected void AddNew(bool isWork)
|
||||
{
|
||||
if (RecMSE != null)
|
||||
{
|
||||
@@ -63,12 +63,14 @@ namespace MP_TAB3.Components
|
||||
startPeriod = dtCurr.Date.AddHours(6);
|
||||
}
|
||||
}
|
||||
// evento da richiesta: default lavora/spenta
|
||||
int idxTipo = isWork ? 1 : 12;
|
||||
// creazione nuovo record ed aggiunta in coda agli esistenti...
|
||||
EditRecord = new InsManualiModel()
|
||||
{
|
||||
IdxMacchina = idxMacc,
|
||||
InizioStato = startPeriod,
|
||||
IdxTipoEv = 1,
|
||||
IdxTipoEv = idxTipo,
|
||||
MatrOpr = MServ.MatrOpr
|
||||
};
|
||||
}
|
||||
@@ -233,8 +235,6 @@ namespace MP_TAB3.Components
|
||||
var dayDto = ListDTO.FirstOrDefault(x => x.DataRif == reqDate.Date);
|
||||
if (dayDto != null && (ListDay != null || (reloadDay && ListPeriod != null)))
|
||||
{
|
||||
#if false
|
||||
#endif
|
||||
if (reloadDay)
|
||||
{
|
||||
// calcolo eventi giorno
|
||||
@@ -313,6 +313,7 @@ namespace MP_TAB3.Components
|
||||
DateCFF = new Dictionary<DateTime, string>();
|
||||
string cssImport = "bg-success text-light rounded-circle p-2";
|
||||
string cssOkDay = "bg-success bg-opacity-50 text-light rounded-circle p-2";
|
||||
string cssPartDay = "bg-info bg-opacity-25 text-light rounded-circle p-2";
|
||||
string cssHasData = "bg-warning text-light rounded-circle p-2";
|
||||
string cssToday = "bg-info text-dark rounded-circle p-2";
|
||||
string cssFest = "bg-danger text-warning rounded-pill2 px-0 opacity-50";
|
||||
@@ -323,32 +324,27 @@ namespace MP_TAB3.Components
|
||||
string currCss = "";
|
||||
foreach (var item in ListDTO)
|
||||
{
|
||||
currCss = item.MinProdTot == 0 ? "" : cssHasData;
|
||||
currCss = "";// item.MinProdTot == 0 ? "" : cssHasData;
|
||||
// controllo minuti dichiarati...
|
||||
if (IsTimeInfoOk(item.DataRif.Date, true))
|
||||
if (item.RatioImport == 1)
|
||||
{
|
||||
currCss = cssOkDay;
|
||||
currCss = cssImport;
|
||||
}
|
||||
else if (item.DataRif == DateTime.Today)
|
||||
{
|
||||
currCss = cssToday;
|
||||
}
|
||||
else if (item.RatioImport == 1)
|
||||
else if (IsTimeInfoOk(item.DataRif.Date, true))
|
||||
{
|
||||
currCss = cssOkDay;
|
||||
currCss = item.MinProdTot < 1440 ? cssPartDay : cssOkDay;
|
||||
}
|
||||
else
|
||||
{
|
||||
currCss = item.MinProdTot == 0 ? "" : cssHasData;
|
||||
}
|
||||
DateCheck.Add(item.DataRif, currCss);
|
||||
}
|
||||
}
|
||||
|
||||
#if false
|
||||
// verifico dati giornalieri...
|
||||
if (!IsTimeInfoOk())
|
||||
{
|
||||
// se non ok --> sposo primo e poi ricalcolo...
|
||||
//int numChange = await DoRecalcDay();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -28,7 +28,8 @@
|
||||
<div class="list-group">
|
||||
@foreach (var item in MenuItems)
|
||||
{
|
||||
if (IsManual && item.ordine > 20)
|
||||
@* if (IsManual && item.ordine > 20) *@
|
||||
if (IsManual && item.ordine > 40)
|
||||
{
|
||||
<button class="p-2 list-group-item list-group-item-action @cssActive(item.NavigateUrl) link-underline link-underline-opacity-0 link-underline-opacity-75-hover disabled" data-bs-dismiss="offcanvas"><i class="fa fa-lg @item.icona pe-2"></i> @item.Testo</button>
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<Version>6.16.2504.216</Version>
|
||||
<Version>6.16.2504.217</Version>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<RootNamespace>MP_TAB3</RootNamespace>
|
||||
</PropertyGroup>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>Modulo MAPOSPEC </i>
|
||||
<h4>Versione: 6.16.2504.216</h4>
|
||||
<h4>Versione: 6.16.2504.217</h4>
|
||||
<br /> Note di rilascio:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
6.16.2504.216
|
||||
6.16.2504.217
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>6.16.2504.216</version>
|
||||
<version>6.16.2504.217</version>
|
||||
<url>https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/MP-TAB3.zip</url>
|
||||
<changelog>https://nexus.steamware.net/repository/SWS/MP-TAB3/stable/LAST/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
@@ -47,6 +47,12 @@ namespace MP.Data.DbModels
|
||||
/// </summary>
|
||||
public DateTime? Imported { get; set; } = null;
|
||||
|
||||
[NotMapped]
|
||||
public bool IsWork
|
||||
{
|
||||
get => IdxTipoEv == 1;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Navigazione oggetto Machine
|
||||
|
||||
Reference in New Issue
Block a user