COmpeltato test preliminare con chiusura, DA TESTARE CHE SIA DAVVERO CHIUSA
This commit is contained in:
Generated
+51
-17
@@ -5013,7 +5013,7 @@ namespace AppData.DS_AppTableAdapters {
|
||||
[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[5];
|
||||
this._commandCollection = new global::System.Data.SqlClient.SqlCommand[6];
|
||||
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, NumRec, CurrStatus FROM" +
|
||||
@@ -5021,32 +5021,38 @@ namespace AppData.DS_AppTableAdapters {
|
||||
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_deleteQuery";
|
||||
this._commandCollection[1].CommandText = "dbo.stp_TL_close";
|
||||
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("@Original_NumTask", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 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].CommandText = "dbo.stp_TL_deleteQuery";
|
||||
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[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_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_GetLastNumDD";
|
||||
this._commandCollection[3].CommandText = "dbo.stp_TL_GetByFilt";
|
||||
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("@LastDD", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[3].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[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("@NumTask", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[4] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[4].Connection = this.Connection;
|
||||
this._commandCollection[4].CommandText = "dbo.stp_TL_insertQuery";
|
||||
this._commandCollection[4].CommandText = "dbo.stp_TL_GetLastNumDD";
|
||||
this._commandCollection[4].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[4].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[4].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[4].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[4].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, "", "", ""));
|
||||
this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@LastDD", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[5] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[5].Connection = this.Connection;
|
||||
this._commandCollection[5].CommandText = "dbo.stp_TL_insertQuery";
|
||||
this._commandCollection[5].CommandType = global::System.Data.CommandType.StoredProcedure;
|
||||
this._commandCollection[5].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[5].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[5].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[5].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()]
|
||||
@@ -5078,7 +5084,7 @@ namespace AppData.DS_AppTableAdapters {
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)]
|
||||
public virtual DS_App.TaskListDataTable getByFilt(global::System.Nullable<int> CurrStatus, string CodArt, string NumTask) {
|
||||
this.Adapter.SelectCommand = this.CommandCollection[2];
|
||||
this.Adapter.SelectCommand = this.CommandCollection[3];
|
||||
if ((CurrStatus.HasValue == true)) {
|
||||
this.Adapter.SelectCommand.Parameters[1].Value = ((int)(CurrStatus.Value));
|
||||
}
|
||||
@@ -5107,7 +5113,7 @@ namespace AppData.DS_AppTableAdapters {
|
||||
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
||||
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)]
|
||||
public virtual DS_App.TaskListDataTable getLastNumDD(global::System.Nullable<int> LastDD) {
|
||||
this.Adapter.SelectCommand = this.CommandCollection[3];
|
||||
this.Adapter.SelectCommand = this.CommandCollection[4];
|
||||
if ((LastDD.HasValue == true)) {
|
||||
this.Adapter.SelectCommand.Parameters[1].Value = ((int)(LastDD.Value));
|
||||
}
|
||||
@@ -5314,8 +5320,36 @@ namespace AppData.DS_AppTableAdapters {
|
||||
[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 Original_NumTask) {
|
||||
public virtual int close(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 deleteQuery(string Original_NumTask) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[2];
|
||||
if ((Original_NumTask == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
@@ -5343,7 +5377,7 @@ namespace AppData.DS_AppTableAdapters {
|
||||
[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<int> QtaRic) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[4];
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[5];
|
||||
if ((NumTask == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
|
||||
@@ -80,6 +80,17 @@
|
||||
<Mapping SourceColumn="NumRec" DataSetColumn="NumRec" />
|
||||
</Mappings>
|
||||
<Sources>
|
||||
<DbSource ConnectionRef="C_TRACKConnectionString (Settings)" DbObjectName="C_TRACK.dbo.stp_TL_close" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="close" Modifier="Public" Name="close" QueryType="NoData" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy2" UserSourceName="close">
|
||||
<SelectCommand>
|
||||
<DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
|
||||
<CommandText>dbo.stp_TL_close</CommandText>
|
||||
<Parameters>
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="int" DbType="Int32" Direction="ReturnValue" ParameterName="@RETURN_VALUE" Precision="10" ProviderType="Int" Scale="0" Size="4" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
<Parameter AllowDbNull="true" AutogeneratedName="" DataSourceName="" DataTypeServer="nvarchar" DbType="String" Direction="Input" ParameterName="@NumTask" Precision="0" ProviderType="NVarChar" Scale="0" Size="50" SourceColumnNullMapping="false" SourceVersion="Current" />
|
||||
</Parameters>
|
||||
</DbCommand>
|
||||
</SelectCommand>
|
||||
</DbSource>
|
||||
<DbSource ConnectionRef="C_TRACKConnectionString (Settings)" DbObjectName="C_TRACK.dbo.stp_TL_deleteQuery" DbObjectType="StoredProcedure" GenerateShortCommands="true" GeneratorSourceName="deleteQuery" Modifier="Public" Name="deleteQuery" QueryType="NoData" ScalarCallRetval="System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetDataBy1" UserSourceName="deleteQuery">
|
||||
<SelectCommand>
|
||||
<DbCommand CommandType="StoredProcedure" ModifiedByUser="false">
|
||||
|
||||
@@ -553,6 +553,15 @@ namespace C_TRACK
|
||||
{
|
||||
// se è un comando di fase --> registro INIZIO!
|
||||
dataLayer.man.taTR.insertQuery(CodOpr, CodPost, CurrNumTask, mod_barcode1.comandoRegistrato.prevCmdIn, DateTime.Now);
|
||||
// controllo se sia fase di CHIUSURA DEFINITIVA registro con INIZIO e FINE insieme e CHIUDO commessa...
|
||||
var rigaFase = dataLayer.man.taAF.getByKey(mod_barcode1.comandoRegistrato.prevCmdIn)[0];
|
||||
if(rigaFase.CloseTask)
|
||||
{
|
||||
// chiudo direttamente SIA fase che il TASK principale...
|
||||
dataLayer.man.taTL.close(CurrNumTask);
|
||||
// tolgo comm corrente...
|
||||
CurrNumTask = "";
|
||||
}
|
||||
Response.Redirect("~/barcode");
|
||||
}
|
||||
#if false
|
||||
|
||||
Reference in New Issue
Block a user