diff --git a/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx b/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx deleted file mode 100644 index a12185cb..00000000 --- a/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx +++ /dev/null @@ -1,70 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_sbloccoUdcFusioni.ascx.cs" Inherits="GMW.WebUserControls.mod_sbloccoUdcFusioni" %> - -<% if (false) - { %> - - -<% } %> - -
-
-   -
-
-
- -
-
- -   - -
-
- -
- -
-
-
- <%: traduci("btnSbloccoUDC") %> -
-
-
- Elenco UDC sbloccabili -
- - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
-
-
-
-   -
-
- diff --git a/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx.cs b/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx.cs deleted file mode 100644 index 3ccdcf08..00000000 --- a/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx.cs +++ /dev/null @@ -1,366 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; -using GMW_data; - -namespace GMW.WebUserControls -{ - public partial class mod_sbloccoUdcFusioni : System.Web.UI.UserControl - { - /// - /// flusso associato (hard coded) a sterrati - /// - protected string flusso = "ST"; - /// - /// stato associato (hard coded) a sterrati - /// - protected string statoUDC = "Sterr"; - /// - /// tipo di evento associato alla modifica dell'UDC - /// - protected string eventoUDC = "UDC_SBFUS"; - public event EventHandler eh_reqUpdate; - /// - /// stringa UID univoca - /// - public string uid - { - get - { - return this.UniqueID.Replace("$", "_").Replace("-", "_"); - } - } - /// - /// caricamento pagina - /// - /// - /// - protected void Page_Load(object sender, EventArgs e) - { - if (!Page.IsPostBack) - { - traduciObj(); - divSblocca.Visible = false; - idxCella = Postazione.currIdxCella; - } - doChecks(); - } - /// - /// IDX cella associata alla linea corrente - /// - protected int idxCella - { - get - { - int answ = 0; - if (memLayer.ML.isInSessionObject("IdxCellaLineaST")) - { - answ = memLayer.ML.IntSessionObj("IdxCellaLineaST"); - } - return answ; - } - set - { - memLayer.ML.setSessionVal("IdxCellaLineaST", value); - } - } - /// - /// effettua controlli visibilità - /// - private void doChecks() - { - checkBarcode(); - } - /// - /// sistemo labels oggetti - /// - private void traduciObj() - { - } - /// - /// restituisce il nome della pagina corrente - /// - protected string PagCorrente - { - get - { - string answ = ""; - Uri MyUrl = Request.Url; - string delimStr = "/"; - char[] delimiter = delimStr.ToCharArray(); - string[] finalUrl = MyUrl.LocalPath.ToString().Split(delimiter); - int n = finalUrl.Length; - answ = finalUrl[n - 1].ToString(); - DataLayer_AnagGen.PermessiRow riga = (DataLayer_AnagGen.PermessiRow)user_std.UtSn.permessi.Select(string.Format("URL = '{0}'", answ))[0]; - answ = riga.NOME; - return answ; - } - } - /// - /// wrapper traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - /// - /// indica il codice articolo correntemente selezionato - /// - protected string currParticolare - { - get - { - return memLayer.ML.StringSessionObj(string.Format("currParticolare_{0}", uid)); - } - set - { - memLayer.ML.setSessionVal(string.Format("currParticolare_{0}", uid), value, memLayer.ML.confReadBool("keepParticolareSel")); - } - } - /// - /// indica UDC correntemente selezionato - /// - protected string currUDC - { - get - { - return memLayer.ML.StringSessionObj(string.Format("UDC_{0}", uid)); - } - set - { - memLayer.ML.setSessionVal(string.Format("UDC_{0}", uid), value, memLayer.ML.confReadBool("keepParticolareSel")); - } - } - /// - /// indica se i caratteri vadano forzati a maiuscoli - /// - public bool forceUppercase - { - get - { - return memLayer.ML.confReadBool("forceUppercase"); - } - } - /// - /// decodifica il tipo barcode acquisito - /// - public tipoCodiceBarcode tipoBCode - { - get - { - tipoCodiceBarcode answ = tipoCodiceBarcode.ND; - int trovati = 0; - // controllo non si tratti di un comando... - string preCmd = memLayer.ML.confReadString("prefComandi"); - if (barcodeIn.StartsWith(preCmd)) - { - answ = tipoCodiceBarcode.Comando; - } - else if ((TermClass.Ter.riconosciBarcode(barcodeIn) == tipoCodiceBarcode.Particolare)) // è un particolare... - { - answ = tipoCodiceBarcode.Particolare; - } - else - { - try - { - // cerco tra gitterbox (UDC)... - trovati = MagClass.magazzino.taCartellini.getByUdc(barcodeIn).Rows.Count; - if (trovati > 0) - { - answ = tipoCodiceBarcode.UDC; - } - } - catch - { - } - } - return answ; - } - } - /// - /// valore barcode - /// - public string barcodeIn - { - get - { - return txtBarcode.Text.Trim(); - } - set - { - txtBarcode.Text = value; - } - } - /// - /// controlla se ci sia un barcode - /// - private void checkBarcode() - { - if (barcodeIn != "") - { - Postazione.messaggiText = string.Format("Barcode digitato: {0}", barcodeIn); - switch (tipoBCode) - { - case tipoCodiceBarcode.UDC: - // procedo solo se UDC esistente - if (MagClass.magazzino.checkUDC(barcodeIn)) - { - /******************************************************************** - * procedo per UDC in ingresso: - * - Deve essere in una locazione WIP sterratura ( LS -- ) - * - Deve avere una sola associazione UDC Fuso - UDC Sterrato - * - ********************************************************************/ - - // controllo IdxPosizione dell'UDC e confronto con posizione in webconfig x fusi (pre sterratura/taglio) - int IdxPosizione = DataProxy.obj.taCartellini.stp_getByUdc(barcodeIn)[0].IdxPosizione; - if (IdxPosizione == memLayer.ML.confReadInt("IdxPosizioneFusi")) - { - - // calcolo nuovo particolare - string currParticolare = DataProxy.obj.taCartellini.stp_getByUdc(barcodeIn)[0].Particolare; - - int idxCellaCurr = 0; - try - { - idxCellaCurr = MagClass.magazzino.taPosUdcCorr.getByUDC(barcodeIn)[0].IdxCella; - } - catch - { } - string codBloccoCurr = ""; - int idxBlocco = 0; - try - { - idxBlocco = MagClass.magazzino.taCelle.getByIdxCella(idxCellaCurr)[0].IdxBlocco; - codBloccoCurr = MagClass.magazzino.taBlocchi.getByIdx(idxBlocco)[0].CodBlocco; - } - catch - { } - - // controllo sia in WIP terra sterratura - if (codBloccoCurr == memLayer.ML.confReadString("CodBloccoFusi")) - { - // controllo abbia 1 sola associazione fusi/sterrato COME CHILD - if (DataProxy.obj.taRelazUDC.stp_getChild(barcodeIn).Rows.Count > 1) - { - divSblocca.Visible = false; - Postazione.messaggiText += " - Attenzione, UDC Fuso associato a più di uno sterrato!"; - Postazione.CssClass = "stileComandoKo"; - } - else - { - currUDC = barcodeIn; - Postazione.CssClass = "stileComandoOk"; - divSblocca.Visible = true; - } - } - else - { - divSblocca.Visible = false; - Postazione.messaggiText += " - Attenzione, UDC NON RISULTA caricato su linee Fusi!"; - Postazione.CssClass = "stileComandoKo"; - } - } - else - { - divSblocca.Visible = false; - Postazione.messaggiText += " - Attenzione, UDC NON in posizione corretta Fusi!"; - Postazione.CssClass = "stileComandoKo"; - } - } - - // update - doUpdate(); - break; - default: - Postazione.messaggiText += " - codice non riconosciuto!"; - Postazione.CssClass = "stileComandoND"; - divSblocca.Visible = false; - break; - } - barcodeIn = ""; - } - else - { - Postazione.messaggiText = traduci("AttesaBCode"); - Postazione.CssClass = "stileAttesa"; - } - txtBarcode.Focus(); - } - - /// - /// aggiorna tabella + focus a barcode - /// - public void doUpdate() - { - idxCella = Postazione.currIdxCella; - grView.DataBind(); - txtBarcode.Focus(); - // raise dell'evento - if (eh_reqUpdate != null) - { - eh_reqUpdate(this, new EventArgs()); - } - } - /// - /// effettua reset dati - /// - public void doResetData() - { - // resetto i dati QtaTot e particolare... - currParticolare = ""; - doChecks(); - } - - protected void grView_PageIndexChanged(object sender, EventArgs e) - { - // fix dell'ODS - checkFixOds(); - } - protected void grView_Sorted(object sender, EventArgs e) - { - // fix dell'ODS - checkFixOds(); - } - /// - /// aggiorno ods al binding.. - /// - /// - /// - protected void ods_DataBinding(object sender, EventArgs e) - { - // fix dell'ODS - checkFixOds(); - } - /// - /// verifica se attivo filtro company e imposta ods di conseguenza... - /// - private void checkFixOds() - { - } - - - /// - /// sblocca UDC - /// - /// - /// - protected void SbloccaUDC_Click(object sender, EventArgs e) - { - // va cancellata la sua relazioni Fuso-Sterrato e va spostato in locazione Fusi Terra - DataProxy.obj.taCartellini.sbloccaDaPost(eventoUDC, memLayer.ML.confReadInt("IdxPosizioneFusi"), currUDC, "", MagClass.magazzino.CodSoggCurrUser); - // resetto selezione - divSblocca.Visible = false; - currUDC = ""; - currParticolare = ""; - doUpdate(); - } - } -} \ No newline at end of file diff --git a/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx.designer.cs b/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx.designer.cs deleted file mode 100644 index e10f6132..00000000 --- a/GMW/WebUserControls/mod_sbloccoUdcFusioni.ascx.designer.cs +++ /dev/null @@ -1,114 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace GMW.WebUserControls { - - - public partial class mod_sbloccoUdcFusioni { - - /// - /// BundleReference1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::Microsoft.AspNet.Web.Optimization.WebForms.BundleReference BundleReference1; - - /// - /// BundleReference2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::Microsoft.AspNet.Web.Optimization.WebForms.BundleReference BundleReference2; - - /// - /// lblParticolareAttivo control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblParticolareAttivo; - - /// - /// lblDescrAttivo control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblDescrAttivo; - - /// - /// lblDisegno control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblDisegno; - - /// - /// lblBarcode control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblBarcode; - - /// - /// txtBarcode control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtBarcode; - - /// - /// divSblocca control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlGenericControl divSblocca; - - /// - /// lbtSbloccaUDC control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.LinkButton lbtSbloccaUDC; - - /// - /// grView control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.GridView grView; - - /// - /// odsUdcSBloccabili control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.ObjectDataSource odsUdcSBloccabili; - } -}