rinominato componente x semilavorati
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="cmp_prtSemilav.ascx.cs" Inherits="MP_MAG.WebUserControls.cmp_prtSemilav" %>
|
||||
<%@ Register Src="~/WebUserControls/cmp_barcode.ascx" TagPrefix="uc1" TagName="cmp_barcode" %>
|
||||
<%@ Register Src="~/WebUserControls/cmp_semiLavLottiOut.ascx" TagPrefix="uc1" TagName="cmp_semiLavLottiOut" %>
|
||||
<%@ Register Src="~/WebUserControls/cmp_semiLavLottiIn.ascx" TagPrefix="uc1" TagName="cmp_semiLavLottiIn" %>
|
||||
<%@ Register Src="~/WebUserControls/cmp_LottiIn.ascx" TagPrefix="uc1" TagName="cmp_LottiIn" %>
|
||||
<%@ Register Src="~/WebUserControls/cmp_semiLavArtOut.ascx" TagPrefix="uc1" TagName="cmp_semiLavArtOut" %>
|
||||
<%@ Register Src="~/WebUserControls/cmp_printLottoOUT.ascx" TagPrefix="uc1" TagName="cmp_printLottoOUT" %>
|
||||
<%@ Register Src="~/WebUserControls/cmp_creaLottoOUT.ascx" TagPrefix="uc1" TagName="cmp_creaLottoOUT" %>
|
||||
@@ -15,8 +15,12 @@
|
||||
<asp:HiddenField runat="server" ID="hfLastBCode" />
|
||||
<asp:HiddenField runat="server" ID="hfLastValidBCode" />
|
||||
<div class="row m-0">
|
||||
<div class="col-12 text-center border border-primary table-primary mb-2 py-2">
|
||||
<h4>
|
||||
<asp:Label runat="server" ID="lblTipoStampa" /></h4>
|
||||
</div>
|
||||
<div class="col-4 text-left">
|
||||
<uc1:cmp_semiLavLottiIn runat="server" ID="cmp_semiLavLottiIn" />
|
||||
<uc1:cmp_LottiIn runat="server" ID="cmp_LottiIn" CodStato="MP" />
|
||||
<hr />
|
||||
<uc1:cmp_ArtRich runat="server" ID="cmp_ArtRich" />
|
||||
</div>
|
||||
|
||||
@@ -12,6 +12,20 @@ namespace MP_MAG.WebUserControls
|
||||
{
|
||||
public partial class cmp_prtSemilav : BaseUserControl
|
||||
{
|
||||
/// <summary>
|
||||
/// Tipo Stampa
|
||||
/// </summary>
|
||||
public string tipoStampa
|
||||
{
|
||||
get
|
||||
{
|
||||
return lblTipoStampa.Text;
|
||||
}
|
||||
set
|
||||
{
|
||||
lblTipoStampa.Text = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Comando ULTIMO barcode letto
|
||||
/// </summary>
|
||||
@@ -115,11 +129,11 @@ namespace MP_MAG.WebUserControls
|
||||
{
|
||||
get
|
||||
{
|
||||
return cmp_semiLavLottiIn.lottiSel;
|
||||
return cmp_LottiIn.lottiSel;
|
||||
}
|
||||
set
|
||||
{
|
||||
cmp_semiLavLottiIn.lottiSel = value;
|
||||
cmp_LottiIn.lottiSel = value;
|
||||
cmp_semiLavLottiOut.lottiSel = value;
|
||||
cmp_semiLavArtOut.lottiSel = value;
|
||||
}
|
||||
@@ -141,7 +155,7 @@ namespace MP_MAG.WebUserControls
|
||||
cmp_barcode.eh_doRefresh += Cmp_barcode_eh_doRefresh;
|
||||
// eventi reset lotti IN
|
||||
cmp_barcode.eh_doReset += Cmp_barcode_eh_doReset;
|
||||
cmp_semiLavLottiIn.eh_doReset += Cmp_semiLavLottiIn_eh_doReset;
|
||||
cmp_LottiIn.eh_doReset += cmp_LottiIn_eh_doReset;
|
||||
// selezione articoli
|
||||
cmp_semiLavArtOut.eh_doRefresh += Cmp_semiLavArtOut_eh_doRefresh;
|
||||
cmp_semiLavArtOut.eh_doReset += Cmp_semiLavArtOut_eh_doReset;
|
||||
@@ -166,7 +180,7 @@ namespace MP_MAG.WebUserControls
|
||||
|
||||
private void Cmp_creaLottoOUT_eh_doRefresh(object sender, EventArgs e)
|
||||
{
|
||||
MagDataLayer.man.taEL.insertQuery(tipoLotto, cmp_semiLavArtOut.CodArtSel, codStato, origine, "", cmp_creaLottoOUT.qtaOrig, cmp_creaLottoOUT.numUdc, RifExt, cmp_semiLavLottiIn.elLotti);
|
||||
MagDataLayer.man.taEL.insertQuery(tipoLotto, cmp_semiLavArtOut.CodArtSel, codStato, origine, "", cmp_creaLottoOUT.qtaOrig, cmp_creaLottoOUT.numUdc, RifExt, cmp_LottiIn.elLotti);
|
||||
cmp_semiLavLottiOut.doUpdate();
|
||||
}
|
||||
|
||||
@@ -221,7 +235,7 @@ namespace MP_MAG.WebUserControls
|
||||
//if (!showPrint) cmp_semiLavArtOut.deSelect();
|
||||
}
|
||||
|
||||
private void Cmp_semiLavLottiIn_eh_doReset(object sender, EventArgs e)
|
||||
private void cmp_LottiIn_eh_doReset(object sender, EventArgs e)
|
||||
{
|
||||
Response.Redirect(user_std.pagCorrente);
|
||||
}
|
||||
|
||||
+11
-2
@@ -69,13 +69,22 @@ namespace MP_MAG.WebUserControls
|
||||
protected global::System.Web.UI.WebControls.HiddenField hfLastValidBCode;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo cmp_semiLavLottiIn.
|
||||
/// Controllo lblTipoStampa.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::MP_MAG.WebUserControls.cmp_semiLavLottiIn cmp_semiLavLottiIn;
|
||||
protected global::System.Web.UI.WebControls.Label lblTipoStampa;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo cmp_LottiIn.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::MP_MAG.WebUserControls.cmp_LottiIn cmp_LottiIn;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo cmp_ArtRich.
|
||||
|
||||
@@ -1,95 +0,0 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="cmp_semiLavLottiIn.ascx.cs" Inherits="MP_MAG.WebUserControls.cmp_semiLavLottiIn" %>
|
||||
|
||||
<div class="card border border-info rounded">
|
||||
<div class="card-header bg-info text-light">
|
||||
<div class="row">
|
||||
<div class="col-10">
|
||||
<h5>Elenco Lotti IN</h5>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<asp:LinkButton runat="server" ID="lbtResetLottoIn" CssClass="btn btn-dark" OnClick="lbtResetLottoIn_Click"><i class="fas fa-sync-alt"></i></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body small px-0 py-1">
|
||||
<asp:GridView ID="grViewLottoIn" runat="server" AutoGenerateColumns="False" DataKeyNames="Lotto" DataSourceID="odsLottiIn" CssClass="table table-striped table-condensed table-sm small" AllowPaging="True">
|
||||
<HeaderStyle CssClass="default" />
|
||||
<PagerStyle CssClass="active GridPager" />
|
||||
<PagerSettings Mode="NumericFirstLast" />
|
||||
<SelectedRowStyle CssClass="table-info" />
|
||||
<EmptyDataTemplate>
|
||||
Nessun Risultato
|
||||
</EmptyDataTemplate>
|
||||
<Columns>
|
||||
<%--<asp:TemplateField ShowHeader="False">
|
||||
<HeaderTemplate>
|
||||
<asp:LinkButton ID="lbtReset" runat="server" OnClick="lbtReset_Click" CssClass="btn btn-sm btn-primary" Visible="true" ToolTip="Reset"><i class="fas fa-sync"></i></asp:LinkButton>
|
||||
</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="lbtSel" runat="server" CausesValidation="False" CommandName="Select" Text="Seleziona" CssClass="btn btn-sm btn-info"><i class="fas fa-search"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>--%>
|
||||
<asp:TemplateField HeaderText="Lotto" SortExpression="Lotto">
|
||||
<ItemTemplate>
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<b>
|
||||
<asp:Label ID="lblLotto" runat="server" Text='<%# Eval("Lotto") %>' /></b>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<asp:Label ID="lblTipoLotto" runat="server" Text='<%# Eval("TipoLotto") %>' ToolTip='<%# Eval("Origine") %>' />
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Eval("CodStato") %>' ToolTip='<%# Eval("DescStato") %>' />
|
||||
</div>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="NumUdc" HeaderText="#" SortExpression="NumUdc" />
|
||||
<asp:TemplateField HeaderText="Articolo" SortExpression="CodArt">
|
||||
<ItemTemplate>
|
||||
<div class="row">
|
||||
<div class="col-12 font-weight-bold">
|
||||
<asp:Label ID="Label2" runat="server" Text='<%# Eval("CodArt") %>' ToolTip='<%# Eval("CodArtExt") %>' />
|
||||
</div>
|
||||
<div class="col-12 small">
|
||||
<i>
|
||||
<asp:Label ID="Label5" runat="server" Text='<%# Eval("DescrArt") + " | " + Eval("CodArtExt") %>' /></i>
|
||||
</div>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Qta" SortExpression="QtaOrig">
|
||||
<ItemTemplate>
|
||||
<b><asp:Label ID="Label9" runat="server" Text='<%# Eval("QtaCurr", "{0:N0}") %>' ToolTip="Qta corrente" /></b>
|
||||
/
|
||||
<asp:Label ID="Label6" runat="server" Text='<%# Eval("QtaOrig", "{0:N0}") %>' ToolTip="Qta orig" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Data" SortExpression="DtCrea">
|
||||
<ItemTemplate>
|
||||
<div>
|
||||
<asp:Label ID="Label7" runat="server" Text='<%# Eval("DtCrea", "{0:yyyy.MM.dd}") %>' />
|
||||
</div>
|
||||
<div class="small">
|
||||
<i>
|
||||
<asp:Label ID="Label8" runat="server" Text='<%# Eval("Note") %>' /></i>
|
||||
</div>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Att" SortExpression="Attivo">
|
||||
<ItemTemplate>
|
||||
<asp:CheckBox ID="CheckBox1" runat="server" Checked='<%# Eval("Attivo") %>' Enabled="false" ToolTip='<%# Eval("DtMod", "mod: {0:yyyy.MM.dd HH:mm:ss}") %>' />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
<asp:ObjectDataSource ID="odsLottiIn" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="getByHashList" TypeName="MagData.DS_MagTableAdapters.ElencoLottiTableAdapter">
|
||||
<SelectParameters>
|
||||
<asp:ControlParameter ControlID="hfHashList" DefaultValue="#" Name="elLotti" PropertyName="Value" Type="String" />
|
||||
</SelectParameters>
|
||||
</asp:ObjectDataSource>
|
||||
<asp:HiddenField runat="server" ID="hfHashList" />
|
||||
</div>
|
||||
</div>
|
||||
<asp:HiddenField runat="server" ID="hfJsonLotti" />
|
||||
@@ -1,70 +0,0 @@
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace MP_MAG.WebUserControls
|
||||
{
|
||||
public partial class cmp_semiLavLottiIn : BaseUserControl
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Elenco dei lotti selezionati
|
||||
/// </summary>
|
||||
public List<string> lottiSel
|
||||
{
|
||||
get
|
||||
{
|
||||
List<string> answ = null;
|
||||
string rawVal = hfJsonLotti.Value;
|
||||
try
|
||||
{
|
||||
answ = JsonConvert.DeserializeObject<List<string>>(rawVal);
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
if (answ == null)
|
||||
{
|
||||
answ = new List<string>();
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
set
|
||||
{
|
||||
string rawVal = JsonConvert.SerializeObject(value);
|
||||
hfJsonLotti.Value = rawVal;
|
||||
// salvo ANCHE elenco in formato #lotto#lotto#
|
||||
string eliString = $"#{string.Join("#", value)}#";
|
||||
hfHashList.Value = eliString;
|
||||
// update grView...
|
||||
grViewLottoIn.DataBind();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Elenco lotti in formato HashList
|
||||
/// </summary>
|
||||
public string elLotti
|
||||
{
|
||||
get
|
||||
{
|
||||
return hfHashList.Value;
|
||||
}
|
||||
}
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// reset sel lottoIn
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void lbtResetLottoIn_Click(object sender, EventArgs e)
|
||||
{
|
||||
raiseReset();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,62 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <generato automaticamente>
|
||||
// Codice generato da uno strumento.
|
||||
//
|
||||
// Le modifiche a questo file possono causare un comportamento non corretto e verranno perse se
|
||||
// il codice viene rigenerato.
|
||||
// </generato automaticamente>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace MP_MAG.WebUserControls
|
||||
{
|
||||
|
||||
|
||||
public partial class cmp_semiLavLottiIn
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Controllo lbtResetLottoIn.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.LinkButton lbtResetLottoIn;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo grViewLottoIn.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.GridView grViewLottoIn;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo odsLottiIn.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.ObjectDataSource odsLottiIn;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo hfHashList.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hfHashList;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo hfJsonLotti.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Campo generato automaticamente.
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.HiddenField hfJsonLotti;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user