diff --git a/AppData/AppData.csproj b/AppData/AppData.csproj
index 77da100..2a368fa 100644
--- a/AppData/AppData.csproj
+++ b/AppData/AppData.csproj
@@ -41,6 +41,7 @@
+
True
True
diff --git a/AppData/DS_App.Designer.cs b/AppData/DS_App.Designer.cs
index f895653..e2da0d1 100644
--- a/AppData/DS_App.Designer.cs
+++ b/AppData/DS_App.Designer.cs
@@ -1001,7 +1001,7 @@ SELECT NumTask, CodArt, QtaRic, Prior, Concluso, DataIns, DataStart, CurrStatus
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
private void InitCommandCollection() {
- this._commandCollection = new global::System.Data.SqlClient.SqlCommand[2];
+ this._commandCollection = new global::System.Data.SqlClient.SqlCommand[4];
this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
this._commandCollection[0].Connection = this.Connection;
this._commandCollection[0].CommandText = "SELECT NumTask, CodArt, QtaRic, Prior, Concluso, DataIns, DataStart, CurrStatus F" +
@@ -1009,10 +1009,26 @@ SELECT NumTask, CodArt, QtaRic, Prior, Concluso, DataIns, DataStart, CurrStatus
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
this._commandCollection[1] = new global::System.Data.SqlClient.SqlCommand();
this._commandCollection[1].Connection = this.Connection;
- this._commandCollection[1].CommandText = "dbo.stp_TL_GetByStatus";
+ this._commandCollection[1].CommandText = "dbo.stp_TL_deleteQuery";
this._commandCollection[1].CommandType = global::System.Data.CommandType.StoredProcedure;
this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
- this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CurrStatus", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@NumTask", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[2] = new global::System.Data.SqlClient.SqlCommand();
+ this._commandCollection[2].Connection = this.Connection;
+ this._commandCollection[2].CommandText = "dbo.stp_TL_GetByFilt";
+ this._commandCollection[2].CommandType = global::System.Data.CommandType.StoredProcedure;
+ this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CurrStatus", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodArt", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@NumTask", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[3] = new global::System.Data.SqlClient.SqlCommand();
+ this._commandCollection[3].Connection = this.Connection;
+ this._commandCollection[3].CommandText = "dbo.stp_TL_insertQuery";
+ this._commandCollection[3].CommandType = global::System.Data.CommandType.StoredProcedure;
+ this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@NumTask", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodArt", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
+ this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@QtaRic", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
@@ -1043,14 +1059,26 @@ SELECT NumTask, CodArt, QtaRic, Prior, Concluso, DataIns, DataStart, CurrStatus
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)]
- public virtual DS_App.TaskListDataTable getByCurrStatus(global::System.Nullable CurrStatus) {
- this.Adapter.SelectCommand = this.CommandCollection[1];
+ public virtual DS_App.TaskListDataTable getByFilt(global::System.Nullable CurrStatus, string CodArt, string NumTask) {
+ this.Adapter.SelectCommand = this.CommandCollection[2];
if ((CurrStatus.HasValue == true)) {
this.Adapter.SelectCommand.Parameters[1].Value = ((int)(CurrStatus.Value));
}
else {
this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
}
+ if ((CodArt == null)) {
+ this.Adapter.SelectCommand.Parameters[2].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.SelectCommand.Parameters[2].Value = ((string)(CodArt));
+ }
+ if ((NumTask == null)) {
+ this.Adapter.SelectCommand.Parameters[3].Value = global::System.DBNull.Value;
+ }
+ else {
+ this.Adapter.SelectCommand.Parameters[3].Value = ((string)(NumTask));
+ }
DS_App.TaskListDataTable dataTable = new DS_App.TaskListDataTable();
this.Adapter.Fill(dataTable);
return dataTable;
@@ -1263,6 +1291,74 @@ SELECT NumTask, CodArt, QtaRic, Prior, Concluso, DataIns, DataStart, CurrStatus
public virtual int Update(string CodArt, int QtaRic, int Prior, bool Concluso, System.DateTime DataIns, global::System.Nullable DataStart, string Original_NumTask, string Original_CodArt, int Original_QtaRic, int Original_Prior, bool Original_Concluso, System.DateTime Original_DataIns, global::System.Nullable Original_DataStart, global::System.Nullable Original_CurrStatus) {
return this.Update(Original_NumTask, CodArt, QtaRic, Prior, Concluso, DataIns, DataStart, Original_NumTask, Original_CodArt, Original_QtaRic, Original_Prior, Original_Concluso, Original_DataIns, Original_DataStart, Original_CurrStatus);
}
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
+ public virtual int deleteQuery(string NumTask) {
+ global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[1];
+ if ((NumTask == null)) {
+ command.Parameters[1].Value = global::System.DBNull.Value;
+ }
+ else {
+ command.Parameters[1].Value = ((string)(NumTask));
+ }
+ global::System.Data.ConnectionState previousConnectionState = command.Connection.State;
+ if (((command.Connection.State & global::System.Data.ConnectionState.Open)
+ != global::System.Data.ConnectionState.Open)) {
+ command.Connection.Open();
+ }
+ int returnValue;
+ try {
+ returnValue = command.ExecuteNonQuery();
+ }
+ finally {
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
+ command.Connection.Close();
+ }
+ }
+ return returnValue;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")]
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
+ public virtual int insertQuery(string NumTask, string CodArt, global::System.Nullable QtaRic) {
+ global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[3];
+ if ((NumTask == null)) {
+ command.Parameters[1].Value = global::System.DBNull.Value;
+ }
+ else {
+ command.Parameters[1].Value = ((string)(NumTask));
+ }
+ if ((CodArt == null)) {
+ command.Parameters[2].Value = global::System.DBNull.Value;
+ }
+ else {
+ command.Parameters[2].Value = ((string)(CodArt));
+ }
+ if ((QtaRic.HasValue == true)) {
+ command.Parameters[3].Value = ((int)(QtaRic.Value));
+ }
+ else {
+ command.Parameters[3].Value = global::System.DBNull.Value;
+ }
+ global::System.Data.ConnectionState previousConnectionState = command.Connection.State;
+ if (((command.Connection.State & global::System.Data.ConnectionState.Open)
+ != global::System.Data.ConnectionState.Open)) {
+ command.Connection.Open();
+ }
+ int returnValue;
+ try {
+ returnValue = command.ExecuteNonQuery();
+ }
+ finally {
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
+ command.Connection.Close();
+ }
+ }
+ return returnValue;
+ }
}
///
diff --git a/AppData/DS_App.xsd b/AppData/DS_App.xsd
index 0121528..b74eb2b 100644
--- a/AppData/DS_App.xsd
+++ b/AppData/DS_App.xsd
@@ -86,13 +86,39 @@ SELECT NumTask, CodArt, QtaRic, Prior, Concluso, DataIns, DataStart, CurrStatus
-
+
- dbo.stp_TL_GetByStatus
+ dbo.stp_TL_deleteQuery
+
+
+
+
+
+
+
+
+
+
+ dbo.stp_TL_GetByFilt
+
+
+
+
+
+
+
+
+
+ dbo.stp_TL_insertQuery
+
+
+
+
+
diff --git a/AppData/DS_App.xss b/AppData/DS_App.xss
index 192d67b..ce4b176 100644
--- a/AppData/DS_App.xss
+++ b/AppData/DS_App.xss
@@ -6,7 +6,7 @@
-->
-
+
\ No newline at end of file
diff --git a/AppData/dataLayer.cs b/AppData/dataLayer.cs
new file mode 100644
index 0000000..d3942ad
--- /dev/null
+++ b/AppData/dataLayer.cs
@@ -0,0 +1,42 @@
+using SteamWare;
+
+namespace AppData
+{
+ public class dataLayer
+ {
+ ///
+ /// avvio classe
+ ///
+ protected dataLayer()
+ {
+ avvioTA();
+ setupConnectionStringBase();
+ }
+ ///
+ /// avvia table adapters
+ ///
+ private void avvioTA()
+ {
+ // avvio i table adapters...
+ taTL = new DS_AppTableAdapters.TaskListTableAdapter();
+ }
+ ///
+ /// effettua setup dei connection strings da web.config delal singola applicazione
+ ///
+ protected virtual void setupConnectionStringBase()
+ {
+ string connString = memLayer.ML.confReadString("CTrackConnectionString");
+ // connections strings del db
+ taTL.Connection.ConnectionString = connString;
+ }
+
+
+ public DS_AppTableAdapters.TaskListTableAdapter taTL;
+ ///
+ /// singleton classe
+ ///
+ public static dataLayer man = new dataLayer();
+
+
+ }
+}
diff --git a/C-TRACK/C-TRACK.csproj b/C-TRACK/C-TRACK.csproj
index 6f76805..3322ce8 100644
--- a/C-TRACK/C-TRACK.csproj
+++ b/C-TRACK/C-TRACK.csproj
@@ -258,6 +258,7 @@
+
@@ -445,6 +446,13 @@
Bootstrap.Master
+
+ mod_addTask.ascx
+ ASPXCodeBehind
+
+
+ mod_addTask.ascx
+
mod_barcode.ascx
ASPXCodeBehind
diff --git a/C-TRACK/Web.config b/C-TRACK/Web.config
index df40b99..995db41 100644
--- a/C-TRACK/Web.config
+++ b/C-TRACK/Web.config
@@ -88,7 +88,8 @@
-
+
+
diff --git a/C-TRACK/WebUserControls/mod_addTask.ascx b/C-TRACK/WebUserControls/mod_addTask.ascx
new file mode 100644
index 0000000..6d29d0c
--- /dev/null
+++ b/C-TRACK/WebUserControls/mod_addTask.ascx
@@ -0,0 +1,26 @@
+<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_addTask.ascx.cs" Inherits="C_TRACK.WebUserControls.mod_addTask" %>
+
diff --git a/C-TRACK/WebUserControls/mod_addTask.ascx.cs b/C-TRACK/WebUserControls/mod_addTask.ascx.cs
new file mode 100644
index 0000000..dba6471
--- /dev/null
+++ b/C-TRACK/WebUserControls/mod_addTask.ascx.cs
@@ -0,0 +1,174 @@
+using AppData;
+using SteamWare;
+using System;
+using System.Text.RegularExpressions;
+
+namespace C_TRACK.WebUserControls
+{
+ public partial class mod_addTask : System.Web.UI.UserControl
+ {
+ ///
+ /// evento aggiunta record
+ ///
+ public event EventHandler eh_created;
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (!Page.IsPostBack)
+ {
+ CodArticolo = "";
+ NumTask = "";
+ Quantita = 0;
+ }
+ checkValori();
+ }
+
+ private void checkValori()
+ {
+ // verifica quali valori siano disponibili e di conseguenza visualizza COLORE...
+ lblCodArt.CssClass = CodArticolo != "" ? "text-success" : "text-secondary";
+ lblNumTask.CssClass = NumTask != "" ? "text-success" : "text-secondary";
+ lblQta.CssClass = Quantita > 0 ? "text-success" : "text-secondary";
+ }
+ ///
+ /// RegExp x Cod ARTICOLO
+ ///
+ protected string reCodArt = memLayer.ML.cdv("regExp_CodArt");
+ ///
+ /// RegExp x Cod COMMESSA
+ ///
+ protected string reNumTask = memLayer.ML.cdv("regExp_NumTask");
+ ///
+ /// RegExp x QTA
+ ///
+ protected string reQta = memLayer.ML.cdv("regExp_QtaRic");
+ ///
+ /// RegExp x RESET / CANCEL
+ ///
+ protected string reReset = memLayer.ML.cdv("regExp_KO");
+ ///
+ /// RegExp x CONFERMA
+ ///
+ protected string reAddNew = memLayer.ML.cdv("regExp_OK");
+ ///
+ /// RegExp x CONFERMA
+ ///
+ protected string reDelete = memLayer.ML.cdv("regExp_DEL");
+ ///
+ /// Input da processare...
+ ///
+ public string newInput
+ {
+ set
+ {
+ processInput(value);
+ }
+ }
+ ///
+ /// Effettua riconoscimento input e determina valori commessa / articolo / qta
+ ///
+ ///
+ private void processInput(string value)
+ {
+ // verifico se sia un articolo...
+ var testReset = Regex.Match(value, reReset);
+ var testDelete = Regex.Match(value, reDelete);
+ var testAddNew = Regex.Match(value, reAddNew);
+ var testCodArt = Regex.Match(value, reCodArt);
+ var testNumTask = Regex.Match(value, reNumTask);
+ var testQta = Regex.Match(value, reQta);
+
+ if (testReset.Success)
+ {
+ CodArticolo = "";
+ NumTask = "";
+ Quantita = 0;
+ }
+ else if (testDelete.Success)
+ {
+ // creo...
+ dataLayer.man.taTL.deleteQuery(NumTask);
+ // resetto!
+ CodArticolo = "";
+ NumTask = "";
+ Quantita = 0;
+ // invoco update...
+ if (eh_created != null)
+ {
+ eh_created(this, new EventArgs());
+ }
+ }
+ else if (testAddNew.Success)
+ {
+ // creo...
+ dataLayer.man.taTL.insertQuery(NumTask, CodArticolo, Quantita);
+ // resetto!
+ CodArticolo = "";
+ NumTask = "";
+ Quantita = 0;
+ // invoco update...
+ if (eh_created != null)
+ {
+ eh_created(this, new EventArgs());
+ }
+ }
+ else if (testCodArt.Success)
+ {
+ CodArticolo = value;
+ }
+ else if (testNumTask.Success)
+ {
+ NumTask = value;
+ }
+ else if (testQta.Success)
+ {
+ int qta = 0;
+ int.TryParse(value, out qta);
+ Quantita = qta;
+ }
+ checkValori();
+ }
+
+ ///
+ /// Cod ARTICOLO corrente
+ ///
+ public string CodArticolo
+ {
+ get
+ {
+ return memLayer.ML.StringSessionObj("currCodArt");
+ }
+ set
+ {
+ memLayer.ML.setSessionVal("currCodArt", value);
+ }
+ }
+ ///
+ /// Cod COMMESSA corrente
+ ///
+ public string NumTask
+ {
+ get
+ {
+ return memLayer.ML.StringSessionObj("currNumTask");
+ }
+ set
+ {
+ memLayer.ML.setSessionVal("currNumTask", value);
+ }
+ }
+ ///
+ /// QTA da produrre
+ ///
+ public int Quantita
+ {
+ get
+ {
+ return memLayer.ML.IntSessionObj("currQta");
+ }
+ set
+ {
+ memLayer.ML.setSessionVal("currQta", value);
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/C-TRACK/WebUserControls/mod_addTask.ascx.designer.cs b/C-TRACK/WebUserControls/mod_addTask.ascx.designer.cs
new file mode 100644
index 0000000..69d4562
--- /dev/null
+++ b/C-TRACK/WebUserControls/mod_addTask.ascx.designer.cs
@@ -0,0 +1,78 @@
+//------------------------------------------------------------------------------
+//
+// Codice generato da uno strumento.
+//
+// Le modifiche a questo file possono causare un comportamento non corretto e verranno perse se
+// il codice viene rigenerato.
+//
+//------------------------------------------------------------------------------
+
+namespace C_TRACK.WebUserControls {
+
+
+ public partial class mod_addTask {
+
+ ///
+ /// Controllo divAddNew.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlGenericControl divAddNew;
+
+ ///
+ /// Controllo lblCodArt.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.Label lblCodArt;
+
+ ///
+ /// Controllo lblNumTask.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.Label lblNumTask;
+
+ ///
+ /// Controllo lblQta.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.Label lblQta;
+
+ ///
+ /// Controllo valCodArt.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.Label valCodArt;
+
+ ///
+ /// Controllo valNumTask.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.Label valNumTask;
+
+ ///
+ /// Controllo valQta.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.Label valQta;
+ }
+}
diff --git a/C-TRACK/WebUserControls/mod_barcode.ascx.cs b/C-TRACK/WebUserControls/mod_barcode.ascx.cs
index 1d663cb..3e367fa 100644
--- a/C-TRACK/WebUserControls/mod_barcode.ascx.cs
+++ b/C-TRACK/WebUserControls/mod_barcode.ascx.cs
@@ -41,6 +41,29 @@ namespace C_TRACK.WebUserControls
}
}
///
+ /// oggetto comando locale alla classe
+ ///
+ public string rawInput
+ {
+ get
+ {
+ string answ;
+ if (memLayer.ML.isInSessionObject("barcodeRaw"))
+ {
+ answ = memLayer.ML.StringSessionObj("barcodeRaw");
+ }
+ else
+ {
+ answ = "";
+ }
+ return answ;
+ }
+ set
+ {
+ memLayer.ML.setSessionVal("barcodeRaw", value, false);
+ }
+ }
+ ///
/// al caricamento della pagina...
///
///
@@ -118,6 +141,11 @@ namespace C_TRACK.WebUserControls
lblInput.Text = traduci("ComandoSconosciuto");
lblValore.Text = BCodeVal;
comando = new inputComando();
+ rawInput = BCodeVal;
+ if (eh_dataRead != null)
+ {
+ eh_dataRead(this, new EventArgs());
+ }
}
BCodeVal = "";
}
@@ -212,6 +240,10 @@ namespace C_TRACK.WebUserControls
///
public event EventHandler eh_comandoRegistrato;
///
+ /// evento lettura dati (grezza) effettuata
+ ///
+ public event EventHandler eh_dataRead;
+ ///
/// comando registrato dal barcode
///
public inputComando comandoRegistrato
diff --git a/C-TRACK/WebUserControls/mod_taskList.ascx b/C-TRACK/WebUserControls/mod_taskList.ascx
index 4a45306..6b0efd0 100644
--- a/C-TRACK/WebUserControls/mod_taskList.ascx
+++ b/C-TRACK/WebUserControls/mod_taskList.ascx
@@ -3,9 +3,6 @@
-
@@ -19,11 +16,6 @@
[0] Tutti
-
@@ -40,12 +32,17 @@
-
+
-
+
+
+
+
+
+
\ No newline at end of file
diff --git a/C-TRACK/WebUserControls/mod_taskList.ascx.cs b/C-TRACK/WebUserControls/mod_taskList.ascx.cs
index d7ead46..5fcdad7 100644
--- a/C-TRACK/WebUserControls/mod_taskList.ascx.cs
+++ b/C-TRACK/WebUserControls/mod_taskList.ascx.cs
@@ -6,44 +6,48 @@ namespace C_TRACK.WebUserControls
{
public partial class mod_taskList : System.Web.UI.UserControl
{
+ ///
+ /// Gestione load pagina
+ ///
+ ///
+ ///
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
statusFiter = 0;
- checkAddNew();
- divBCode.Visible = false;
}
- mod_barcode.eh_comandoRegistrato += Mod_barcode_eh_comandoRegistrato;
}
- private void Mod_barcode_eh_comandoRegistrato(object sender, EventArgs e)
+ public void doUpdate()
{
- // verifico cosa ho registrato..
+ // aggiorno!
+ grView.DataBind();
}
///
- /// verifica utente x possibilità fare "add new"
+ /// codice commessa in elaborazione
///
- private void checkAddNew()
- {
- lbAddNew.Visible = devicesAuthProxy.stObj.userHasRight("CT_userStart");
- }
-
- public string testoAddNew
+ protected string codCommessa
{
get
{
- string answ = "Add New";
- if (divBCode.Visible)
+ string answ;
+ if (memLayer.ML.isInSessionObject("barcodeRaw"))
{
- answ = "Nascondi Add New";
+ answ = memLayer.ML.StringSessionObj("barcodeRaw");
+ }
+ else
+ {
+ answ = "";
}
-
return answ;
}
+ set
+ {
+ memLayer.ML.setSessionVal("barcodeRaw", value, false);
+ }
}
-
///
/// Filtro stato comemssa
///
@@ -82,9 +86,5 @@ namespace C_TRACK.WebUserControls
statusFiter = 0;
}
- protected void lbAddNew_Click(object sender, EventArgs e)
- {
- divBCode.Visible = !divBCode.Visible;
- }
}
}
\ No newline at end of file
diff --git a/C-TRACK/WebUserControls/mod_taskList.ascx.designer.cs b/C-TRACK/WebUserControls/mod_taskList.ascx.designer.cs
index d7245d1..5283ddc 100644
--- a/C-TRACK/WebUserControls/mod_taskList.ascx.designer.cs
+++ b/C-TRACK/WebUserControls/mod_taskList.ascx.designer.cs
@@ -12,15 +12,6 @@ namespace C_TRACK.WebUserControls {
public partial class mod_taskList {
- ///
- /// Controllo lbAddNew.
- ///
- ///
- /// Campo generato automaticamente.
- /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
- ///
- protected global::System.Web.UI.WebControls.LinkButton lbAddNew;
-
///
/// Controllo lbCaricati.
///
@@ -57,24 +48,6 @@ namespace C_TRACK.WebUserControls {
///
protected global::System.Web.UI.WebControls.LinkButton lbTutti;
- ///
- /// Controllo divBCode.
- ///
- ///
- /// Campo generato automaticamente.
- /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
- ///
- protected global::System.Web.UI.HtmlControls.HtmlGenericControl divBCode;
-
- ///
- /// Controllo mod_barcode.
- ///
- ///
- /// Campo generato automaticamente.
- /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
- ///
- protected global::C_TRACK.WebUserControls.mod_barcode mod_barcode;
-
///
/// Controllo grView.
///
@@ -93,6 +66,24 @@ namespace C_TRACK.WebUserControls {
///
protected global::System.Web.UI.WebControls.HiddenField hfCurrStatus;
+ ///
+ /// Controllo hfCodArt.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.HiddenField hfCodArt;
+
+ ///
+ /// Controllo hfNumTask.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.WebControls.HiddenField hfNumTask;
+
///
/// Controllo ods.
///
diff --git a/C-TRACK/task.aspx b/C-TRACK/task.aspx
index 6d6dd8c..bb54b2d 100644
--- a/C-TRACK/task.aspx
+++ b/C-TRACK/task.aspx
@@ -1,9 +1,15 @@
<%@ Page Title="" Language="C#" MasterPageFile="~/WebMasterPages/Bootstrap.Master" AutoEventWireup="true" CodeBehind="task.aspx.cs" Inherits="C_TRACK.task" %>
<%@ Register Src="~/WebUserControls/mod_taskList.ascx" TagPrefix="uc1" TagName="mod_taskList" %>
+<%@ Register Src="~/WebUserControls/mod_barcode.ascx" TagPrefix="uc1" TagName="mod_barcode" %>
+<%@ Register Src="~/WebUserControls/mod_addTask.ascx" TagPrefix="uc1" TagName="mod_addTask" %>
+
+
-
+
+
+
diff --git a/C-TRACK/task.aspx.cs b/C-TRACK/task.aspx.cs
index 6d7d66b..028c24f 100644
--- a/C-TRACK/task.aspx.cs
+++ b/C-TRACK/task.aspx.cs
@@ -1,9 +1,5 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Web;
-using System.Web.UI;
-using System.Web.UI.WebControls;
+using SteamWare;
+using System;
namespace C_TRACK
{
@@ -11,7 +7,24 @@ namespace C_TRACK
{
protected void Page_Load(object sender, EventArgs e)
{
-
+ if (!Page.IsPostBack)
+ {
+ mod_barcode.Visible = devicesAuthProxy.stObj.userHasRight("CT_userStart");
+ }
+ mod_barcode.eh_dataRead += Mod_barcode_eh_dataRead;
+ mod_addTask.eh_created += Mod_addTask_eh_created;
}
+
+ private void Mod_addTask_eh_created(object sender, EventArgs e)
+ {
+ mod_taskList.doUpdate();
+ }
+
+ private void Mod_barcode_eh_dataRead(object sender, EventArgs e)
+ {
+ // passo il dato grezzo al modulo processing commessa...
+ mod_addTask.newInput = mod_barcode.rawInput;
+ }
+
}
}
\ No newline at end of file
diff --git a/C-TRACK/task.aspx.designer.cs b/C-TRACK/task.aspx.designer.cs
index 31e1806..4c6e962 100644
--- a/C-TRACK/task.aspx.designer.cs
+++ b/C-TRACK/task.aspx.designer.cs
@@ -12,6 +12,24 @@ namespace C_TRACK {
public partial class task {
+ ///
+ /// Controllo mod_barcode.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::C_TRACK.WebUserControls.mod_barcode mod_barcode;
+
+ ///
+ /// Controllo mod_addTask.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::C_TRACK.WebUserControls.mod_addTask mod_addTask;
+
///
/// Controllo mod_taskList.
///