..
This commit is contained in:
75
SubProject/FCM0000/dsMSSQL.Designer.cs
generated
75
SubProject/FCM0000/dsMSSQL.Designer.cs
generated
@@ -1005,7 +1005,7 @@ namespace FCM0000 {
|
||||
this.columncate.MaxLength = 50;
|
||||
this.columnscale.DefaultValue = ((double)(1D));
|
||||
this.columnunit.DefaultValue = ((string)("EA"));
|
||||
this.columnunit.MaxLength = 10;
|
||||
this.columnunit.MaxLength = 50;
|
||||
this.columnimport.MaxLength = 1;
|
||||
this.columngcode.MaxLength = 10;
|
||||
}
|
||||
@@ -9803,7 +9803,7 @@ SELECT idx, name, sid, model, manu, supply, price, memo, wuid, wdate, cate, supp
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cate", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, "cate", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@supplyidx", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "supplyidx", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@scale", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "scale", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@unit", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "unit", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@unit", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, "unit", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@disable", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 0, 0, "disable", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@bparam1", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 0, 0, "bparam1", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@iparam1", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "iparam1", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
@@ -9823,7 +9823,7 @@ SELECT idx, name, sid, model, manu, supply, price, memo, wuid, wdate, cate, supp
|
||||
[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[9];
|
||||
this._commandCollection = new global::System.Data.SqlClient.SqlCommand[10];
|
||||
this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[0].Connection = this.Connection;
|
||||
this._commandCollection[0].CommandText = "SELECT idx, name, sid, model, manu, supply, price, memo, wuid, wdate, cate, supp" +
|
||||
@@ -9898,6 +9898,17 @@ ORDER BY name, idx";
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@name", global::System.Data.SqlDbType.NVarChar, 1024, global::System.Data.ParameterDirection.Input, 0, 0, "", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@model", global::System.Data.SqlDbType.NVarChar, 1024, global::System.Data.ParameterDirection.Input, 0, 0, "", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9] = new global::System.Data.SqlClient.SqlCommand();
|
||||
this._commandCollection[9].Connection = this.Connection;
|
||||
this._commandCollection[9].CommandText = "UPDATE Items\r\nSET name = @name, model = @model, unit = @unit, disable = @d" +
|
||||
"isable\r\nWHERE (gcode = @gcode) AND (sid = @Original_sid)";
|
||||
this._commandCollection[9].CommandType = global::System.Data.CommandType.Text;
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@name", global::System.Data.SqlDbType.NVarChar, 200, global::System.Data.ParameterDirection.Input, 0, 0, "name", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@model", global::System.Data.SqlDbType.NVarChar, 200, global::System.Data.ParameterDirection.Input, 0, 0, "model", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@unit", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "unit", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@disable", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 0, 0, "disable", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@gcode", global::System.Data.SqlDbType.VarChar, 10, global::System.Data.ParameterDirection.Input, 0, 0, "gcode", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
||||
this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_sid", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, "sid", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
||||
}
|
||||
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
@@ -10602,6 +10613,64 @@ ORDER BY name, idx";
|
||||
return new global::System.Nullable<int>(((int)(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 UpdateMatrial(string name, string model, string unit, global::System.Nullable<bool> disable, string gcode, string Original_sid) {
|
||||
global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[9];
|
||||
if ((name == null)) {
|
||||
command.Parameters[0].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[0].Value = ((string)(name));
|
||||
}
|
||||
if ((model == null)) {
|
||||
command.Parameters[1].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[1].Value = ((string)(model));
|
||||
}
|
||||
if ((unit == null)) {
|
||||
command.Parameters[2].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[2].Value = ((string)(unit));
|
||||
}
|
||||
if ((disable.HasValue == true)) {
|
||||
command.Parameters[3].Value = ((bool)(disable.Value));
|
||||
}
|
||||
else {
|
||||
command.Parameters[3].Value = global::System.DBNull.Value;
|
||||
}
|
||||
if ((gcode == null)) {
|
||||
command.Parameters[4].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[4].Value = ((string)(gcode));
|
||||
}
|
||||
if ((Original_sid == null)) {
|
||||
command.Parameters[5].Value = global::System.DBNull.Value;
|
||||
}
|
||||
else {
|
||||
command.Parameters[5].Value = ((string)(Original_sid));
|
||||
}
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user