Merge branch 'develop' into SDK
This commit is contained in:
@@ -604,6 +604,43 @@ namespace AppData
|
||||
// restituisco ok
|
||||
return answ;
|
||||
}
|
||||
public static string canStartNewKey
|
||||
{
|
||||
get
|
||||
{
|
||||
return $"{redOutPath}:CanStartNew";
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// verifica se sia avviabile un nuovo task nesting controllando cache Redis o tabelle batch/offlineOrders
|
||||
/// </summary>
|
||||
public static bool canStartNew
|
||||
{
|
||||
get
|
||||
{
|
||||
bool answ = false;
|
||||
bool valido = false;
|
||||
// cerco in redis
|
||||
if (memLayer.ML.redKeyPresent(canStartNewKey))
|
||||
{
|
||||
string rawData = memLayer.ML.getRSV(canStartNewKey);
|
||||
valido = bool.TryParse(rawData, out answ);
|
||||
}
|
||||
if (!valido)
|
||||
{
|
||||
// in primis controllo SE ci siano task running, nel qual caso è false e basta...
|
||||
int numEst = DataLayer.man.taBL.getByStatus((int)BatchStatus.EstimationRequested, "", 0).Count;
|
||||
int numNest = DataLayer.man.taBL.getByStatus((int)BatchStatus.NestRequested, "", 0).Count;
|
||||
// ora controllo anche offline orders...
|
||||
int numOffOrd = DataLayer.man.taOffOL.getRunning().Count;
|
||||
// ora la somma di tutti DEVE essere zero...
|
||||
answ = ((numEst + numNest + numOffOrd) == 0);
|
||||
// salvo in redis
|
||||
memLayer.ML.setRSV(canStartNewKey, answ.ToString(), 2);
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Verifica lo stato di una richiesta di esecuzione BATCH x stima/nesting
|
||||
|
||||
Vendored
+1
-1
@@ -11,7 +11,7 @@ pipeline {
|
||||
steps {
|
||||
/* calcolo numero versione... diverso x branch MASTER/DEVELOP */
|
||||
script {
|
||||
withEnv(['NEXT_BUILD_NUMBER=345']) {
|
||||
withEnv(['NEXT_BUILD_NUMBER=346']) {
|
||||
// env.versionNumber = VersionNumber(versionNumberString : '1.1.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2019-07-01', skipFailedBuilds: true)
|
||||
env.versionNumber = VersionNumber(versionNumberString : '1.1.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2019-07-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}')
|
||||
env.versionNumberBeta = VersionNumber(versionNumberString : '1.1.${BUILD_DATE_FORMATTED, "yyMM"}-beta.${BUILDS_ALL_TIME}', projectStartDate : '2019-07-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}')
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
</appSettings>
|
||||
<connectionStrings>
|
||||
<add name="AppData.Properties.Settings.Sauder_NKCConnectionString" connectionString="Data Source=PC-LELE\SQLEXPRESS;Initial Catalog=Sauder_NKC;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
<add name="Elmah" connectionString="Data Source=PC-LELE\SQLEXPRESS;Initial Catalog=Elmah;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
<add name="ErrorLog" connectionString="Data Source=PC-LELE\SQLEXPRESS;Initial Catalog=Elmah;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
</connectionStrings>
|
||||
<system.web>
|
||||
</system.web>
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
</appSettings>
|
||||
<connectionStrings>
|
||||
<add name="AppData.Properties.Settings.Sauder_NKCConnectionString" connectionString="Data Source=SAKITTING\SQLEXPRESS;Initial Catalog=Sauder_NKC;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
<add name="Elmah" connectionString="Data Source=SAKITTING\SQLEXPRESS;Initial Catalog=Elmah;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
<add name="ErrorLog" connectionString="Data Source=SAKITTING\SQLEXPRESS;Initial Catalog=Elmah;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
</connectionStrings>
|
||||
<system.web>
|
||||
<compilation xdt:Transform="RemoveAttributes(debug)" />
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
</appSettings>
|
||||
<connectionStrings>
|
||||
<add name="AppData.Properties.Settings.Sauder_NKCConnectionString" connectionString="Data Source=SQL2016DEV;Initial Catalog=Sauder_NKC;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
<add name="Elmah" connectionString="Data Source=SQL2016DEV;Initial Catalog=Elmah;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
<add name="ErrorLog" connectionString="Data Source=SQL2016DEV;Initial Catalog=Elmah;Persist Security Info=True;User ID=conn_NKC;Password=pwd_NKC" xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||||
</connectionStrings>
|
||||
<system.web>
|
||||
<compilation xdt:Transform="RemoveAttributes(debug)" />
|
||||
|
||||
@@ -122,6 +122,20 @@ namespace NKC_WF.WebUserControls
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Descrizione Cart selezionato (ord ext code)
|
||||
/// </summary>
|
||||
public string CartDesc
|
||||
{
|
||||
get
|
||||
{
|
||||
return cmp_KS_currCart.Description;
|
||||
}
|
||||
set
|
||||
{
|
||||
cmp_KS_currCart.Description = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Bin selezionato
|
||||
/// </summary>
|
||||
public int BinID
|
||||
|
||||
@@ -46,6 +46,20 @@ namespace NKC_WF.WebUserControls
|
||||
cmp_KS_OkoiCart.Dtmx = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Descrizione Cart selezionato (ord ext code)
|
||||
/// </summary>
|
||||
public string CartDesc
|
||||
{
|
||||
get
|
||||
{
|
||||
return cmp_KS_currCart.Description;
|
||||
}
|
||||
set
|
||||
{
|
||||
cmp_KS_currCart.Description = value;
|
||||
}
|
||||
}
|
||||
public void doUpdate()
|
||||
{
|
||||
}
|
||||
|
||||
@@ -39,6 +39,20 @@ namespace NKC_WF.WebUserControls
|
||||
cmp_KS_currCart.Dtmx = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Descrizione Cart selezionato (ord ext code)
|
||||
/// </summary>
|
||||
public string CartDesc
|
||||
{
|
||||
get
|
||||
{
|
||||
return cmp_KS_currCart.Description;
|
||||
}
|
||||
set
|
||||
{
|
||||
cmp_KS_currCart.Description = value;
|
||||
}
|
||||
}
|
||||
public int ItemID
|
||||
{
|
||||
get
|
||||
|
||||
@@ -119,6 +119,20 @@ namespace NKC_WF.WebUserControls
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Descrizione Cart selezionato (ord ext code)
|
||||
/// </summary>
|
||||
public string CartDesc
|
||||
{
|
||||
get
|
||||
{
|
||||
return cmp_KS_currCart.Description;
|
||||
}
|
||||
set
|
||||
{
|
||||
cmp_KS_currCart.Description = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// OtherItem selezionato
|
||||
/// </summary>
|
||||
public int OtherItemID
|
||||
@@ -147,6 +161,20 @@ namespace NKC_WF.WebUserControls
|
||||
cmp_KS_OkoiOI.Dtmx = value;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Descrizione OtherItem selezionato
|
||||
/// </summary>
|
||||
public string OtherItemDesc
|
||||
{
|
||||
get
|
||||
{
|
||||
return cmp_KS_currOI.Description;
|
||||
}
|
||||
set
|
||||
{
|
||||
cmp_KS_currOI.Description = value;
|
||||
}
|
||||
}
|
||||
|
||||
protected void lbtAddAll_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
@@ -1,7 +1,14 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="cmp_KS_currCart.ascx.cs" Inherits="NKC_WF.WebUserControls.cmp_KS_currCart" %>
|
||||
|
||||
<div class="border border-success">
|
||||
<h5 class="table-success text-uppercase"> <%: traduci ("Cart") %></h5>
|
||||
<h5 class="table-success text-uppercase"><%: traduci ("Cart") %></h5>
|
||||
<asp:HiddenField runat="server" ID="hfValue" />
|
||||
<asp:Label runat="server" ID="lblDtmx" />
|
||||
<div class="row">
|
||||
<div class="col-6">
|
||||
<asp:Label runat="server" ID="lblDtmx" />
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<asp:Label runat="server" ID="lblDesc" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -38,5 +38,16 @@ namespace NKC_WF.WebUserControls
|
||||
lblDtmx.Text = value;
|
||||
}
|
||||
}
|
||||
public string Description
|
||||
{
|
||||
get
|
||||
{
|
||||
return lblDesc.Text;
|
||||
}
|
||||
set
|
||||
{
|
||||
lblDesc.Text = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,5 +31,14 @@ namespace NKC_WF.WebUserControls
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lblDtmx;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo lblDesc.
|
||||
/// </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.Label lblDesc;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,13 @@
|
||||
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="cmp_KS_currOI.ascx.cs" Inherits="NKC_WF.WebUserControls.cmp_KS_currOI" %>
|
||||
<div class="border border-secondary">
|
||||
<h5 class="table-info"> <%: traduci ("OtherParts") %></h5>
|
||||
<h5 class="table-info"><%: traduci ("OtherParts") %></h5>
|
||||
<asp:HiddenField runat="server" ID="hfValue" />
|
||||
<asp:Label runat="server" ID="lblDtmx" />
|
||||
<div class="row">
|
||||
<div class="col-6">
|
||||
<asp:Label runat="server" ID="lblDtmx" />
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<asp:Label runat="server" ID="lblDesc" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -38,5 +38,16 @@ namespace NKC_WF.WebUserControls
|
||||
lblDtmx.Text = value;
|
||||
}
|
||||
}
|
||||
public string Description
|
||||
{
|
||||
get
|
||||
{
|
||||
return lblDesc.Text;
|
||||
}
|
||||
set
|
||||
{
|
||||
lblDesc.Text = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,5 +31,14 @@ namespace NKC_WF.WebUserControls
|
||||
/// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lblDtmx;
|
||||
|
||||
/// <summary>
|
||||
/// Controllo lblDesc.
|
||||
/// </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.Label lblDesc;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
<div class="row">
|
||||
<div class="col-8 text-left card-text">
|
||||
<asp:Label ID="Label1" runat="server" Text='<%# Eval("OtherItemDesc") %>' />
|
||||
<div class="small"><%# Eval("OtherItemDtmx") %></div>
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<asp:Image runat="server" Height='<%# qrSize %>' ImageUrl='<%# getImgUrl(Eval("OtherItemDtmx")) %>' />
|
||||
|
||||
@@ -6,12 +6,12 @@
|
||||
<div class="row small">
|
||||
<div class="col-9">
|
||||
<h3><%: traduci ("BatchDetail") %></h3>
|
||||
<asp:Label runat="server" ID="lblRequestPresent" CssClass="text-danger" Visible='<%# !canStartNew() %>' Text='<%# traduci("NewNestReqDisabled") %>' />
|
||||
<asp:Label runat="server" ID="lblRequestPresent" CssClass="text-danger" Visible='<%# !canStartNew %>' Text='<%# traduci("NewNestReqDisabled") %>' />
|
||||
</div>
|
||||
<div class="col-3">
|
||||
<asp:LinkButton runat="server" ID="lbtSendEstim" CssClass="btn btn-sm btn-block btn-info" OnClick="lbtSendEstim_Click" OnClientClick='<%: SteamWare.jsUtils.getCBE("ConfirmStartEstim") %>' Visible='<%# (checkStatus(Eval("Status"), NKC_SDK.BatchStatus.Errors) || checkStatus(Eval("Status"), NKC_SDK.BatchStatus.Imported)) && canStartNew() %>'><%: traduci("SendToEstim") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtSendEstim" CssClass="btn btn-sm btn-block btn-info" OnClick="lbtSendEstim_Click" OnClientClick='<%: SteamWare.jsUtils.getCBE("ConfirmStartEstim") %>' Visible='<%# (checkStatus(Eval("Status"), NKC_SDK.BatchStatus.Errors) || checkStatus(Eval("Status"), NKC_SDK.BatchStatus.Imported)) && canStartNew %>'><%: traduci("SendToEstim") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtStopEstim" CssClass="btn btn-sm btn-block btn-dark" OnClick="lbtStopEstim_Click" OnClientClick='<%: SteamWare.jsUtils.getCBE("ConfirmStopEstim") %>' Visible='<%# checkStatus(Eval("Status"), NKC_SDK.BatchStatus.EstimationRequested) %>'><%: traduci("StopEstim") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtSendNesting" CssClass="btn btn-sm btn-block btn-warning" OnClick="lbtSendNesting_Click" OnClientClick='<%: SteamWare.jsUtils.getCBE("ConfirmStartNest") %>' Visible='<%# checkStatus(Eval("Status"), NKC_SDK.BatchStatus.EstimationDone) && canStartNew() %>'><%: traduci("SendToNest") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtSendNesting" CssClass="btn btn-sm btn-block btn-warning" OnClick="lbtSendNesting_Click" OnClientClick='<%: SteamWare.jsUtils.getCBE("ConfirmStartNest") %>' Visible='<%# checkStatus(Eval("Status"), NKC_SDK.BatchStatus.EstimationDone) && canStartNew %>'><%: traduci("SendToNest") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtStopNesting" CssClass="btn btn-sm btn-block btn-dark" OnClick="lbtStopNesting_Click" OnClientClick='<%: SteamWare.jsUtils.getCBE("ConfirmStopNest") %>' Visible='<%# checkStatus(Eval("Status"), NKC_SDK.BatchStatus.NestRequested) %>'><%: traduci("StopNest") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtAccept" CssClass="btn btn-sm btn-block btn-success" OnClick="lbtAccept_Click" OnClientClick='<%: SteamWare.jsUtils.getCBE("ConfirmAcceptNest") %>' Visible='<%# checkStatus(Eval("Status"), NKC_SDK.BatchStatus.NestDone) %>'><%: traduci("AcceptNest") %></asp:LinkButton>
|
||||
</div>
|
||||
|
||||
@@ -239,17 +239,12 @@ namespace NKC_WF.WebUserControls
|
||||
/// verifica possibilità avvio TASK x presenza task NON chiusi
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public bool canStartNew()
|
||||
public bool canStartNew
|
||||
{
|
||||
bool answ = false;
|
||||
// in primis controllo SE ci siano task running, nel qual caso è false e basta...
|
||||
int numEst = DataLayer.man.taBL.getByStatus((int)BatchStatus.EstimationRequested, "", 0).Count;
|
||||
int numNest = DataLayer.man.taBL.getByStatus((int)BatchStatus.NestRequested, "", 0).Count;
|
||||
// ora controllo anche offline orders...
|
||||
int numOffOrd = DataLayer.man.taOffOL.getRunning().Count;
|
||||
// ora la somma di tutti DEVE essere zero...
|
||||
answ = ((numEst + numNest + numOffOrd) == 0);
|
||||
return answ;
|
||||
get
|
||||
{
|
||||
return ComLib.canStartNew;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Converte il codice stato in effettivo campo
|
||||
|
||||
@@ -295,7 +295,14 @@ namespace NKC_WF.WebUserControls
|
||||
else
|
||||
{
|
||||
// mostro CART!
|
||||
setCart(rawData, codeInt);
|
||||
string descr = "-";
|
||||
try
|
||||
{
|
||||
descr = rigaOrd.OrderExtCode;
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
setCart(rawData, codeInt, descr);
|
||||
// verifico se il cart sia già stato messo in scarico (in quel caso dico già ok...)
|
||||
var tabLog = DataLayer.man.taPLog.getByCartId(codeInt);
|
||||
if (tabLog.Count > 0)
|
||||
@@ -511,14 +518,21 @@ namespace NKC_WF.WebUserControls
|
||||
var listCartAvailable = tabOKOI.Where(x => !x.IsCartKitStartNull() && x.IsCartKitEndNull()).ToList();
|
||||
if (listCartAvailable.Count == 0)
|
||||
{
|
||||
displError($"{traduci("ErrPartNoCartAvail")}: {rawData} | item {tabOKOI[0].OtherItemDesc} | order {tabOKOI[0].OrderExtCode}");
|
||||
displError($"{traduci("ErrPartNoCartAvail")}: {rawData} | PART {tabOKOI[0].OtherItemExtCode} {tabOKOI[0].OtherItemDesc} | order {tabOKOI[0].OrderExtCode}");
|
||||
// reset preliminare
|
||||
resetOtherItem();
|
||||
}
|
||||
else
|
||||
{
|
||||
string descr = "-";
|
||||
try
|
||||
{
|
||||
descr = tabOKOI[0].OtherItemExtCode;
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
// mostro OtherItem!
|
||||
setOtherItem(rawData, codeInt);
|
||||
setOtherItem(rawData, codeInt, descr);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -549,10 +563,12 @@ namespace NKC_WF.WebUserControls
|
||||
/// </summary>
|
||||
/// <param name="rawData"></param>
|
||||
/// <param name="codeInt"></param>
|
||||
private void setOtherItem(string rawData, int codeInt)
|
||||
/// <param name="Description"></param>
|
||||
private void setOtherItem(string rawData, int codeInt, string Description)
|
||||
{
|
||||
cmp_KS_OtherItemsCart.OtherItemID = codeInt;
|
||||
cmp_KS_OtherItemsCart.OtherItemDtmx = rawData;
|
||||
cmp_KS_OtherItemsCart.OtherItemDesc = Description;
|
||||
cmp_KS_OtherItemsCart.doUpdate();
|
||||
fixVisibility();
|
||||
}
|
||||
@@ -574,19 +590,24 @@ namespace NKC_WF.WebUserControls
|
||||
/// </summary>
|
||||
/// <param name="rawData"></param>
|
||||
/// <param name="codeInt"></param>
|
||||
private void setCart(string rawData, int codeInt)
|
||||
/// <param name="Description"></param>
|
||||
private void setCart(string rawData, int codeInt, string Description)
|
||||
{
|
||||
cmp_KS_BinCart.CartID = codeInt;
|
||||
cmp_KS_BinCart.CartDtmx = rawData;
|
||||
cmp_KS_BinCart.CartDesc = Description;
|
||||
cmp_KS_BinCart.doUpdate();
|
||||
cmp_KS_OtherItemsCart.CartID = codeInt;
|
||||
cmp_KS_OtherItemsCart.CartDtmx = rawData;
|
||||
cmp_KS_OtherItemsCart.CartDesc = Description;
|
||||
cmp_KS_OtherItemsCart.doUpdate();
|
||||
cmp_KS_Cart.CartID = codeInt;
|
||||
cmp_KS_Cart.CartDtmx = rawData;
|
||||
cmp_KS_Cart.CartDesc = Description;
|
||||
cmp_KS_Cart.doUpdate();
|
||||
cmp_KS_Items.CartID = codeInt;
|
||||
cmp_KS_Items.CartDtmx = rawData;
|
||||
cmp_KS_Items.CartDesc = Description;
|
||||
cmp_KS_Items.doUpdate();
|
||||
fixVisibility();
|
||||
}
|
||||
|
||||
@@ -27,11 +27,11 @@
|
||||
<hr />
|
||||
<div class="row my-2">
|
||||
<div class="col">
|
||||
<asp:LinkButton runat="server" ID="lbtMakeCnc" CssClass="btn btn-success btn-block" Visible='<%# obj2int(Eval("OrdStatus")) <= 0 && canStartNew() %>' OnClick="lbtMakeCnc_Click" OnClientClick='return confirm("Send to CAM?")'><i class="fa fa-laptop" aria-hidden="true"></i> <%: traduci ("MakeCncProg") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtMakeCnc" CssClass="btn btn-success btn-block" Visible='<%# obj2int(Eval("OrdStatus")) <= 0 && canStartNew %>' OnClick="lbtMakeCnc_Click" OnClientClick='return confirm("Send to CAM?")'><i class="fa fa-laptop" aria-hidden="true"></i> <%: traduci ("MakeCncProg") %></asp:LinkButton>
|
||||
<asp:LinkButton runat="server" ID="lbtStopCnc" CssClass="btn btn-dark text-light btn-block" Visible='<%# obj2int(Eval("OrdStatus")) == 1 && Eval("DrawFilePath").ToString() == "" %>' OnClick="lbtStopCnc_Click" OnClientClick='return confirm("Remove request to CAM?")'><i class="fa fa-laptop" aria-hidden="true"></i> <%: traduci ("StopCncReq") %></asp:LinkButton>
|
||||
</div>
|
||||
<div class="col">
|
||||
<asp:Label runat="server" ID="lblRequestPresent" CssClass="text-danger" Visible='<%# !canStartNew() %>' Text='<%# traduci("NewNestReqDisabled") %>' />
|
||||
<asp:Label runat="server" ID="lblRequestPresent" CssClass="text-danger" Visible='<%# !canStartNew %>' Text='<%# traduci("NewNestReqDisabled") %>' />
|
||||
<asp:LinkButton runat="server" ID="lblDone" CssClass="btn btn-success btn-block" Visible='<%# (Eval("OrdStatus").ToString()=="1" && Eval("DrawFilePath").ToString()!="") || Eval("OrdStatus").ToString()=="2" %>' OnClick="lblDone_Click" OnClientClick='return confirm("Confirm Item production?")'><i class="fa fa-check" aria-hidden="true"></i> <%: traduci ("ItemDone") %></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -83,7 +83,7 @@ namespace NKC_WF.WebUserControls
|
||||
DataLayer.man.taOffOL.updateStatus(OffOrdId, 0);
|
||||
}
|
||||
frmView.DataBind();
|
||||
raiseEvent();
|
||||
raiseEvent();
|
||||
}
|
||||
|
||||
protected void lbtPrintLabels_Click(object sender, EventArgs e)
|
||||
@@ -120,17 +120,12 @@ namespace NKC_WF.WebUserControls
|
||||
/// verifica possibilità avvio TASK x presenza task NON chiusi
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public bool canStartNew()
|
||||
public bool canStartNew
|
||||
{
|
||||
bool answ = false;
|
||||
// in primis controllo SE ci siano task running, nel qual caso è false e basta...
|
||||
int numEst = DataLayer.man.taBL.getByStatus((int)BatchStatus.EstimationRequested, "", 0).Count;
|
||||
int numNest = DataLayer.man.taBL.getByStatus((int)BatchStatus.NestRequested, "", 0).Count;
|
||||
// ora controllo anche offline orders...
|
||||
int numOffOrd = DataLayer.man.taOffOL.getRunning().Count;
|
||||
// ora la somma di tutti DEVE essere zero...
|
||||
answ = ((numEst + numNest + numOffOrd) == 0);
|
||||
return answ;
|
||||
get
|
||||
{
|
||||
return ComLib.canStartNew;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -714,10 +714,13 @@ namespace NKC_WF.WebUserControls
|
||||
// resetto item selezionato...
|
||||
DataLayer.man.taIL.updateStatus(itemIdSelected, 990, PlaceId);
|
||||
lgInfo($"cmp_unloadSmart | SCRAP | Status --> 990 | itemIdSelected: {itemIdSelected} | PlaceId: {PlaceId}");
|
||||
resetSelection(false);
|
||||
showItemDetail(false, null, false);
|
||||
lblMessage.Text = traduci("PartScrapped");
|
||||
// rirprocesso barcode...
|
||||
// riprocesso barcode...
|
||||
lastCmd = lastValidCmd;
|
||||
processLastCmd(false);
|
||||
resetButtons();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user