continuo pagina delete
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
<h3>ListScan</h3>
|
||||
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col">Oggetto</th>
|
||||
<th scope="col"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if (elencoSCAN != null)
|
||||
{
|
||||
@foreach (var item in elencoSCAN)
|
||||
{
|
||||
<tr>
|
||||
<td class="d-flex justify-content-between">
|
||||
<div class="col-6">
|
||||
<div>
|
||||
<span class="small textCondensed"><b>Cod: </b></span>@item.ScanValue
|
||||
</div>
|
||||
<div>
|
||||
<span class="small textCondensed"><b>Lotto: </b></span>@item.Lotto
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<div>
|
||||
<span class="small textCondensed"><b>Art: </b></span>@item.CodArticolo
|
||||
</div>
|
||||
<div>
|
||||
<span class="small textCondensed"><b>Qty: </b></span>@Math.Round(item.Qty, 0)
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<div>
|
||||
<button class="btn btn-sm btn-danger">
|
||||
<i class="fa-solid fa-trash-can"></i>
|
||||
</button>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -0,0 +1,46 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using System.Net.Http;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Components.Authorization;
|
||||
using Microsoft.AspNetCore.Components.Forms;
|
||||
using Microsoft.AspNetCore.Components.Routing;
|
||||
using Microsoft.AspNetCore.Components.Web;
|
||||
using Microsoft.AspNetCore.Components.Web.Virtualization;
|
||||
using Microsoft.JSInterop;
|
||||
using MP.INVE;
|
||||
using MP.INVE.Shared;
|
||||
using MP.INVE.Components;
|
||||
using MP.Data.DatabaseModels;
|
||||
using MP.INVE.Data;
|
||||
|
||||
namespace MP.INVE.Components
|
||||
{
|
||||
public partial class ListScan
|
||||
{
|
||||
[Inject]
|
||||
MiDataService MIService { get; set; } = null!;
|
||||
[Inject]
|
||||
IJSRuntime JSRuntime { get; set; } = null!;
|
||||
[Parameter]
|
||||
public string lastScan { get; set; } = "";
|
||||
[Parameter]
|
||||
public string userScan { get; set; } = null!;
|
||||
[Parameter]
|
||||
public int sessID { get; set; } = 0;
|
||||
[Parameter]
|
||||
public string magID { get; set; } = "";
|
||||
protected string rawScan { get; set; } = null!;
|
||||
|
||||
List<ScanDataModel>? elencoSCAN;
|
||||
protected override async Task OnParametersSetAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -12,14 +12,14 @@
|
||||
{
|
||||
|
||||
<ul class="p-0">
|
||||
<li class="list-group-item">
|
||||
<li class="list-group-item p-0">
|
||||
Lotto:
|
||||
<div class="input-group input-group-sm">
|
||||
<input class="form-control" value="@lottoScan" disabled />
|
||||
<span class="input-group-text" id="basic-addon1">@tipo</span>
|
||||
</div>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<li class="list-group-item p-0">
|
||||
Articolo:
|
||||
<div class="input-group input-group-sm">
|
||||
<input class="form-control @reqArtMod" @bind-value="@articoloScan" type="text" />
|
||||
@@ -31,7 +31,7 @@
|
||||
}
|
||||
</div>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<li class="list-group-item p-0">
|
||||
Quantità:
|
||||
<div class="input-group input-group-sm">
|
||||
@if (currLottoInterno != null || currLottoEsterno != null)
|
||||
@@ -50,14 +50,14 @@
|
||||
}
|
||||
</div>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<li class="list-group-item p-0">
|
||||
Note:
|
||||
<div class="input-group input-group-sm">
|
||||
<input class="form-control " @bind-value="@noteScan" type="text" />
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="btn-group col-12 mb-2" role="group">
|
||||
<div class="btn-group col-12 py-1" role="group">
|
||||
@if (articoloScan != "" && quantitaScan != 0 && canSave)
|
||||
{
|
||||
<button type="button" class="btn btn-success col-6" @onclick="()=>insertScan()">Conferma</button>
|
||||
@@ -65,19 +65,19 @@
|
||||
}
|
||||
else if (articoloScan == "" && quantitaScan != 0)
|
||||
{
|
||||
<div class="alert bg-warning col-12">Dati mancanti: Codice articolo</div>
|
||||
<div class="alert bg-warning col-12 py-1">Dati mancanti: Codice articolo</div>
|
||||
}
|
||||
else if (quantitaScan == 0 && articoloScan != "")
|
||||
{
|
||||
<div class="alert bg-warning col-12">Dati mancanti: Quantità a "0"</div>
|
||||
<div class="alert bg-warning col-12 py-1">Dati mancanti: Quantità a "0"</div>
|
||||
}
|
||||
else if (isKnown)
|
||||
{
|
||||
<div class="alert bg-warning col-12">Codice già scansionato per la sessione corrente</div>
|
||||
<div class="alert bg-warning col-12 py-1">Codice già scansionato per la sessione corrente</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="alert bg-warning col-12">Dati mancanti: Codice articolo e Quantità </div>
|
||||
<div class="alert bg-warning col-12 py-1">Dati mancanti: Codice articolo e Quantità </div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
|
||||
@@ -26,20 +26,20 @@ namespace MP.INVE.Components
|
||||
{
|
||||
[Inject]
|
||||
private MiDataService MIService { get; set; } = null!;
|
||||
[Inject]
|
||||
public IJSRuntime JSRuntime { get; set; } = null!;
|
||||
[Inject]
|
||||
public NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
[Parameter]
|
||||
public string lastScan { get; set; } = "";
|
||||
//[Parameter]
|
||||
//public EventCallback<AnagUdcModel> udcSend { get; set; }
|
||||
[Parameter]
|
||||
public string userScan { get; set; } = null!;
|
||||
[Parameter]
|
||||
public int sessID { get; set; } = 0;
|
||||
[Parameter]
|
||||
public string magID { get; set; } = "";
|
||||
[Inject]
|
||||
public IJSRuntime JSRuntime { get; set; } = null!;
|
||||
[Inject]
|
||||
public NavigationManager NavManager { get; set; } = null!;
|
||||
|
||||
private string tipo { get; set; } = "";
|
||||
private string canMod = "false";
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<RootNamespace>MP.INVE</RootNamespace>
|
||||
<Version>6.16.2212.1318</Version>
|
||||
<Version>6.16.2212.1409</Version>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -5,8 +5,13 @@
|
||||
</div>
|
||||
<div class="card mb-5">
|
||||
<div class="card-header py-1">
|
||||
<div class="col-12">
|
||||
Last scan: <b>@rawScan</b>
|
||||
<div class="d-flex justify-content-between">
|
||||
<div>
|
||||
Last scan: <b>@rawScan</b>
|
||||
</div>
|
||||
<div>
|
||||
#:<b>@nScansioniTot</b>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body py-0">
|
||||
@@ -23,9 +28,7 @@
|
||||
<div>
|
||||
S.<b>@sessionId</b> | @descr
|
||||
</div>
|
||||
<div>
|
||||
#:<b>@nScansioniTot</b>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
@magInv
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
@page "/DeleteScan"
|
||||
|
||||
<h3>DeleteScan</h3>
|
||||
|
||||
<CodeScan lastRawScan="saveScan"></CodeScan>
|
||||
<ListScan lastScan="@rawScan" sessID="@sessionId" magID="@magazzinoId" userScan="@idOpr"></ListScan>
|
||||
@@ -0,0 +1,56 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Components;
|
||||
using System.Net.Http;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Components.Authorization;
|
||||
using Microsoft.AspNetCore.Components.Forms;
|
||||
using Microsoft.AspNetCore.Components.Routing;
|
||||
using Microsoft.AspNetCore.Components.Web;
|
||||
using Microsoft.AspNetCore.Components.Web.Virtualization;
|
||||
using Microsoft.JSInterop;
|
||||
using MP.INVE;
|
||||
using MP.INVE.Shared;
|
||||
using MP.INVE.Components;
|
||||
using MP.Data.DatabaseModels;
|
||||
using MP.INVE.Data;
|
||||
using Microsoft.AspNetCore.WebUtilities;
|
||||
|
||||
namespace MP.INVE.Pages
|
||||
{
|
||||
public partial class DeleteScan
|
||||
{
|
||||
[Inject]
|
||||
MiDataService MIService { get; set; } = null!;
|
||||
[Inject]
|
||||
NavigationManager NavManager { get; set; } = null!;
|
||||
protected void saveScan(string newScan)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(newScan))
|
||||
{
|
||||
rawScan = newScan;
|
||||
}
|
||||
}
|
||||
protected async Task deleteScan(ScanDataModel scan)
|
||||
{
|
||||
await MIService.deleteScansione(scan);
|
||||
}
|
||||
protected string rawScan { get; set; } = null!;
|
||||
protected string idOpr { get; set; } = null!;
|
||||
protected int sessionId { get; set; } = 0;
|
||||
protected string magazzinoId { get; set; } = "";
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
var uri = NavManager.ToAbsoluteUri(NavManager.Uri);
|
||||
if (QueryHelpers.ParseQuery(uri.Query).TryGetValue("idOpr", out var _matrOpr) && QueryHelpers.ParseQuery(uri.Query).TryGetValue("idSess", out var _inveSessionId) && QueryHelpers.ParseQuery(uri.Query).TryGetValue("codMag", out var _idMag))
|
||||
{
|
||||
idOpr = _matrOpr;
|
||||
sessionId = int.Parse(_inveSessionId);
|
||||
magazzinoId = _idMag;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3,3 +3,6 @@
|
||||
<h3>Invio</h3>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
<td>
|
||||
<div>
|
||||
<button class="btn btn-sm btn-danger" @onclick="()=>deleteScan(item)">
|
||||
-
|
||||
<i class="fa-solid fa-trash-can"></i>
|
||||
</button>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>Modulo MAPOINVE </i>
|
||||
<h4>Versione: 6.16.2212.1318</h4>
|
||||
<h4>Versione: 6.16.2212.1409</h4>
|
||||
<br /> Note di rilascio:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
6.16.2212.1318
|
||||
6.16.2212.1409
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>6.16.2212.1318</version>
|
||||
<version>6.16.2212.1409</version>
|
||||
<url>https://nexus.steamware.net/repository/SWS/MP-INVE/stable/LAST/MP.INVE.zip</url>
|
||||
<changelog>https://nexus.steamware.net/repository/SWS/MP-INVE/stable/LAST/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
Reference in New Issue
Block a user