|
@@ -0,0 +1,4655 @@
|
|
|
+//------------------------------------------------------------------------------
|
|
|
+// <auto-generated>
|
|
|
+// Этот код создан программой.
|
|
|
+// Исполняемая версия:4.0.30319.42000
|
|
|
+//
|
|
|
+// Изменения в этом файле могут привести к неправильной работе и будут потеряны в случае
|
|
|
+// повторной генерации кода.
|
|
|
+// </auto-generated>
|
|
|
+//------------------------------------------------------------------------------
|
|
|
+
|
|
|
+#pragma warning disable 1591
|
|
|
+
|
|
|
+namespace Lyakhov_Bilet10 {
|
|
|
+
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents a strongly typed in-memory cache of data.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Serializable()]
|
|
|
+ [global::System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
|
+ [global::System.ComponentModel.ToolboxItem(true)]
|
|
|
+ [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedDataSetSchema")]
|
|
|
+ [global::System.Xml.Serialization.XmlRootAttribute("Lyakhov_Bilet10DataSet")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.DataSet")]
|
|
|
+ public partial class Lyakhov_Bilet10DataSet : global::System.Data.DataSet {
|
|
|
+
|
|
|
+ private ЗаказDataTable tableЗаказ;
|
|
|
+
|
|
|
+ private История_продажиDataTable tableИстория_продажи;
|
|
|
+
|
|
|
+ private КлиентыDataTable tableКлиенты;
|
|
|
+
|
|
|
+ private ТоварыDataTable tableТовары;
|
|
|
+
|
|
|
+ private View_1DataTable tableView_1;
|
|
|
+
|
|
|
+ private global::System.Data.DataRelation relationFK_Заказ_Клиенты;
|
|
|
+
|
|
|
+ private global::System.Data.DataRelation relationFK_Заказ_Товары;
|
|
|
+
|
|
|
+ private global::System.Data.DataRelation relationFK_История_продажи_Товары;
|
|
|
+
|
|
|
+ private global::System.Data.SchemaSerializationMode _schemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public Lyakhov_Bilet10DataSet() {
|
|
|
+ this.BeginInit();
|
|
|
+ this.InitClass();
|
|
|
+ global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
|
|
|
+ base.Tables.CollectionChanged += schemaChangedHandler;
|
|
|
+ base.Relations.CollectionChanged += schemaChangedHandler;
|
|
|
+ this.EndInit();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected Lyakhov_Bilet10DataSet(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
|
|
|
+ base(info, context, false) {
|
|
|
+ if ((this.IsBinarySerialized(info, context) == true)) {
|
|
|
+ this.InitVars(false);
|
|
|
+ global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler1 = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
|
|
|
+ this.Tables.CollectionChanged += schemaChangedHandler1;
|
|
|
+ this.Relations.CollectionChanged += schemaChangedHandler1;
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
|
|
|
+ if ((this.DetermineSchemaSerializationMode(info, context) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
|
|
|
+ global::System.Data.DataSet ds = new global::System.Data.DataSet();
|
|
|
+ ds.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
|
|
|
+ if ((ds.Tables["Заказ"] != null)) {
|
|
|
+ base.Tables.Add(new ЗаказDataTable(ds.Tables["Заказ"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["История продажи"] != null)) {
|
|
|
+ base.Tables.Add(new История_продажиDataTable(ds.Tables["История продажи"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["Клиенты"] != null)) {
|
|
|
+ base.Tables.Add(new КлиентыDataTable(ds.Tables["Клиенты"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["Товары"] != null)) {
|
|
|
+ base.Tables.Add(new ТоварыDataTable(ds.Tables["Товары"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["View_1"] != null)) {
|
|
|
+ base.Tables.Add(new View_1DataTable(ds.Tables["View_1"]));
|
|
|
+ }
|
|
|
+ this.DataSetName = ds.DataSetName;
|
|
|
+ this.Prefix = ds.Prefix;
|
|
|
+ this.Namespace = ds.Namespace;
|
|
|
+ this.Locale = ds.Locale;
|
|
|
+ this.CaseSensitive = ds.CaseSensitive;
|
|
|
+ this.EnforceConstraints = ds.EnforceConstraints;
|
|
|
+ this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
|
|
|
+ }
|
|
|
+ this.GetSerializationData(info, context);
|
|
|
+ global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
|
|
|
+ base.Tables.CollectionChanged += schemaChangedHandler;
|
|
|
+ this.Relations.CollectionChanged += schemaChangedHandler;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
|
|
|
+ public ЗаказDataTable Заказ {
|
|
|
+ get {
|
|
|
+ return this.tableЗаказ;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
|
|
|
+ public История_продажиDataTable История_продажи {
|
|
|
+ get {
|
|
|
+ return this.tableИстория_продажи;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
|
|
|
+ public КлиентыDataTable Клиенты {
|
|
|
+ get {
|
|
|
+ return this.tableКлиенты;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
|
|
|
+ public ТоварыDataTable Товары {
|
|
|
+ get {
|
|
|
+ return this.tableТовары;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
|
|
|
+ public View_1DataTable View_1 {
|
|
|
+ get {
|
|
|
+ return this.tableView_1;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.BrowsableAttribute(true)]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Visible)]
|
|
|
+ public override global::System.Data.SchemaSerializationMode SchemaSerializationMode {
|
|
|
+ get {
|
|
|
+ return this._schemaSerializationMode;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._schemaSerializationMode = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
|
|
|
+ public new global::System.Data.DataTableCollection Tables {
|
|
|
+ get {
|
|
|
+ return base.Tables;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
|
|
|
+ public new global::System.Data.DataRelationCollection Relations {
|
|
|
+ get {
|
|
|
+ return base.Relations;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void InitializeDerivedDataSet() {
|
|
|
+ this.BeginInit();
|
|
|
+ this.InitClass();
|
|
|
+ this.EndInit();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public override global::System.Data.DataSet Clone() {
|
|
|
+ Lyakhov_Bilet10DataSet cln = ((Lyakhov_Bilet10DataSet)(base.Clone()));
|
|
|
+ cln.InitVars();
|
|
|
+ cln.SchemaSerializationMode = this.SchemaSerializationMode;
|
|
|
+ return cln;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override bool ShouldSerializeTables() {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override bool ShouldSerializeRelations() {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void ReadXmlSerializable(global::System.Xml.XmlReader reader) {
|
|
|
+ if ((this.DetermineSchemaSerializationMode(reader) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
|
|
|
+ this.Reset();
|
|
|
+ global::System.Data.DataSet ds = new global::System.Data.DataSet();
|
|
|
+ ds.ReadXml(reader);
|
|
|
+ if ((ds.Tables["Заказ"] != null)) {
|
|
|
+ base.Tables.Add(new ЗаказDataTable(ds.Tables["Заказ"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["История продажи"] != null)) {
|
|
|
+ base.Tables.Add(new История_продажиDataTable(ds.Tables["История продажи"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["Клиенты"] != null)) {
|
|
|
+ base.Tables.Add(new КлиентыDataTable(ds.Tables["Клиенты"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["Товары"] != null)) {
|
|
|
+ base.Tables.Add(new ТоварыDataTable(ds.Tables["Товары"]));
|
|
|
+ }
|
|
|
+ if ((ds.Tables["View_1"] != null)) {
|
|
|
+ base.Tables.Add(new View_1DataTable(ds.Tables["View_1"]));
|
|
|
+ }
|
|
|
+ this.DataSetName = ds.DataSetName;
|
|
|
+ this.Prefix = ds.Prefix;
|
|
|
+ this.Namespace = ds.Namespace;
|
|
|
+ this.Locale = ds.Locale;
|
|
|
+ this.CaseSensitive = ds.CaseSensitive;
|
|
|
+ this.EnforceConstraints = ds.EnforceConstraints;
|
|
|
+ this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.ReadXml(reader);
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Xml.Schema.XmlSchema GetSchemaSerializable() {
|
|
|
+ global::System.IO.MemoryStream stream = new global::System.IO.MemoryStream();
|
|
|
+ this.WriteXmlSchema(new global::System.Xml.XmlTextWriter(stream, null));
|
|
|
+ stream.Position = 0;
|
|
|
+ return global::System.Xml.Schema.XmlSchema.Read(new global::System.Xml.XmlTextReader(stream), null);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal void InitVars() {
|
|
|
+ this.InitVars(true);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal void InitVars(bool initTable) {
|
|
|
+ this.tableЗаказ = ((ЗаказDataTable)(base.Tables["Заказ"]));
|
|
|
+ if ((initTable == true)) {
|
|
|
+ if ((this.tableЗаказ != null)) {
|
|
|
+ this.tableЗаказ.InitVars();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.tableИстория_продажи = ((История_продажиDataTable)(base.Tables["История продажи"]));
|
|
|
+ if ((initTable == true)) {
|
|
|
+ if ((this.tableИстория_продажи != null)) {
|
|
|
+ this.tableИстория_продажи.InitVars();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.tableКлиенты = ((КлиентыDataTable)(base.Tables["Клиенты"]));
|
|
|
+ if ((initTable == true)) {
|
|
|
+ if ((this.tableКлиенты != null)) {
|
|
|
+ this.tableКлиенты.InitVars();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.tableТовары = ((ТоварыDataTable)(base.Tables["Товары"]));
|
|
|
+ if ((initTable == true)) {
|
|
|
+ if ((this.tableТовары != null)) {
|
|
|
+ this.tableТовары.InitVars();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.tableView_1 = ((View_1DataTable)(base.Tables["View_1"]));
|
|
|
+ if ((initTable == true)) {
|
|
|
+ if ((this.tableView_1 != null)) {
|
|
|
+ this.tableView_1.InitVars();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.relationFK_Заказ_Клиенты = this.Relations["FK_Заказ_Клиенты"];
|
|
|
+ this.relationFK_Заказ_Товары = this.Relations["FK_Заказ_Товары"];
|
|
|
+ this.relationFK_История_продажи_Товары = this.Relations["FK_История продажи_Товары"];
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitClass() {
|
|
|
+ this.DataSetName = "Lyakhov_Bilet10DataSet";
|
|
|
+ this.Prefix = "";
|
|
|
+ this.Namespace = "http://tempuri.org/Lyakhov_Bilet10DataSet.xsd";
|
|
|
+ this.EnforceConstraints = true;
|
|
|
+ this.SchemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
|
|
|
+ this.tableЗаказ = new ЗаказDataTable();
|
|
|
+ base.Tables.Add(this.tableЗаказ);
|
|
|
+ this.tableИстория_продажи = new История_продажиDataTable();
|
|
|
+ base.Tables.Add(this.tableИстория_продажи);
|
|
|
+ this.tableКлиенты = new КлиентыDataTable();
|
|
|
+ base.Tables.Add(this.tableКлиенты);
|
|
|
+ this.tableТовары = new ТоварыDataTable();
|
|
|
+ base.Tables.Add(this.tableТовары);
|
|
|
+ this.tableView_1 = new View_1DataTable();
|
|
|
+ base.Tables.Add(this.tableView_1);
|
|
|
+ this.relationFK_Заказ_Клиенты = new global::System.Data.DataRelation("FK_Заказ_Клиенты", new global::System.Data.DataColumn[] {
|
|
|
+ this.tableКлиенты.ID_KlientaColumn}, new global::System.Data.DataColumn[] {
|
|
|
+ this.tableЗаказ.ID_KlientaColumn}, false);
|
|
|
+ this.Relations.Add(this.relationFK_Заказ_Клиенты);
|
|
|
+ this.relationFK_Заказ_Товары = new global::System.Data.DataRelation("FK_Заказ_Товары", new global::System.Data.DataColumn[] {
|
|
|
+ this.tableТовары.ID_TovaraColumn}, new global::System.Data.DataColumn[] {
|
|
|
+ this.tableЗаказ.ID_TovaraColumn}, false);
|
|
|
+ this.Relations.Add(this.relationFK_Заказ_Товары);
|
|
|
+ this.relationFK_История_продажи_Товары = new global::System.Data.DataRelation("FK_История продажи_Товары", new global::System.Data.DataColumn[] {
|
|
|
+ this.tableТовары.ID_TovaraColumn}, new global::System.Data.DataColumn[] {
|
|
|
+ this.tableИстория_продажи.ID_TovaraColumn}, false);
|
|
|
+ this.Relations.Add(this.relationFK_История_продажи_Товары);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private bool ShouldSerializeЗаказ() {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private bool ShouldSerializeИстория_продажи() {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private bool ShouldSerializeКлиенты() {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private bool ShouldSerializeТовары() {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private bool ShouldSerializeView_1() {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void SchemaChanged(object sender, global::System.ComponentModel.CollectionChangeEventArgs e) {
|
|
|
+ if ((e.Action == global::System.ComponentModel.CollectionChangeAction.Remove)) {
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedDataSetSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
|
|
|
+ Lyakhov_Bilet10DataSet ds = new Lyakhov_Bilet10DataSet();
|
|
|
+ global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
|
|
|
+ global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any.Namespace = ds.Namespace;
|
|
|
+ sequence.Items.Add(any);
|
|
|
+ type.Particle = sequence;
|
|
|
+ global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
|
|
|
+ if (xs.Contains(dsSchema.TargetNamespace)) {
|
|
|
+ global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
|
|
|
+ global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
|
|
|
+ try {
|
|
|
+ global::System.Xml.Schema.XmlSchema schema = null;
|
|
|
+ dsSchema.Write(s1);
|
|
|
+ for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
|
|
|
+ schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
|
|
|
+ s2.SetLength(0);
|
|
|
+ schema.Write(s2);
|
|
|
+ if ((s1.Length == s2.Length)) {
|
|
|
+ s1.Position = 0;
|
|
|
+ s2.Position = 0;
|
|
|
+ for (; ((s1.Position != s1.Length)
|
|
|
+ && (s1.ReadByte() == s2.ReadByte())); ) {
|
|
|
+ ;
|
|
|
+ }
|
|
|
+ if ((s1.Position == s1.Length)) {
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((s1 != null)) {
|
|
|
+ s1.Close();
|
|
|
+ }
|
|
|
+ if ((s2 != null)) {
|
|
|
+ s2.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ xs.Add(dsSchema);
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public delegate void ЗаказRowChangeEventHandler(object sender, ЗаказRowChangeEvent e);
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public delegate void История_продажиRowChangeEventHandler(object sender, История_продажиRowChangeEvent e);
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public delegate void КлиентыRowChangeEventHandler(object sender, КлиентыRowChangeEvent e);
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public delegate void ТоварыRowChangeEventHandler(object sender, ТоварыRowChangeEvent e);
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public delegate void View_1RowChangeEventHandler(object sender, View_1RowChangeEvent e);
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the strongly named DataTable class.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Serializable()]
|
|
|
+ [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
|
|
|
+ public partial class ЗаказDataTable : global::System.Data.TypedTableBase<ЗаказRow> {
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Zakaza;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnKolichestvo;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Tovara;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Klienta;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказDataTable() {
|
|
|
+ this.TableName = "Заказ";
|
|
|
+ this.BeginInit();
|
|
|
+ this.InitClass();
|
|
|
+ this.EndInit();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal ЗаказDataTable(global::System.Data.DataTable table) {
|
|
|
+ this.TableName = table.TableName;
|
|
|
+ if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
|
|
|
+ this.CaseSensitive = table.CaseSensitive;
|
|
|
+ }
|
|
|
+ if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
|
|
|
+ this.Locale = table.Locale;
|
|
|
+ }
|
|
|
+ if ((table.Namespace != table.DataSet.Namespace)) {
|
|
|
+ this.Namespace = table.Namespace;
|
|
|
+ }
|
|
|
+ this.Prefix = table.Prefix;
|
|
|
+ this.MinimumCapacity = table.MinimumCapacity;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected ЗаказDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
|
|
|
+ base(info, context) {
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_ZakazaColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Zakaza;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn KolichestvoColumn {
|
|
|
+ get {
|
|
|
+ return this.columnKolichestvo;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_TovaraColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Tovara;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_KlientaColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Klienta;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ public int Count {
|
|
|
+ get {
|
|
|
+ return this.Rows.Count;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRow this[int index] {
|
|
|
+ get {
|
|
|
+ return ((ЗаказRow)(this.Rows[index]));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ЗаказRowChangeEventHandler ЗаказRowChanging;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ЗаказRowChangeEventHandler ЗаказRowChanged;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ЗаказRowChangeEventHandler ЗаказRowDeleting;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ЗаказRowChangeEventHandler ЗаказRowDeleted;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void AddЗаказRow(ЗаказRow row) {
|
|
|
+ this.Rows.Add(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRow AddЗаказRow(int Kolichestvo, ТоварыRow parentТоварыRowByFK_Заказ_Товары, КлиентыRow parentКлиентыRowByFK_Заказ_Клиенты) {
|
|
|
+ ЗаказRow rowЗаказRow = ((ЗаказRow)(this.NewRow()));
|
|
|
+ object[] columnValuesArray = new object[] {
|
|
|
+ null,
|
|
|
+ Kolichestvo,
|
|
|
+ null,
|
|
|
+ null};
|
|
|
+ if ((parentТоварыRowByFK_Заказ_Товары != null)) {
|
|
|
+ columnValuesArray[2] = parentТоварыRowByFK_Заказ_Товары[0];
|
|
|
+ }
|
|
|
+ if ((parentКлиентыRowByFK_Заказ_Клиенты != null)) {
|
|
|
+ columnValuesArray[3] = parentКлиентыRowByFK_Заказ_Клиенты[0];
|
|
|
+ }
|
|
|
+ rowЗаказRow.ItemArray = columnValuesArray;
|
|
|
+ this.Rows.Add(rowЗаказRow);
|
|
|
+ return rowЗаказRow;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRow FindByID_Zakaza(int ID_Zakaza) {
|
|
|
+ return ((ЗаказRow)(this.Rows.Find(new object[] {
|
|
|
+ ID_Zakaza})));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public override global::System.Data.DataTable Clone() {
|
|
|
+ ЗаказDataTable cln = ((ЗаказDataTable)(base.Clone()));
|
|
|
+ cln.InitVars();
|
|
|
+ return cln;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataTable CreateInstance() {
|
|
|
+ return new ЗаказDataTable();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal void InitVars() {
|
|
|
+ this.columnID_Zakaza = base.Columns["ID_Zakaza"];
|
|
|
+ this.columnKolichestvo = base.Columns["Kolichestvo"];
|
|
|
+ this.columnID_Tovara = base.Columns["ID_Tovara"];
|
|
|
+ this.columnID_Klienta = base.Columns["ID_Klienta"];
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitClass() {
|
|
|
+ this.columnID_Zakaza = new global::System.Data.DataColumn("ID_Zakaza", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Zakaza);
|
|
|
+ this.columnKolichestvo = new global::System.Data.DataColumn("Kolichestvo", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnKolichestvo);
|
|
|
+ this.columnID_Tovara = new global::System.Data.DataColumn("ID_Tovara", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Tovara);
|
|
|
+ this.columnID_Klienta = new global::System.Data.DataColumn("ID_Klienta", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Klienta);
|
|
|
+ this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
|
|
|
+ this.columnID_Zakaza}, true));
|
|
|
+ this.columnID_Zakaza.AutoIncrement = true;
|
|
|
+ this.columnID_Zakaza.AutoIncrementSeed = -1;
|
|
|
+ this.columnID_Zakaza.AutoIncrementStep = -1;
|
|
|
+ this.columnID_Zakaza.AllowDBNull = false;
|
|
|
+ this.columnID_Zakaza.ReadOnly = true;
|
|
|
+ this.columnID_Zakaza.Unique = true;
|
|
|
+ this.columnKolichestvo.AllowDBNull = false;
|
|
|
+ this.columnID_Tovara.AllowDBNull = false;
|
|
|
+ this.columnID_Klienta.AllowDBNull = false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRow NewЗаказRow() {
|
|
|
+ return ((ЗаказRow)(this.NewRow()));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
|
|
|
+ return new ЗаказRow(builder);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Type GetRowType() {
|
|
|
+ return typeof(ЗаказRow);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanged(e);
|
|
|
+ if ((this.ЗаказRowChanged != null)) {
|
|
|
+ this.ЗаказRowChanged(this, new ЗаказRowChangeEvent(((ЗаказRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanging(e);
|
|
|
+ if ((this.ЗаказRowChanging != null)) {
|
|
|
+ this.ЗаказRowChanging(this, new ЗаказRowChangeEvent(((ЗаказRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleted(e);
|
|
|
+ if ((this.ЗаказRowDeleted != null)) {
|
|
|
+ this.ЗаказRowDeleted(this, new ЗаказRowChangeEvent(((ЗаказRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleting(e);
|
|
|
+ if ((this.ЗаказRowDeleting != null)) {
|
|
|
+ this.ЗаказRowDeleting(this, new ЗаказRowChangeEvent(((ЗаказRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void RemoveЗаказRow(ЗаказRow row) {
|
|
|
+ this.Rows.Remove(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
|
|
|
+ global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
|
|
|
+ global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
|
|
|
+ Lyakhov_Bilet10DataSet ds = new Lyakhov_Bilet10DataSet();
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any1.Namespace = "http://www.w3.org/2001/XMLSchema";
|
|
|
+ any1.MinOccurs = new decimal(0);
|
|
|
+ any1.MaxOccurs = decimal.MaxValue;
|
|
|
+ any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
|
|
|
+ any2.MinOccurs = new decimal(1);
|
|
|
+ any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any2);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute1.Name = "namespace";
|
|
|
+ attribute1.FixedValue = ds.Namespace;
|
|
|
+ type.Attributes.Add(attribute1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute2.Name = "tableTypeName";
|
|
|
+ attribute2.FixedValue = "ЗаказDataTable";
|
|
|
+ type.Attributes.Add(attribute2);
|
|
|
+ type.Particle = sequence;
|
|
|
+ global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
|
|
|
+ if (xs.Contains(dsSchema.TargetNamespace)) {
|
|
|
+ global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
|
|
|
+ global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
|
|
|
+ try {
|
|
|
+ global::System.Xml.Schema.XmlSchema schema = null;
|
|
|
+ dsSchema.Write(s1);
|
|
|
+ for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
|
|
|
+ schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
|
|
|
+ s2.SetLength(0);
|
|
|
+ schema.Write(s2);
|
|
|
+ if ((s1.Length == s2.Length)) {
|
|
|
+ s1.Position = 0;
|
|
|
+ s2.Position = 0;
|
|
|
+ for (; ((s1.Position != s1.Length)
|
|
|
+ && (s1.ReadByte() == s2.ReadByte())); ) {
|
|
|
+ ;
|
|
|
+ }
|
|
|
+ if ((s1.Position == s1.Length)) {
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((s1 != null)) {
|
|
|
+ s1.Close();
|
|
|
+ }
|
|
|
+ if ((s2 != null)) {
|
|
|
+ s2.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ xs.Add(dsSchema);
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the strongly named DataTable class.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Serializable()]
|
|
|
+ [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
|
|
|
+ public partial class История_продажиDataTable : global::System.Data.TypedTableBase<История_продажиRow> {
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Istorii;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnNazvanie;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnData_Prodaji;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Tovara;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиDataTable() {
|
|
|
+ this.TableName = "История продажи";
|
|
|
+ this.BeginInit();
|
|
|
+ this.InitClass();
|
|
|
+ this.EndInit();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal История_продажиDataTable(global::System.Data.DataTable table) {
|
|
|
+ this.TableName = table.TableName;
|
|
|
+ if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
|
|
|
+ this.CaseSensitive = table.CaseSensitive;
|
|
|
+ }
|
|
|
+ if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
|
|
|
+ this.Locale = table.Locale;
|
|
|
+ }
|
|
|
+ if ((table.Namespace != table.DataSet.Namespace)) {
|
|
|
+ this.Namespace = table.Namespace;
|
|
|
+ }
|
|
|
+ this.Prefix = table.Prefix;
|
|
|
+ this.MinimumCapacity = table.MinimumCapacity;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected История_продажиDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
|
|
|
+ base(info, context) {
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_IstoriiColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Istorii;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn NazvanieColumn {
|
|
|
+ get {
|
|
|
+ return this.columnNazvanie;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn Data_ProdajiColumn {
|
|
|
+ get {
|
|
|
+ return this.columnData_Prodaji;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_TovaraColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Tovara;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ public int Count {
|
|
|
+ get {
|
|
|
+ return this.Rows.Count;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиRow this[int index] {
|
|
|
+ get {
|
|
|
+ return ((История_продажиRow)(this.Rows[index]));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event История_продажиRowChangeEventHandler История_продажиRowChanging;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event История_продажиRowChangeEventHandler История_продажиRowChanged;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event История_продажиRowChangeEventHandler История_продажиRowDeleting;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event История_продажиRowChangeEventHandler История_продажиRowDeleted;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void AddИстория_продажиRow(История_продажиRow row) {
|
|
|
+ this.Rows.Add(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиRow AddИстория_продажиRow(string Nazvanie, System.DateTime Data_Prodaji, ТоварыRow parentТоварыRowByFK_История_продажи_Товары) {
|
|
|
+ История_продажиRow rowИстория_продажиRow = ((История_продажиRow)(this.NewRow()));
|
|
|
+ object[] columnValuesArray = new object[] {
|
|
|
+ null,
|
|
|
+ Nazvanie,
|
|
|
+ Data_Prodaji,
|
|
|
+ null};
|
|
|
+ if ((parentТоварыRowByFK_История_продажи_Товары != null)) {
|
|
|
+ columnValuesArray[3] = parentТоварыRowByFK_История_продажи_Товары[0];
|
|
|
+ }
|
|
|
+ rowИстория_продажиRow.ItemArray = columnValuesArray;
|
|
|
+ this.Rows.Add(rowИстория_продажиRow);
|
|
|
+ return rowИстория_продажиRow;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиRow FindByID_Istorii(int ID_Istorii) {
|
|
|
+ return ((История_продажиRow)(this.Rows.Find(new object[] {
|
|
|
+ ID_Istorii})));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public override global::System.Data.DataTable Clone() {
|
|
|
+ История_продажиDataTable cln = ((История_продажиDataTable)(base.Clone()));
|
|
|
+ cln.InitVars();
|
|
|
+ return cln;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataTable CreateInstance() {
|
|
|
+ return new История_продажиDataTable();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal void InitVars() {
|
|
|
+ this.columnID_Istorii = base.Columns["ID_Istorii"];
|
|
|
+ this.columnNazvanie = base.Columns["Nazvanie"];
|
|
|
+ this.columnData_Prodaji = base.Columns["Data_Prodaji"];
|
|
|
+ this.columnID_Tovara = base.Columns["ID_Tovara"];
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitClass() {
|
|
|
+ this.columnID_Istorii = new global::System.Data.DataColumn("ID_Istorii", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Istorii);
|
|
|
+ this.columnNazvanie = new global::System.Data.DataColumn("Nazvanie", typeof(string), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnNazvanie);
|
|
|
+ this.columnData_Prodaji = new global::System.Data.DataColumn("Data_Prodaji", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnData_Prodaji);
|
|
|
+ this.columnID_Tovara = new global::System.Data.DataColumn("ID_Tovara", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Tovara);
|
|
|
+ this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
|
|
|
+ this.columnID_Istorii}, true));
|
|
|
+ this.columnID_Istorii.AutoIncrement = true;
|
|
|
+ this.columnID_Istorii.AutoIncrementSeed = -1;
|
|
|
+ this.columnID_Istorii.AutoIncrementStep = -1;
|
|
|
+ this.columnID_Istorii.AllowDBNull = false;
|
|
|
+ this.columnID_Istorii.ReadOnly = true;
|
|
|
+ this.columnID_Istorii.Unique = true;
|
|
|
+ this.columnNazvanie.AllowDBNull = false;
|
|
|
+ this.columnNazvanie.MaxLength = 50;
|
|
|
+ this.columnData_Prodaji.AllowDBNull = false;
|
|
|
+ this.columnID_Tovara.AllowDBNull = false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиRow NewИстория_продажиRow() {
|
|
|
+ return ((История_продажиRow)(this.NewRow()));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
|
|
|
+ return new История_продажиRow(builder);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Type GetRowType() {
|
|
|
+ return typeof(История_продажиRow);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanged(e);
|
|
|
+ if ((this.История_продажиRowChanged != null)) {
|
|
|
+ this.История_продажиRowChanged(this, new История_продажиRowChangeEvent(((История_продажиRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanging(e);
|
|
|
+ if ((this.История_продажиRowChanging != null)) {
|
|
|
+ this.История_продажиRowChanging(this, new История_продажиRowChangeEvent(((История_продажиRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleted(e);
|
|
|
+ if ((this.История_продажиRowDeleted != null)) {
|
|
|
+ this.История_продажиRowDeleted(this, new История_продажиRowChangeEvent(((История_продажиRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleting(e);
|
|
|
+ if ((this.История_продажиRowDeleting != null)) {
|
|
|
+ this.История_продажиRowDeleting(this, new История_продажиRowChangeEvent(((История_продажиRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void RemoveИстория_продажиRow(История_продажиRow row) {
|
|
|
+ this.Rows.Remove(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
|
|
|
+ global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
|
|
|
+ global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
|
|
|
+ Lyakhov_Bilet10DataSet ds = new Lyakhov_Bilet10DataSet();
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any1.Namespace = "http://www.w3.org/2001/XMLSchema";
|
|
|
+ any1.MinOccurs = new decimal(0);
|
|
|
+ any1.MaxOccurs = decimal.MaxValue;
|
|
|
+ any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
|
|
|
+ any2.MinOccurs = new decimal(1);
|
|
|
+ any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any2);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute1.Name = "namespace";
|
|
|
+ attribute1.FixedValue = ds.Namespace;
|
|
|
+ type.Attributes.Add(attribute1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute2.Name = "tableTypeName";
|
|
|
+ attribute2.FixedValue = "История_продажиDataTable";
|
|
|
+ type.Attributes.Add(attribute2);
|
|
|
+ type.Particle = sequence;
|
|
|
+ global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
|
|
|
+ if (xs.Contains(dsSchema.TargetNamespace)) {
|
|
|
+ global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
|
|
|
+ global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
|
|
|
+ try {
|
|
|
+ global::System.Xml.Schema.XmlSchema schema = null;
|
|
|
+ dsSchema.Write(s1);
|
|
|
+ for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
|
|
|
+ schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
|
|
|
+ s2.SetLength(0);
|
|
|
+ schema.Write(s2);
|
|
|
+ if ((s1.Length == s2.Length)) {
|
|
|
+ s1.Position = 0;
|
|
|
+ s2.Position = 0;
|
|
|
+ for (; ((s1.Position != s1.Length)
|
|
|
+ && (s1.ReadByte() == s2.ReadByte())); ) {
|
|
|
+ ;
|
|
|
+ }
|
|
|
+ if ((s1.Position == s1.Length)) {
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((s1 != null)) {
|
|
|
+ s1.Close();
|
|
|
+ }
|
|
|
+ if ((s2 != null)) {
|
|
|
+ s2.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ xs.Add(dsSchema);
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the strongly named DataTable class.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Serializable()]
|
|
|
+ [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
|
|
|
+ public partial class КлиентыDataTable : global::System.Data.TypedTableBase<КлиентыRow> {
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Klienta;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnFIO;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnTelepfone;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Zakaza;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыDataTable() {
|
|
|
+ this.TableName = "Клиенты";
|
|
|
+ this.BeginInit();
|
|
|
+ this.InitClass();
|
|
|
+ this.EndInit();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal КлиентыDataTable(global::System.Data.DataTable table) {
|
|
|
+ this.TableName = table.TableName;
|
|
|
+ if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
|
|
|
+ this.CaseSensitive = table.CaseSensitive;
|
|
|
+ }
|
|
|
+ if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
|
|
|
+ this.Locale = table.Locale;
|
|
|
+ }
|
|
|
+ if ((table.Namespace != table.DataSet.Namespace)) {
|
|
|
+ this.Namespace = table.Namespace;
|
|
|
+ }
|
|
|
+ this.Prefix = table.Prefix;
|
|
|
+ this.MinimumCapacity = table.MinimumCapacity;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected КлиентыDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
|
|
|
+ base(info, context) {
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_KlientaColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Klienta;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn FIOColumn {
|
|
|
+ get {
|
|
|
+ return this.columnFIO;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn TelepfoneColumn {
|
|
|
+ get {
|
|
|
+ return this.columnTelepfone;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_ZakazaColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Zakaza;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ public int Count {
|
|
|
+ get {
|
|
|
+ return this.Rows.Count;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыRow this[int index] {
|
|
|
+ get {
|
|
|
+ return ((КлиентыRow)(this.Rows[index]));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event КлиентыRowChangeEventHandler КлиентыRowChanging;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event КлиентыRowChangeEventHandler КлиентыRowChanged;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event КлиентыRowChangeEventHandler КлиентыRowDeleting;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event КлиентыRowChangeEventHandler КлиентыRowDeleted;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void AddКлиентыRow(КлиентыRow row) {
|
|
|
+ this.Rows.Add(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыRow AddКлиентыRow(string FIO, string Telepfone, int ID_Zakaza) {
|
|
|
+ КлиентыRow rowКлиентыRow = ((КлиентыRow)(this.NewRow()));
|
|
|
+ object[] columnValuesArray = new object[] {
|
|
|
+ null,
|
|
|
+ FIO,
|
|
|
+ Telepfone,
|
|
|
+ ID_Zakaza};
|
|
|
+ rowКлиентыRow.ItemArray = columnValuesArray;
|
|
|
+ this.Rows.Add(rowКлиентыRow);
|
|
|
+ return rowКлиентыRow;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыRow FindByID_Klienta(int ID_Klienta) {
|
|
|
+ return ((КлиентыRow)(this.Rows.Find(new object[] {
|
|
|
+ ID_Klienta})));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public override global::System.Data.DataTable Clone() {
|
|
|
+ КлиентыDataTable cln = ((КлиентыDataTable)(base.Clone()));
|
|
|
+ cln.InitVars();
|
|
|
+ return cln;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataTable CreateInstance() {
|
|
|
+ return new КлиентыDataTable();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal void InitVars() {
|
|
|
+ this.columnID_Klienta = base.Columns["ID_Klienta"];
|
|
|
+ this.columnFIO = base.Columns["FIO"];
|
|
|
+ this.columnTelepfone = base.Columns["Telepfone"];
|
|
|
+ this.columnID_Zakaza = base.Columns["ID_Zakaza"];
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitClass() {
|
|
|
+ this.columnID_Klienta = new global::System.Data.DataColumn("ID_Klienta", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Klienta);
|
|
|
+ this.columnFIO = new global::System.Data.DataColumn("FIO", typeof(string), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnFIO);
|
|
|
+ this.columnTelepfone = new global::System.Data.DataColumn("Telepfone", typeof(string), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnTelepfone);
|
|
|
+ this.columnID_Zakaza = new global::System.Data.DataColumn("ID_Zakaza", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Zakaza);
|
|
|
+ this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
|
|
|
+ this.columnID_Klienta}, true));
|
|
|
+ this.columnID_Klienta.AutoIncrement = true;
|
|
|
+ this.columnID_Klienta.AutoIncrementSeed = -1;
|
|
|
+ this.columnID_Klienta.AutoIncrementStep = -1;
|
|
|
+ this.columnID_Klienta.AllowDBNull = false;
|
|
|
+ this.columnID_Klienta.ReadOnly = true;
|
|
|
+ this.columnID_Klienta.Unique = true;
|
|
|
+ this.columnFIO.AllowDBNull = false;
|
|
|
+ this.columnFIO.MaxLength = 50;
|
|
|
+ this.columnTelepfone.AllowDBNull = false;
|
|
|
+ this.columnTelepfone.MaxLength = 50;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыRow NewКлиентыRow() {
|
|
|
+ return ((КлиентыRow)(this.NewRow()));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
|
|
|
+ return new КлиентыRow(builder);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Type GetRowType() {
|
|
|
+ return typeof(КлиентыRow);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanged(e);
|
|
|
+ if ((this.КлиентыRowChanged != null)) {
|
|
|
+ this.КлиентыRowChanged(this, new КлиентыRowChangeEvent(((КлиентыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanging(e);
|
|
|
+ if ((this.КлиентыRowChanging != null)) {
|
|
|
+ this.КлиентыRowChanging(this, new КлиентыRowChangeEvent(((КлиентыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleted(e);
|
|
|
+ if ((this.КлиентыRowDeleted != null)) {
|
|
|
+ this.КлиентыRowDeleted(this, new КлиентыRowChangeEvent(((КлиентыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleting(e);
|
|
|
+ if ((this.КлиентыRowDeleting != null)) {
|
|
|
+ this.КлиентыRowDeleting(this, new КлиентыRowChangeEvent(((КлиентыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void RemoveКлиентыRow(КлиентыRow row) {
|
|
|
+ this.Rows.Remove(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
|
|
|
+ global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
|
|
|
+ global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
|
|
|
+ Lyakhov_Bilet10DataSet ds = new Lyakhov_Bilet10DataSet();
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any1.Namespace = "http://www.w3.org/2001/XMLSchema";
|
|
|
+ any1.MinOccurs = new decimal(0);
|
|
|
+ any1.MaxOccurs = decimal.MaxValue;
|
|
|
+ any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
|
|
|
+ any2.MinOccurs = new decimal(1);
|
|
|
+ any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any2);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute1.Name = "namespace";
|
|
|
+ attribute1.FixedValue = ds.Namespace;
|
|
|
+ type.Attributes.Add(attribute1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute2.Name = "tableTypeName";
|
|
|
+ attribute2.FixedValue = "КлиентыDataTable";
|
|
|
+ type.Attributes.Add(attribute2);
|
|
|
+ type.Particle = sequence;
|
|
|
+ global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
|
|
|
+ if (xs.Contains(dsSchema.TargetNamespace)) {
|
|
|
+ global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
|
|
|
+ global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
|
|
|
+ try {
|
|
|
+ global::System.Xml.Schema.XmlSchema schema = null;
|
|
|
+ dsSchema.Write(s1);
|
|
|
+ for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
|
|
|
+ schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
|
|
|
+ s2.SetLength(0);
|
|
|
+ schema.Write(s2);
|
|
|
+ if ((s1.Length == s2.Length)) {
|
|
|
+ s1.Position = 0;
|
|
|
+ s2.Position = 0;
|
|
|
+ for (; ((s1.Position != s1.Length)
|
|
|
+ && (s1.ReadByte() == s2.ReadByte())); ) {
|
|
|
+ ;
|
|
|
+ }
|
|
|
+ if ((s1.Position == s1.Length)) {
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((s1 != null)) {
|
|
|
+ s1.Close();
|
|
|
+ }
|
|
|
+ if ((s2 != null)) {
|
|
|
+ s2.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ xs.Add(dsSchema);
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the strongly named DataTable class.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Serializable()]
|
|
|
+ [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
|
|
|
+ public partial class ТоварыDataTable : global::System.Data.TypedTableBase<ТоварыRow> {
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Tovara;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnNazvanie;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnCena;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnID_Klienta;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыDataTable() {
|
|
|
+ this.TableName = "Товары";
|
|
|
+ this.BeginInit();
|
|
|
+ this.InitClass();
|
|
|
+ this.EndInit();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal ТоварыDataTable(global::System.Data.DataTable table) {
|
|
|
+ this.TableName = table.TableName;
|
|
|
+ if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
|
|
|
+ this.CaseSensitive = table.CaseSensitive;
|
|
|
+ }
|
|
|
+ if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
|
|
|
+ this.Locale = table.Locale;
|
|
|
+ }
|
|
|
+ if ((table.Namespace != table.DataSet.Namespace)) {
|
|
|
+ this.Namespace = table.Namespace;
|
|
|
+ }
|
|
|
+ this.Prefix = table.Prefix;
|
|
|
+ this.MinimumCapacity = table.MinimumCapacity;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected ТоварыDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
|
|
|
+ base(info, context) {
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_TovaraColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Tovara;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn NazvanieColumn {
|
|
|
+ get {
|
|
|
+ return this.columnNazvanie;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn CenaColumn {
|
|
|
+ get {
|
|
|
+ return this.columnCena;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ID_KlientaColumn {
|
|
|
+ get {
|
|
|
+ return this.columnID_Klienta;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ public int Count {
|
|
|
+ get {
|
|
|
+ return this.Rows.Count;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRow this[int index] {
|
|
|
+ get {
|
|
|
+ return ((ТоварыRow)(this.Rows[index]));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ТоварыRowChangeEventHandler ТоварыRowChanging;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ТоварыRowChangeEventHandler ТоварыRowChanged;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ТоварыRowChangeEventHandler ТоварыRowDeleting;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event ТоварыRowChangeEventHandler ТоварыRowDeleted;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void AddТоварыRow(ТоварыRow row) {
|
|
|
+ this.Rows.Add(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRow AddТоварыRow(string Nazvanie, decimal Cena, int ID_Klienta) {
|
|
|
+ ТоварыRow rowТоварыRow = ((ТоварыRow)(this.NewRow()));
|
|
|
+ object[] columnValuesArray = new object[] {
|
|
|
+ null,
|
|
|
+ Nazvanie,
|
|
|
+ Cena,
|
|
|
+ ID_Klienta};
|
|
|
+ rowТоварыRow.ItemArray = columnValuesArray;
|
|
|
+ this.Rows.Add(rowТоварыRow);
|
|
|
+ return rowТоварыRow;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRow FindByID_Tovara(int ID_Tovara) {
|
|
|
+ return ((ТоварыRow)(this.Rows.Find(new object[] {
|
|
|
+ ID_Tovara})));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public override global::System.Data.DataTable Clone() {
|
|
|
+ ТоварыDataTable cln = ((ТоварыDataTable)(base.Clone()));
|
|
|
+ cln.InitVars();
|
|
|
+ return cln;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataTable CreateInstance() {
|
|
|
+ return new ТоварыDataTable();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal void InitVars() {
|
|
|
+ this.columnID_Tovara = base.Columns["ID_Tovara"];
|
|
|
+ this.columnNazvanie = base.Columns["Nazvanie"];
|
|
|
+ this.columnCena = base.Columns["Cena"];
|
|
|
+ this.columnID_Klienta = base.Columns["ID_Klienta"];
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitClass() {
|
|
|
+ this.columnID_Tovara = new global::System.Data.DataColumn("ID_Tovara", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Tovara);
|
|
|
+ this.columnNazvanie = new global::System.Data.DataColumn("Nazvanie", typeof(string), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnNazvanie);
|
|
|
+ this.columnCena = new global::System.Data.DataColumn("Cena", typeof(decimal), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnCena);
|
|
|
+ this.columnID_Klienta = new global::System.Data.DataColumn("ID_Klienta", typeof(int), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnID_Klienta);
|
|
|
+ this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
|
|
|
+ this.columnID_Tovara}, true));
|
|
|
+ this.columnID_Tovara.AutoIncrement = true;
|
|
|
+ this.columnID_Tovara.AutoIncrementSeed = -1;
|
|
|
+ this.columnID_Tovara.AutoIncrementStep = -1;
|
|
|
+ this.columnID_Tovara.AllowDBNull = false;
|
|
|
+ this.columnID_Tovara.ReadOnly = true;
|
|
|
+ this.columnID_Tovara.Unique = true;
|
|
|
+ this.columnNazvanie.AllowDBNull = false;
|
|
|
+ this.columnNazvanie.MaxLength = 50;
|
|
|
+ this.columnCena.AllowDBNull = false;
|
|
|
+ this.columnID_Klienta.AllowDBNull = false;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRow NewТоварыRow() {
|
|
|
+ return ((ТоварыRow)(this.NewRow()));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
|
|
|
+ return new ТоварыRow(builder);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Type GetRowType() {
|
|
|
+ return typeof(ТоварыRow);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanged(e);
|
|
|
+ if ((this.ТоварыRowChanged != null)) {
|
|
|
+ this.ТоварыRowChanged(this, new ТоварыRowChangeEvent(((ТоварыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanging(e);
|
|
|
+ if ((this.ТоварыRowChanging != null)) {
|
|
|
+ this.ТоварыRowChanging(this, new ТоварыRowChangeEvent(((ТоварыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleted(e);
|
|
|
+ if ((this.ТоварыRowDeleted != null)) {
|
|
|
+ this.ТоварыRowDeleted(this, new ТоварыRowChangeEvent(((ТоварыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleting(e);
|
|
|
+ if ((this.ТоварыRowDeleting != null)) {
|
|
|
+ this.ТоварыRowDeleting(this, new ТоварыRowChangeEvent(((ТоварыRow)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void RemoveТоварыRow(ТоварыRow row) {
|
|
|
+ this.Rows.Remove(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
|
|
|
+ global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
|
|
|
+ global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
|
|
|
+ Lyakhov_Bilet10DataSet ds = new Lyakhov_Bilet10DataSet();
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any1.Namespace = "http://www.w3.org/2001/XMLSchema";
|
|
|
+ any1.MinOccurs = new decimal(0);
|
|
|
+ any1.MaxOccurs = decimal.MaxValue;
|
|
|
+ any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
|
|
|
+ any2.MinOccurs = new decimal(1);
|
|
|
+ any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any2);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute1.Name = "namespace";
|
|
|
+ attribute1.FixedValue = ds.Namespace;
|
|
|
+ type.Attributes.Add(attribute1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute2.Name = "tableTypeName";
|
|
|
+ attribute2.FixedValue = "ТоварыDataTable";
|
|
|
+ type.Attributes.Add(attribute2);
|
|
|
+ type.Particle = sequence;
|
|
|
+ global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
|
|
|
+ if (xs.Contains(dsSchema.TargetNamespace)) {
|
|
|
+ global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
|
|
|
+ global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
|
|
|
+ try {
|
|
|
+ global::System.Xml.Schema.XmlSchema schema = null;
|
|
|
+ dsSchema.Write(s1);
|
|
|
+ for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
|
|
|
+ schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
|
|
|
+ s2.SetLength(0);
|
|
|
+ schema.Write(s2);
|
|
|
+ if ((s1.Length == s2.Length)) {
|
|
|
+ s1.Position = 0;
|
|
|
+ s2.Position = 0;
|
|
|
+ for (; ((s1.Position != s1.Length)
|
|
|
+ && (s1.ReadByte() == s2.ReadByte())); ) {
|
|
|
+ ;
|
|
|
+ }
|
|
|
+ if ((s1.Position == s1.Length)) {
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((s1 != null)) {
|
|
|
+ s1.Close();
|
|
|
+ }
|
|
|
+ if ((s2 != null)) {
|
|
|
+ s2.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ xs.Add(dsSchema);
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the strongly named DataTable class.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Serializable()]
|
|
|
+ [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
|
|
|
+ public partial class View_1DataTable : global::System.Data.TypedTableBase<View_1Row> {
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnДата;
|
|
|
+
|
|
|
+ private global::System.Data.DataColumn columnНазвание;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public View_1DataTable() {
|
|
|
+ this.TableName = "View_1";
|
|
|
+ this.BeginInit();
|
|
|
+ this.InitClass();
|
|
|
+ this.EndInit();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal View_1DataTable(global::System.Data.DataTable table) {
|
|
|
+ this.TableName = table.TableName;
|
|
|
+ if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
|
|
|
+ this.CaseSensitive = table.CaseSensitive;
|
|
|
+ }
|
|
|
+ if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
|
|
|
+ this.Locale = table.Locale;
|
|
|
+ }
|
|
|
+ if ((table.Namespace != table.DataSet.Namespace)) {
|
|
|
+ this.Namespace = table.Namespace;
|
|
|
+ }
|
|
|
+ this.Prefix = table.Prefix;
|
|
|
+ this.MinimumCapacity = table.MinimumCapacity;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected View_1DataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
|
|
|
+ base(info, context) {
|
|
|
+ this.InitVars();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn ДатаColumn {
|
|
|
+ get {
|
|
|
+ return this.columnДата;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataColumn НазваниеColumn {
|
|
|
+ get {
|
|
|
+ return this.columnНазвание;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ public int Count {
|
|
|
+ get {
|
|
|
+ return this.Rows.Count;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public View_1Row this[int index] {
|
|
|
+ get {
|
|
|
+ return ((View_1Row)(this.Rows[index]));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event View_1RowChangeEventHandler View_1RowChanging;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event View_1RowChangeEventHandler View_1RowChanged;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event View_1RowChangeEventHandler View_1RowDeleting;
|
|
|
+
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public event View_1RowChangeEventHandler View_1RowDeleted;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void AddView_1Row(View_1Row row) {
|
|
|
+ this.Rows.Add(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public View_1Row AddView_1Row(System.DateTime Дата, string Название) {
|
|
|
+ View_1Row rowView_1Row = ((View_1Row)(this.NewRow()));
|
|
|
+ object[] columnValuesArray = new object[] {
|
|
|
+ Дата,
|
|
|
+ Название};
|
|
|
+ rowView_1Row.ItemArray = columnValuesArray;
|
|
|
+ this.Rows.Add(rowView_1Row);
|
|
|
+ return rowView_1Row;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public override global::System.Data.DataTable Clone() {
|
|
|
+ View_1DataTable cln = ((View_1DataTable)(base.Clone()));
|
|
|
+ cln.InitVars();
|
|
|
+ return cln;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataTable CreateInstance() {
|
|
|
+ return new View_1DataTable();
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal void InitVars() {
|
|
|
+ this.columnДата = base.Columns["Дата"];
|
|
|
+ this.columnНазвание = base.Columns["Название"];
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitClass() {
|
|
|
+ this.columnДата = new global::System.Data.DataColumn("Дата", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnДата);
|
|
|
+ this.columnНазвание = new global::System.Data.DataColumn("Название", typeof(string), null, global::System.Data.MappingType.Element);
|
|
|
+ base.Columns.Add(this.columnНазвание);
|
|
|
+ this.columnДата.AllowDBNull = false;
|
|
|
+ this.columnНазвание.AllowDBNull = false;
|
|
|
+ this.columnНазвание.MaxLength = 50;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public View_1Row NewView_1Row() {
|
|
|
+ return ((View_1Row)(this.NewRow()));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
|
|
|
+ return new View_1Row(builder);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override global::System.Type GetRowType() {
|
|
|
+ return typeof(View_1Row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanged(e);
|
|
|
+ if ((this.View_1RowChanged != null)) {
|
|
|
+ this.View_1RowChanged(this, new View_1RowChangeEvent(((View_1Row)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowChanging(e);
|
|
|
+ if ((this.View_1RowChanging != null)) {
|
|
|
+ this.View_1RowChanging(this, new View_1RowChangeEvent(((View_1Row)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleted(e);
|
|
|
+ if ((this.View_1RowDeleted != null)) {
|
|
|
+ this.View_1RowDeleted(this, new View_1RowChangeEvent(((View_1Row)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
|
|
|
+ base.OnRowDeleting(e);
|
|
|
+ if ((this.View_1RowDeleting != null)) {
|
|
|
+ this.View_1RowDeleting(this, new View_1RowChangeEvent(((View_1Row)(e.Row)), e.Action));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void RemoveView_1Row(View_1Row row) {
|
|
|
+ this.Rows.Remove(row);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
|
|
|
+ global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
|
|
|
+ global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
|
|
|
+ Lyakhov_Bilet10DataSet ds = new Lyakhov_Bilet10DataSet();
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any1.Namespace = "http://www.w3.org/2001/XMLSchema";
|
|
|
+ any1.MinOccurs = new decimal(0);
|
|
|
+ any1.MaxOccurs = decimal.MaxValue;
|
|
|
+ any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
|
|
|
+ any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
|
|
|
+ any2.MinOccurs = new decimal(1);
|
|
|
+ any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
|
|
|
+ sequence.Items.Add(any2);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute1.Name = "namespace";
|
|
|
+ attribute1.FixedValue = ds.Namespace;
|
|
|
+ type.Attributes.Add(attribute1);
|
|
|
+ global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
|
|
|
+ attribute2.Name = "tableTypeName";
|
|
|
+ attribute2.FixedValue = "View_1DataTable";
|
|
|
+ type.Attributes.Add(attribute2);
|
|
|
+ type.Particle = sequence;
|
|
|
+ global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
|
|
|
+ if (xs.Contains(dsSchema.TargetNamespace)) {
|
|
|
+ global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
|
|
|
+ global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
|
|
|
+ try {
|
|
|
+ global::System.Xml.Schema.XmlSchema schema = null;
|
|
|
+ dsSchema.Write(s1);
|
|
|
+ for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
|
|
|
+ schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
|
|
|
+ s2.SetLength(0);
|
|
|
+ schema.Write(s2);
|
|
|
+ if ((s1.Length == s2.Length)) {
|
|
|
+ s1.Position = 0;
|
|
|
+ s2.Position = 0;
|
|
|
+ for (; ((s1.Position != s1.Length)
|
|
|
+ && (s1.ReadByte() == s2.ReadByte())); ) {
|
|
|
+ ;
|
|
|
+ }
|
|
|
+ if ((s1.Position == s1.Length)) {
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((s1 != null)) {
|
|
|
+ s1.Close();
|
|
|
+ }
|
|
|
+ if ((s2 != null)) {
|
|
|
+ s2.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ xs.Add(dsSchema);
|
|
|
+ return type;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents strongly named DataRow class.
|
|
|
+ ///</summary>
|
|
|
+ public partial class ЗаказRow : global::System.Data.DataRow {
|
|
|
+
|
|
|
+ private ЗаказDataTable tableЗаказ;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal ЗаказRow(global::System.Data.DataRowBuilder rb) :
|
|
|
+ base(rb) {
|
|
|
+ this.tableЗаказ = ((ЗаказDataTable)(this.Table));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Zakaza {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableЗаказ.ID_ZakazaColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableЗаказ.ID_ZakazaColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int Kolichestvo {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableЗаказ.KolichestvoColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableЗаказ.KolichestvoColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Tovara {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableЗаказ.ID_TovaraColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableЗаказ.ID_TovaraColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Klienta {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableЗаказ.ID_KlientaColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableЗаказ.ID_KlientaColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыRow КлиентыRow {
|
|
|
+ get {
|
|
|
+ return ((КлиентыRow)(this.GetParentRow(this.Table.ParentRelations["FK_Заказ_Клиенты"])));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this.SetParentRow(value, this.Table.ParentRelations["FK_Заказ_Клиенты"]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRow ТоварыRow {
|
|
|
+ get {
|
|
|
+ return ((ТоварыRow)(this.GetParentRow(this.Table.ParentRelations["FK_Заказ_Товары"])));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this.SetParentRow(value, this.Table.ParentRelations["FK_Заказ_Товары"]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents strongly named DataRow class.
|
|
|
+ ///</summary>
|
|
|
+ public partial class История_продажиRow : global::System.Data.DataRow {
|
|
|
+
|
|
|
+ private История_продажиDataTable tableИстория_продажи;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal История_продажиRow(global::System.Data.DataRowBuilder rb) :
|
|
|
+ base(rb) {
|
|
|
+ this.tableИстория_продажи = ((История_продажиDataTable)(this.Table));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Istorii {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableИстория_продажи.ID_IstoriiColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableИстория_продажи.ID_IstoriiColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public string Nazvanie {
|
|
|
+ get {
|
|
|
+ return ((string)(this[this.tableИстория_продажи.NazvanieColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableИстория_продажи.NazvanieColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public System.DateTime Data_Prodaji {
|
|
|
+ get {
|
|
|
+ return ((global::System.DateTime)(this[this.tableИстория_продажи.Data_ProdajiColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableИстория_продажи.Data_ProdajiColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Tovara {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableИстория_продажи.ID_TovaraColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableИстория_продажи.ID_TovaraColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRow ТоварыRow {
|
|
|
+ get {
|
|
|
+ return ((ТоварыRow)(this.GetParentRow(this.Table.ParentRelations["FK_История продажи_Товары"])));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this.SetParentRow(value, this.Table.ParentRelations["FK_История продажи_Товары"]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents strongly named DataRow class.
|
|
|
+ ///</summary>
|
|
|
+ public partial class КлиентыRow : global::System.Data.DataRow {
|
|
|
+
|
|
|
+ private КлиентыDataTable tableКлиенты;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal КлиентыRow(global::System.Data.DataRowBuilder rb) :
|
|
|
+ base(rb) {
|
|
|
+ this.tableКлиенты = ((КлиентыDataTable)(this.Table));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Klienta {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableКлиенты.ID_KlientaColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableКлиенты.ID_KlientaColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public string FIO {
|
|
|
+ get {
|
|
|
+ return ((string)(this[this.tableКлиенты.FIOColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableКлиенты.FIOColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public string Telepfone {
|
|
|
+ get {
|
|
|
+ return ((string)(this[this.tableКлиенты.TelepfoneColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableКлиенты.TelepfoneColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Zakaza {
|
|
|
+ get {
|
|
|
+ try {
|
|
|
+ return ((int)(this[this.tableКлиенты.ID_ZakazaColumn]));
|
|
|
+ }
|
|
|
+ catch (global::System.InvalidCastException e) {
|
|
|
+ throw new global::System.Data.StrongTypingException("Значение для столбца \'ID_Zakaza\' в таблице \'Клиенты\' равно DBNull.", e);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableКлиенты.ID_ZakazaColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public bool IsID_ZakazaNull() {
|
|
|
+ return this.IsNull(this.tableКлиенты.ID_ZakazaColumn);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public void SetID_ZakazaNull() {
|
|
|
+ this[this.tableКлиенты.ID_ZakazaColumn] = global::System.Convert.DBNull;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRow[] GetЗаказRows() {
|
|
|
+ if ((this.Table.ChildRelations["FK_Заказ_Клиенты"] == null)) {
|
|
|
+ return new ЗаказRow[0];
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ return ((ЗаказRow[])(base.GetChildRows(this.Table.ChildRelations["FK_Заказ_Клиенты"])));
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents strongly named DataRow class.
|
|
|
+ ///</summary>
|
|
|
+ public partial class ТоварыRow : global::System.Data.DataRow {
|
|
|
+
|
|
|
+ private ТоварыDataTable tableТовары;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal ТоварыRow(global::System.Data.DataRowBuilder rb) :
|
|
|
+ base(rb) {
|
|
|
+ this.tableТовары = ((ТоварыDataTable)(this.Table));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Tovara {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableТовары.ID_TovaraColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableТовары.ID_TovaraColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public string Nazvanie {
|
|
|
+ get {
|
|
|
+ return ((string)(this[this.tableТовары.NazvanieColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableТовары.NazvanieColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public decimal Cena {
|
|
|
+ get {
|
|
|
+ return ((decimal)(this[this.tableТовары.CenaColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableТовары.CenaColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int ID_Klienta {
|
|
|
+ get {
|
|
|
+ return ((int)(this[this.tableТовары.ID_KlientaColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableТовары.ID_KlientaColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRow[] GetЗаказRows() {
|
|
|
+ if ((this.Table.ChildRelations["FK_Заказ_Товары"] == null)) {
|
|
|
+ return new ЗаказRow[0];
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ return ((ЗаказRow[])(base.GetChildRows(this.Table.ChildRelations["FK_Заказ_Товары"])));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиRow[] GetИстория_продажиRows() {
|
|
|
+ if ((this.Table.ChildRelations["FK_История продажи_Товары"] == null)) {
|
|
|
+ return new История_продажиRow[0];
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ return ((История_продажиRow[])(base.GetChildRows(this.Table.ChildRelations["FK_История продажи_Товары"])));
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents strongly named DataRow class.
|
|
|
+ ///</summary>
|
|
|
+ public partial class View_1Row : global::System.Data.DataRow {
|
|
|
+
|
|
|
+ private View_1DataTable tableView_1;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal View_1Row(global::System.Data.DataRowBuilder rb) :
|
|
|
+ base(rb) {
|
|
|
+ this.tableView_1 = ((View_1DataTable)(this.Table));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public System.DateTime Дата {
|
|
|
+ get {
|
|
|
+ return ((global::System.DateTime)(this[this.tableView_1.ДатаColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableView_1.ДатаColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public string Название {
|
|
|
+ get {
|
|
|
+ return ((string)(this[this.tableView_1.НазваниеColumn]));
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this[this.tableView_1.НазваниеColumn] = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Row event argument class
|
|
|
+ ///</summary>
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public class ЗаказRowChangeEvent : global::System.EventArgs {
|
|
|
+
|
|
|
+ private ЗаказRow eventRow;
|
|
|
+
|
|
|
+ private global::System.Data.DataRowAction eventAction;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRowChangeEvent(ЗаказRow row, global::System.Data.DataRowAction action) {
|
|
|
+ this.eventRow = row;
|
|
|
+ this.eventAction = action;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказRow Row {
|
|
|
+ get {
|
|
|
+ return this.eventRow;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataRowAction Action {
|
|
|
+ get {
|
|
|
+ return this.eventAction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Row event argument class
|
|
|
+ ///</summary>
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public class История_продажиRowChangeEvent : global::System.EventArgs {
|
|
|
+
|
|
|
+ private История_продажиRow eventRow;
|
|
|
+
|
|
|
+ private global::System.Data.DataRowAction eventAction;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиRowChangeEvent(История_продажиRow row, global::System.Data.DataRowAction action) {
|
|
|
+ this.eventRow = row;
|
|
|
+ this.eventAction = action;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиRow Row {
|
|
|
+ get {
|
|
|
+ return this.eventRow;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataRowAction Action {
|
|
|
+ get {
|
|
|
+ return this.eventAction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Row event argument class
|
|
|
+ ///</summary>
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public class КлиентыRowChangeEvent : global::System.EventArgs {
|
|
|
+
|
|
|
+ private КлиентыRow eventRow;
|
|
|
+
|
|
|
+ private global::System.Data.DataRowAction eventAction;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыRowChangeEvent(КлиентыRow row, global::System.Data.DataRowAction action) {
|
|
|
+ this.eventRow = row;
|
|
|
+ this.eventAction = action;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыRow Row {
|
|
|
+ get {
|
|
|
+ return this.eventRow;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataRowAction Action {
|
|
|
+ get {
|
|
|
+ return this.eventAction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Row event argument class
|
|
|
+ ///</summary>
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public class ТоварыRowChangeEvent : global::System.EventArgs {
|
|
|
+
|
|
|
+ private ТоварыRow eventRow;
|
|
|
+
|
|
|
+ private global::System.Data.DataRowAction eventAction;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRowChangeEvent(ТоварыRow row, global::System.Data.DataRowAction action) {
|
|
|
+ this.eventRow = row;
|
|
|
+ this.eventAction = action;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыRow Row {
|
|
|
+ get {
|
|
|
+ return this.eventRow;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataRowAction Action {
|
|
|
+ get {
|
|
|
+ return this.eventAction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Row event argument class
|
|
|
+ ///</summary>
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public class View_1RowChangeEvent : global::System.EventArgs {
|
|
|
+
|
|
|
+ private View_1Row eventRow;
|
|
|
+
|
|
|
+ private global::System.Data.DataRowAction eventAction;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public View_1RowChangeEvent(View_1Row row, global::System.Data.DataRowAction action) {
|
|
|
+ this.eventRow = row;
|
|
|
+ this.eventAction = action;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public View_1Row Row {
|
|
|
+ get {
|
|
|
+ return this.eventRow;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public global::System.Data.DataRowAction Action {
|
|
|
+ get {
|
|
|
+ return this.eventAction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+namespace Lyakhov_Bilet10.Lyakhov_Bilet10DataSetTableAdapters {
|
|
|
+
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the connection and commands used to retrieve and save data.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
|
+ [global::System.ComponentModel.ToolboxItem(true)]
|
|
|
+ [global::System.ComponentModel.DataObjectAttribute(true)]
|
|
|
+ [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
|
|
|
+ ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public partial class ЗаказTableAdapter : global::System.ComponentModel.Component {
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlDataAdapter _adapter;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlConnection _connection;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlTransaction _transaction;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
|
|
|
+
|
|
|
+ private bool _clearBeforeFill;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ЗаказTableAdapter() {
|
|
|
+ this.ClearBeforeFill = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
|
|
|
+ get {
|
|
|
+ if ((this._adapter == null)) {
|
|
|
+ this.InitAdapter();
|
|
|
+ }
|
|
|
+ return this._adapter;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlConnection Connection {
|
|
|
+ get {
|
|
|
+ if ((this._connection == null)) {
|
|
|
+ this.InitConnection();
|
|
|
+ }
|
|
|
+ return this._connection;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._connection = value;
|
|
|
+ if ((this.Adapter.InsertCommand != null)) {
|
|
|
+ this.Adapter.InsertCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.DeleteCommand != null)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.UpdateCommand != null)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection = value;
|
|
|
+ }
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ if ((this.CommandCollection[i] != null)) {
|
|
|
+ ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlTransaction Transaction {
|
|
|
+ get {
|
|
|
+ return this._transaction;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._transaction = value;
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ this.CommandCollection[i].Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.DeleteCommand != null))) {
|
|
|
+ this.Adapter.DeleteCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.InsertCommand != null))) {
|
|
|
+ this.Adapter.InsertCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.UpdateCommand != null))) {
|
|
|
+ this.Adapter.UpdateCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
|
|
|
+ get {
|
|
|
+ if ((this._commandCollection == null)) {
|
|
|
+ this.InitCommandCollection();
|
|
|
+ }
|
|
|
+ return this._commandCollection;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public bool ClearBeforeFill {
|
|
|
+ get {
|
|
|
+ return this._clearBeforeFill;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._clearBeforeFill = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitAdapter() {
|
|
|
+ this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
|
|
|
+ global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
|
|
|
+ tableMapping.SourceTable = "Table";
|
|
|
+ tableMapping.DataSetTable = "Заказ";
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Zakaza", "ID_Zakaza");
|
|
|
+ tableMapping.ColumnMappings.Add("Kolichestvo", "Kolichestvo");
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Tovara", "ID_Tovara");
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Klienta", "ID_Klienta");
|
|
|
+ this._adapter.TableMappings.Add(tableMapping);
|
|
|
+ this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.DeleteCommand.Connection = this.Connection;
|
|
|
+ this._adapter.DeleteCommand.CommandText = "DELETE FROM [dbo].[Заказ] WHERE (([ID_Zakaza] = @Original_ID_Zakaza) AND ([Kolich" +
|
|
|
+ "estvo] = @Original_Kolichestvo) AND ([ID_Tovara] = @Original_ID_Tovara) AND ([ID" +
|
|
|
+ "_Klienta] = @Original_ID_Klienta))";
|
|
|
+ this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Kolichestvo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Kolichestvo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.InsertCommand.Connection = this.Connection;
|
|
|
+ this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[Заказ] ([Kolichestvo], [ID_Tovara], [ID_Klienta]) VALUES (@Kol" +
|
|
|
+ "ichestvo, @ID_Tovara, @ID_Klienta);\r\nSELECT ID_Zakaza, Kolichestvo, ID_Tovara, I" +
|
|
|
+ "D_Klienta FROM Заказ WHERE (ID_Zakaza = SCOPE_IDENTITY())";
|
|
|
+ this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Kolichestvo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Kolichestvo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.UpdateCommand.Connection = this.Connection;
|
|
|
+ this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Заказ] SET [Kolichestvo] = @Kolichestvo, [ID_Tovara] = @ID_Tovara, [ID_Klienta] = @ID_Klienta WHERE (([ID_Zakaza] = @Original_ID_Zakaza) AND ([Kolichestvo] = @Original_Kolichestvo) AND ([ID_Tovara] = @Original_ID_Tovara) AND ([ID_Klienta] = @Original_ID_Klienta));
|
|
|
+SELECT ID_Zakaza, Kolichestvo, ID_Tovara, ID_Klienta FROM Заказ WHERE (ID_Zakaza = @ID_Zakaza)";
|
|
|
+ this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Kolichestvo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Kolichestvo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Kolichestvo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Kolichestvo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Zakaza", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitConnection() {
|
|
|
+ this._connection = new global::System.Data.SqlClient.SqlConnection();
|
|
|
+ this._connection.ConnectionString = global::Lyakhov_Bilet10.Properties.Settings.Default.Lyakhov_Bilet10ConnectionString;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitCommandCollection() {
|
|
|
+ this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
|
|
|
+ this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._commandCollection[0].Connection = this.Connection;
|
|
|
+ this._commandCollection[0].CommandText = "SELECT ID_Zakaza, Kolichestvo, ID_Tovara, ID_Klienta FROM dbo.Заказ";
|
|
|
+ this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
|
|
|
+ public virtual int Fill(Lyakhov_Bilet10DataSet.ЗаказDataTable dataTable) {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ if ((this.ClearBeforeFill == true)) {
|
|
|
+ dataTable.Clear();
|
|
|
+ }
|
|
|
+ int returnValue = this.Adapter.Fill(dataTable);
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
|
|
|
+ public virtual Lyakhov_Bilet10DataSet.ЗаказDataTable GetData() {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ Lyakhov_Bilet10DataSet.ЗаказDataTable dataTable = new Lyakhov_Bilet10DataSet.ЗаказDataTable();
|
|
|
+ this.Adapter.Fill(dataTable);
|
|
|
+ return dataTable;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet.ЗаказDataTable dataTable) {
|
|
|
+ return this.Adapter.Update(dataTable);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet dataSet) {
|
|
|
+ return this.Adapter.Update(dataSet, "Заказ");
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow dataRow) {
|
|
|
+ return this.Adapter.Update(new global::System.Data.DataRow[] {
|
|
|
+ dataRow});
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow[] dataRows) {
|
|
|
+ return this.Adapter.Update(dataRows);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
|
|
|
+ public virtual int Delete(int Original_ID_Zakaza, int Original_Kolichestvo, int Original_ID_Tovara, int Original_ID_Klienta) {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_ID_Zakaza));
|
|
|
+ this.Adapter.DeleteCommand.Parameters[1].Value = ((int)(Original_Kolichestvo));
|
|
|
+ this.Adapter.DeleteCommand.Parameters[2].Value = ((int)(Original_ID_Tovara));
|
|
|
+ this.Adapter.DeleteCommand.Parameters[3].Value = ((int)(Original_ID_Klienta));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
|
|
|
+ if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
|
|
|
+ public virtual int Insert(int Kolichestvo, int ID_Tovara, int ID_Klienta) {
|
|
|
+ this.Adapter.InsertCommand.Parameters[0].Value = ((int)(Kolichestvo));
|
|
|
+ this.Adapter.InsertCommand.Parameters[1].Value = ((int)(ID_Tovara));
|
|
|
+ this.Adapter.InsertCommand.Parameters[2].Value = ((int)(ID_Klienta));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
|
|
|
+ if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(int Kolichestvo, int ID_Tovara, int ID_Klienta, int Original_ID_Zakaza, int Original_Kolichestvo, int Original_ID_Tovara, int Original_ID_Klienta, int ID_Zakaza) {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[0].Value = ((int)(Kolichestvo));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[1].Value = ((int)(ID_Tovara));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(ID_Klienta));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_ID_Zakaza));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[4].Value = ((int)(Original_Kolichestvo));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[5].Value = ((int)(Original_ID_Tovara));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(Original_ID_Klienta));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[7].Value = ((int)(ID_Zakaza));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
|
|
|
+ if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(int Kolichestvo, int ID_Tovara, int ID_Klienta, int Original_ID_Zakaza, int Original_Kolichestvo, int Original_ID_Tovara, int Original_ID_Klienta) {
|
|
|
+ return this.Update(Kolichestvo, ID_Tovara, ID_Klienta, Original_ID_Zakaza, Original_Kolichestvo, Original_ID_Tovara, Original_ID_Klienta, Original_ID_Zakaza);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the connection and commands used to retrieve and save data.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
|
+ [global::System.ComponentModel.ToolboxItem(true)]
|
|
|
+ [global::System.ComponentModel.DataObjectAttribute(true)]
|
|
|
+ [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
|
|
|
+ ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public partial class История_продажиTableAdapter : global::System.ComponentModel.Component {
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlDataAdapter _adapter;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlConnection _connection;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlTransaction _transaction;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
|
|
|
+
|
|
|
+ private bool _clearBeforeFill;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public История_продажиTableAdapter() {
|
|
|
+ this.ClearBeforeFill = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
|
|
|
+ get {
|
|
|
+ if ((this._adapter == null)) {
|
|
|
+ this.InitAdapter();
|
|
|
+ }
|
|
|
+ return this._adapter;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlConnection Connection {
|
|
|
+ get {
|
|
|
+ if ((this._connection == null)) {
|
|
|
+ this.InitConnection();
|
|
|
+ }
|
|
|
+ return this._connection;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._connection = value;
|
|
|
+ if ((this.Adapter.InsertCommand != null)) {
|
|
|
+ this.Adapter.InsertCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.DeleteCommand != null)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.UpdateCommand != null)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection = value;
|
|
|
+ }
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ if ((this.CommandCollection[i] != null)) {
|
|
|
+ ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlTransaction Transaction {
|
|
|
+ get {
|
|
|
+ return this._transaction;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._transaction = value;
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ this.CommandCollection[i].Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.DeleteCommand != null))) {
|
|
|
+ this.Adapter.DeleteCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.InsertCommand != null))) {
|
|
|
+ this.Adapter.InsertCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.UpdateCommand != null))) {
|
|
|
+ this.Adapter.UpdateCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
|
|
|
+ get {
|
|
|
+ if ((this._commandCollection == null)) {
|
|
|
+ this.InitCommandCollection();
|
|
|
+ }
|
|
|
+ return this._commandCollection;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public bool ClearBeforeFill {
|
|
|
+ get {
|
|
|
+ return this._clearBeforeFill;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._clearBeforeFill = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitAdapter() {
|
|
|
+ this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
|
|
|
+ global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
|
|
|
+ tableMapping.SourceTable = "Table";
|
|
|
+ tableMapping.DataSetTable = "История продажи";
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Istorii", "ID_Istorii");
|
|
|
+ tableMapping.ColumnMappings.Add("Nazvanie", "Nazvanie");
|
|
|
+ tableMapping.ColumnMappings.Add("Data_Prodaji", "Data_Prodaji");
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Tovara", "ID_Tovara");
|
|
|
+ this._adapter.TableMappings.Add(tableMapping);
|
|
|
+ this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.DeleteCommand.Connection = this.Connection;
|
|
|
+ this._adapter.DeleteCommand.CommandText = "DELETE FROM [dbo].[История продажи] WHERE (([ID_Istorii] = @Original_ID_Istorii) " +
|
|
|
+ "AND ([Nazvanie] = @Original_Nazvanie) AND ([Data_Prodaji] = @Original_Data_Proda" +
|
|
|
+ "ji) AND ([ID_Tovara] = @Original_ID_Tovara))";
|
|
|
+ this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Istorii", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Istorii", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Data_Prodaji", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Data_Prodaji", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.InsertCommand.Connection = this.Connection;
|
|
|
+ this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[История продажи] ([Nazvanie], [Data_Prodaji], [ID_Tovara]) VAL" +
|
|
|
+ "UES (@Nazvanie, @Data_Prodaji, @ID_Tovara);\r\nSELECT ID_Istorii, Nazvanie, Data_P" +
|
|
|
+ "rodaji, ID_Tovara FROM [История продажи] WHERE (ID_Istorii = SCOPE_IDENTITY())";
|
|
|
+ this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Data_Prodaji", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Data_Prodaji", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.UpdateCommand.Connection = this.Connection;
|
|
|
+ this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[История продажи] SET [Nazvanie] = @Nazvanie, [Data_Prodaji] = @Data_Prodaji, [ID_Tovara] = @ID_Tovara WHERE (([ID_Istorii] = @Original_ID_Istorii) AND ([Nazvanie] = @Original_Nazvanie) AND ([Data_Prodaji] = @Original_Data_Prodaji) AND ([ID_Tovara] = @Original_ID_Tovara));
|
|
|
+SELECT ID_Istorii, Nazvanie, Data_Prodaji, ID_Tovara FROM [История продажи] WHERE (ID_Istorii = @ID_Istorii)";
|
|
|
+ this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Data_Prodaji", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Data_Prodaji", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Istorii", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Istorii", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Data_Prodaji", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Data_Prodaji", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Istorii", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Istorii", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitConnection() {
|
|
|
+ this._connection = new global::System.Data.SqlClient.SqlConnection();
|
|
|
+ this._connection.ConnectionString = global::Lyakhov_Bilet10.Properties.Settings.Default.Lyakhov_Bilet10ConnectionString;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitCommandCollection() {
|
|
|
+ this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
|
|
|
+ this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._commandCollection[0].Connection = this.Connection;
|
|
|
+ this._commandCollection[0].CommandText = "SELECT ID_Istorii, Nazvanie, Data_Prodaji, ID_Tovara FROM dbo.[История продажи]";
|
|
|
+ this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
|
|
|
+ public virtual int Fill(Lyakhov_Bilet10DataSet.История_продажиDataTable dataTable) {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ if ((this.ClearBeforeFill == true)) {
|
|
|
+ dataTable.Clear();
|
|
|
+ }
|
|
|
+ int returnValue = this.Adapter.Fill(dataTable);
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
|
|
|
+ public virtual Lyakhov_Bilet10DataSet.История_продажиDataTable GetData() {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ Lyakhov_Bilet10DataSet.История_продажиDataTable dataTable = new Lyakhov_Bilet10DataSet.История_продажиDataTable();
|
|
|
+ this.Adapter.Fill(dataTable);
|
|
|
+ return dataTable;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet.История_продажиDataTable dataTable) {
|
|
|
+ return this.Adapter.Update(dataTable);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet dataSet) {
|
|
|
+ return this.Adapter.Update(dataSet, "История продажи");
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow dataRow) {
|
|
|
+ return this.Adapter.Update(new global::System.Data.DataRow[] {
|
|
|
+ dataRow});
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow[] dataRows) {
|
|
|
+ return this.Adapter.Update(dataRows);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
|
|
|
+ public virtual int Delete(int Original_ID_Istorii, string Original_Nazvanie, System.DateTime Original_Data_Prodaji, int Original_ID_Tovara) {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_ID_Istorii));
|
|
|
+ if ((Original_Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[1].Value = ((string)(Original_Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.DeleteCommand.Parameters[2].Value = ((System.DateTime)(Original_Data_Prodaji));
|
|
|
+ this.Adapter.DeleteCommand.Parameters[3].Value = ((int)(Original_ID_Tovara));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
|
|
|
+ if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
|
|
|
+ public virtual int Insert(string Nazvanie, System.DateTime Data_Prodaji, int ID_Tovara) {
|
|
|
+ if ((Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.InsertCommand.Parameters[0].Value = ((string)(Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.InsertCommand.Parameters[1].Value = ((System.DateTime)(Data_Prodaji));
|
|
|
+ this.Adapter.InsertCommand.Parameters[2].Value = ((int)(ID_Tovara));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
|
|
|
+ if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(string Nazvanie, System.DateTime Data_Prodaji, int ID_Tovara, int Original_ID_Istorii, string Original_Nazvanie, System.DateTime Original_Data_Prodaji, int Original_ID_Tovara, int ID_Istorii) {
|
|
|
+ if ((Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.UpdateCommand.Parameters[1].Value = ((System.DateTime)(Data_Prodaji));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(ID_Tovara));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_ID_Istorii));
|
|
|
+ if ((Original_Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[4].Value = ((string)(Original_Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.UpdateCommand.Parameters[5].Value = ((System.DateTime)(Original_Data_Prodaji));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(Original_ID_Tovara));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[7].Value = ((int)(ID_Istorii));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
|
|
|
+ if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(string Nazvanie, System.DateTime Data_Prodaji, int ID_Tovara, int Original_ID_Istorii, string Original_Nazvanie, System.DateTime Original_Data_Prodaji, int Original_ID_Tovara) {
|
|
|
+ return this.Update(Nazvanie, Data_Prodaji, ID_Tovara, Original_ID_Istorii, Original_Nazvanie, Original_Data_Prodaji, Original_ID_Tovara, Original_ID_Istorii);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the connection and commands used to retrieve and save data.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
|
+ [global::System.ComponentModel.ToolboxItem(true)]
|
|
|
+ [global::System.ComponentModel.DataObjectAttribute(true)]
|
|
|
+ [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
|
|
|
+ ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public partial class КлиентыTableAdapter : global::System.ComponentModel.Component {
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlDataAdapter _adapter;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlConnection _connection;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlTransaction _transaction;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
|
|
|
+
|
|
|
+ private bool _clearBeforeFill;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public КлиентыTableAdapter() {
|
|
|
+ this.ClearBeforeFill = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
|
|
|
+ get {
|
|
|
+ if ((this._adapter == null)) {
|
|
|
+ this.InitAdapter();
|
|
|
+ }
|
|
|
+ return this._adapter;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlConnection Connection {
|
|
|
+ get {
|
|
|
+ if ((this._connection == null)) {
|
|
|
+ this.InitConnection();
|
|
|
+ }
|
|
|
+ return this._connection;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._connection = value;
|
|
|
+ if ((this.Adapter.InsertCommand != null)) {
|
|
|
+ this.Adapter.InsertCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.DeleteCommand != null)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.UpdateCommand != null)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection = value;
|
|
|
+ }
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ if ((this.CommandCollection[i] != null)) {
|
|
|
+ ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlTransaction Transaction {
|
|
|
+ get {
|
|
|
+ return this._transaction;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._transaction = value;
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ this.CommandCollection[i].Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.DeleteCommand != null))) {
|
|
|
+ this.Adapter.DeleteCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.InsertCommand != null))) {
|
|
|
+ this.Adapter.InsertCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.UpdateCommand != null))) {
|
|
|
+ this.Adapter.UpdateCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
|
|
|
+ get {
|
|
|
+ if ((this._commandCollection == null)) {
|
|
|
+ this.InitCommandCollection();
|
|
|
+ }
|
|
|
+ return this._commandCollection;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public bool ClearBeforeFill {
|
|
|
+ get {
|
|
|
+ return this._clearBeforeFill;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._clearBeforeFill = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitAdapter() {
|
|
|
+ this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
|
|
|
+ global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
|
|
|
+ tableMapping.SourceTable = "Table";
|
|
|
+ tableMapping.DataSetTable = "Клиенты";
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Klienta", "ID_Klienta");
|
|
|
+ tableMapping.ColumnMappings.Add("FIO", "FIO");
|
|
|
+ tableMapping.ColumnMappings.Add("Telepfone", "Telepfone");
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Zakaza", "ID_Zakaza");
|
|
|
+ this._adapter.TableMappings.Add(tableMapping);
|
|
|
+ this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.DeleteCommand.Connection = this.Connection;
|
|
|
+ this._adapter.DeleteCommand.CommandText = "DELETE FROM [dbo].[Клиенты] WHERE (([ID_Klienta] = @Original_ID_Klienta) AND ([FI" +
|
|
|
+ "O] = @Original_FIO) AND ([Telepfone] = @Original_Telepfone) AND ((@IsNull_ID_Zak" +
|
|
|
+ "aza = 1 AND [ID_Zakaza] IS NULL) OR ([ID_Zakaza] = @Original_ID_Zakaza)))";
|
|
|
+ this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_FIO", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "FIO", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Telepfone", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Telepfone", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.InsertCommand.Connection = this.Connection;
|
|
|
+ this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[Клиенты] ([FIO], [Telepfone], [ID_Zakaza]) VALUES (@FIO, @Tele" +
|
|
|
+ "pfone, @ID_Zakaza);\r\nSELECT ID_Klienta, FIO, Telepfone, ID_Zakaza FROM Клиенты W" +
|
|
|
+ "HERE (ID_Klienta = SCOPE_IDENTITY())";
|
|
|
+ this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@FIO", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "FIO", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Telepfone", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Telepfone", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.UpdateCommand.Connection = this.Connection;
|
|
|
+ this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Клиенты] SET [FIO] = @FIO, [Telepfone] = @Telepfone, [ID_Zakaza] = @ID_Zakaza WHERE (([ID_Klienta] = @Original_ID_Klienta) AND ([FIO] = @Original_FIO) AND ([Telepfone] = @Original_Telepfone) AND ((@IsNull_ID_Zakaza = 1 AND [ID_Zakaza] IS NULL) OR ([ID_Zakaza] = @Original_ID_Zakaza)));
|
|
|
+SELECT ID_Klienta, FIO, Telepfone, ID_Zakaza FROM Клиенты WHERE (ID_Klienta = @ID_Klienta)";
|
|
|
+ this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@FIO", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "FIO", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Telepfone", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Telepfone", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_FIO", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "FIO", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Telepfone", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Telepfone", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Zakaza", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Zakaza", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Klienta", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitConnection() {
|
|
|
+ this._connection = new global::System.Data.SqlClient.SqlConnection();
|
|
|
+ this._connection.ConnectionString = global::Lyakhov_Bilet10.Properties.Settings.Default.Lyakhov_Bilet10ConnectionString;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitCommandCollection() {
|
|
|
+ this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
|
|
|
+ this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._commandCollection[0].Connection = this.Connection;
|
|
|
+ this._commandCollection[0].CommandText = "SELECT ID_Klienta, FIO, Telepfone, ID_Zakaza FROM dbo.Клиенты";
|
|
|
+ this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
|
|
|
+ public virtual int Fill(Lyakhov_Bilet10DataSet.КлиентыDataTable dataTable) {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ if ((this.ClearBeforeFill == true)) {
|
|
|
+ dataTable.Clear();
|
|
|
+ }
|
|
|
+ int returnValue = this.Adapter.Fill(dataTable);
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
|
|
|
+ public virtual Lyakhov_Bilet10DataSet.КлиентыDataTable GetData() {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ Lyakhov_Bilet10DataSet.КлиентыDataTable dataTable = new Lyakhov_Bilet10DataSet.КлиентыDataTable();
|
|
|
+ this.Adapter.Fill(dataTable);
|
|
|
+ return dataTable;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet.КлиентыDataTable dataTable) {
|
|
|
+ return this.Adapter.Update(dataTable);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet dataSet) {
|
|
|
+ return this.Adapter.Update(dataSet, "Клиенты");
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow dataRow) {
|
|
|
+ return this.Adapter.Update(new global::System.Data.DataRow[] {
|
|
|
+ dataRow});
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow[] dataRows) {
|
|
|
+ return this.Adapter.Update(dataRows);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
|
|
|
+ public virtual int Delete(int Original_ID_Klienta, string Original_FIO, string Original_Telepfone, global::System.Nullable<int> Original_ID_Zakaza) {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_ID_Klienta));
|
|
|
+ if ((Original_FIO == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_FIO");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[1].Value = ((string)(Original_FIO));
|
|
|
+ }
|
|
|
+ if ((Original_Telepfone == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_Telepfone");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_Telepfone));
|
|
|
+ }
|
|
|
+ if ((Original_ID_Zakaza.HasValue == true)) {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
|
|
|
+ this.Adapter.DeleteCommand.Parameters[4].Value = ((int)(Original_ID_Zakaza.Value));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
|
|
|
+ this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
|
|
|
+ }
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
|
|
|
+ if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
|
|
|
+ public virtual int Insert(string FIO, string Telepfone, global::System.Nullable<int> ID_Zakaza) {
|
|
|
+ if ((FIO == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("FIO");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.InsertCommand.Parameters[0].Value = ((string)(FIO));
|
|
|
+ }
|
|
|
+ if ((Telepfone == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Telepfone");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.InsertCommand.Parameters[1].Value = ((string)(Telepfone));
|
|
|
+ }
|
|
|
+ if ((ID_Zakaza.HasValue == true)) {
|
|
|
+ this.Adapter.InsertCommand.Parameters[2].Value = ((int)(ID_Zakaza.Value));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
|
|
|
+ }
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
|
|
|
+ if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(string FIO, string Telepfone, global::System.Nullable<int> ID_Zakaza, int Original_ID_Klienta, string Original_FIO, string Original_Telepfone, global::System.Nullable<int> Original_ID_Zakaza, int ID_Klienta) {
|
|
|
+ if ((FIO == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("FIO");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(FIO));
|
|
|
+ }
|
|
|
+ if ((Telepfone == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Telepfone");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[1].Value = ((string)(Telepfone));
|
|
|
+ }
|
|
|
+ if ((ID_Zakaza.HasValue == true)) {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(ID_Zakaza.Value));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
|
|
|
+ }
|
|
|
+ this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_ID_Klienta));
|
|
|
+ if ((Original_FIO == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_FIO");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[4].Value = ((string)(Original_FIO));
|
|
|
+ }
|
|
|
+ if ((Original_Telepfone == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_Telepfone");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[5].Value = ((string)(Original_Telepfone));
|
|
|
+ }
|
|
|
+ if ((Original_ID_Zakaza.HasValue == true)) {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[6].Value = ((object)(0));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[7].Value = ((int)(Original_ID_Zakaza.Value));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[6].Value = ((object)(1));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[7].Value = global::System.DBNull.Value;
|
|
|
+ }
|
|
|
+ this.Adapter.UpdateCommand.Parameters[8].Value = ((int)(ID_Klienta));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
|
|
|
+ if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(string FIO, string Telepfone, global::System.Nullable<int> ID_Zakaza, int Original_ID_Klienta, string Original_FIO, string Original_Telepfone, global::System.Nullable<int> Original_ID_Zakaza) {
|
|
|
+ return this.Update(FIO, Telepfone, ID_Zakaza, Original_ID_Klienta, Original_FIO, Original_Telepfone, Original_ID_Zakaza, Original_ID_Klienta);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the connection and commands used to retrieve and save data.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
|
+ [global::System.ComponentModel.ToolboxItem(true)]
|
|
|
+ [global::System.ComponentModel.DataObjectAttribute(true)]
|
|
|
+ [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
|
|
|
+ ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public partial class ТоварыTableAdapter : global::System.ComponentModel.Component {
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlDataAdapter _adapter;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlConnection _connection;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlTransaction _transaction;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
|
|
|
+
|
|
|
+ private bool _clearBeforeFill;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public ТоварыTableAdapter() {
|
|
|
+ this.ClearBeforeFill = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
|
|
|
+ get {
|
|
|
+ if ((this._adapter == null)) {
|
|
|
+ this.InitAdapter();
|
|
|
+ }
|
|
|
+ return this._adapter;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlConnection Connection {
|
|
|
+ get {
|
|
|
+ if ((this._connection == null)) {
|
|
|
+ this.InitConnection();
|
|
|
+ }
|
|
|
+ return this._connection;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._connection = value;
|
|
|
+ if ((this.Adapter.InsertCommand != null)) {
|
|
|
+ this.Adapter.InsertCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.DeleteCommand != null)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.UpdateCommand != null)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection = value;
|
|
|
+ }
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ if ((this.CommandCollection[i] != null)) {
|
|
|
+ ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlTransaction Transaction {
|
|
|
+ get {
|
|
|
+ return this._transaction;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._transaction = value;
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ this.CommandCollection[i].Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.DeleteCommand != null))) {
|
|
|
+ this.Adapter.DeleteCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.InsertCommand != null))) {
|
|
|
+ this.Adapter.InsertCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.UpdateCommand != null))) {
|
|
|
+ this.Adapter.UpdateCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
|
|
|
+ get {
|
|
|
+ if ((this._commandCollection == null)) {
|
|
|
+ this.InitCommandCollection();
|
|
|
+ }
|
|
|
+ return this._commandCollection;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public bool ClearBeforeFill {
|
|
|
+ get {
|
|
|
+ return this._clearBeforeFill;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._clearBeforeFill = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitAdapter() {
|
|
|
+ this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
|
|
|
+ global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
|
|
|
+ tableMapping.SourceTable = "Table";
|
|
|
+ tableMapping.DataSetTable = "Товары";
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Tovara", "ID_Tovara");
|
|
|
+ tableMapping.ColumnMappings.Add("Nazvanie", "Nazvanie");
|
|
|
+ tableMapping.ColumnMappings.Add("Cena", "Cena");
|
|
|
+ tableMapping.ColumnMappings.Add("ID_Klienta", "ID_Klienta");
|
|
|
+ this._adapter.TableMappings.Add(tableMapping);
|
|
|
+ this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.DeleteCommand.Connection = this.Connection;
|
|
|
+ this._adapter.DeleteCommand.CommandText = "DELETE FROM [dbo].[Товары] WHERE (([ID_Tovara] = @Original_ID_Tovara) AND ([Nazva" +
|
|
|
+ "nie] = @Original_Nazvanie) AND ([Cena] = @Original_Cena) AND ([ID_Klienta] = @Or" +
|
|
|
+ "iginal_ID_Klienta))";
|
|
|
+ this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.InsertCommand.Connection = this.Connection;
|
|
|
+ this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[Товары] ([Nazvanie], [Cena], [ID_Klienta]) VALUES (@Nazvanie, " +
|
|
|
+ "@Cena, @ID_Klienta);\r\nSELECT ID_Tovara, Nazvanie, Cena, ID_Klienta FROM Товары W" +
|
|
|
+ "HERE (ID_Tovara = SCOPE_IDENTITY())";
|
|
|
+ this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._adapter.UpdateCommand.Connection = this.Connection;
|
|
|
+ this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Товары] SET [Nazvanie] = @Nazvanie, [Cena] = @Cena, [ID_Klienta] = @ID_Klienta WHERE (([ID_Tovara] = @Original_ID_Tovara) AND ([Nazvanie] = @Original_Nazvanie) AND ([Cena] = @Original_Cena) AND ([ID_Klienta] = @Original_ID_Klienta));
|
|
|
+SELECT ID_Tovara, Nazvanie, Cena, ID_Klienta FROM Товары WHERE (ID_Tovara = @ID_Tovara)";
|
|
|
+ this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Tovara", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Nazvanie", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Nazvanie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_ID_Klienta", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Klienta", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
|
|
|
+ this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@ID_Tovara", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "ID_Tovara", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitConnection() {
|
|
|
+ this._connection = new global::System.Data.SqlClient.SqlConnection();
|
|
|
+ this._connection.ConnectionString = global::Lyakhov_Bilet10.Properties.Settings.Default.Lyakhov_Bilet10ConnectionString;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitCommandCollection() {
|
|
|
+ this._commandCollection = new global::System.Data.SqlClient.SqlCommand[2];
|
|
|
+ this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._commandCollection[0].Connection = this.Connection;
|
|
|
+ this._commandCollection[0].CommandText = "SELECT ID_Tovara, Nazvanie, Cena, ID_Klienta FROM dbo.Товары";
|
|
|
+ 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 = "SELECT ID_Tovara, Nazvanie, Cena, ID_Klienta FROM dbo.Товары";
|
|
|
+ this._commandCollection[1].CommandType = global::System.Data.CommandType.Text;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
|
|
|
+ public virtual int Fill(Lyakhov_Bilet10DataSet.ТоварыDataTable dataTable) {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ if ((this.ClearBeforeFill == true)) {
|
|
|
+ dataTable.Clear();
|
|
|
+ }
|
|
|
+ int returnValue = this.Adapter.Fill(dataTable);
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
|
|
|
+ public virtual Lyakhov_Bilet10DataSet.ТоварыDataTable GetData() {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ Lyakhov_Bilet10DataSet.ТоварыDataTable dataTable = new Lyakhov_Bilet10DataSet.ТоварыDataTable();
|
|
|
+ this.Adapter.Fill(dataTable);
|
|
|
+ return dataTable;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, false)]
|
|
|
+ public virtual int FillBy(Lyakhov_Bilet10DataSet.ТоварыDataTable dataTable) {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[1];
|
|
|
+ if ((this.ClearBeforeFill == true)) {
|
|
|
+ dataTable.Clear();
|
|
|
+ }
|
|
|
+ int returnValue = this.Adapter.Fill(dataTable);
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet.ТоварыDataTable dataTable) {
|
|
|
+ return this.Adapter.Update(dataTable);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(Lyakhov_Bilet10DataSet dataSet) {
|
|
|
+ return this.Adapter.Update(dataSet, "Товары");
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow dataRow) {
|
|
|
+ return this.Adapter.Update(new global::System.Data.DataRow[] {
|
|
|
+ dataRow});
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public virtual int Update(global::System.Data.DataRow[] dataRows) {
|
|
|
+ return this.Adapter.Update(dataRows);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
|
|
|
+ public virtual int Delete(int Original_ID_Tovara, string Original_Nazvanie, decimal Original_Cena, int Original_ID_Klienta) {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_ID_Tovara));
|
|
|
+ if ((Original_Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.DeleteCommand.Parameters[1].Value = ((string)(Original_Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.DeleteCommand.Parameters[2].Value = ((decimal)(Original_Cena));
|
|
|
+ this.Adapter.DeleteCommand.Parameters[3].Value = ((int)(Original_ID_Klienta));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
|
|
|
+ if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
|
|
|
+ public virtual int Insert(string Nazvanie, decimal Cena, int ID_Klienta) {
|
|
|
+ if ((Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.InsertCommand.Parameters[0].Value = ((string)(Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.InsertCommand.Parameters[1].Value = ((decimal)(Cena));
|
|
|
+ this.Adapter.InsertCommand.Parameters[2].Value = ((int)(ID_Klienta));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
|
|
|
+ if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.InsertCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(string Nazvanie, decimal Cena, int ID_Klienta, int Original_ID_Tovara, string Original_Nazvanie, decimal Original_Cena, int Original_ID_Klienta, int ID_Tovara) {
|
|
|
+ if ((Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.UpdateCommand.Parameters[1].Value = ((decimal)(Cena));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(ID_Klienta));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_ID_Tovara));
|
|
|
+ if ((Original_Nazvanie == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("Original_Nazvanie");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this.Adapter.UpdateCommand.Parameters[4].Value = ((string)(Original_Nazvanie));
|
|
|
+ }
|
|
|
+ this.Adapter.UpdateCommand.Parameters[5].Value = ((decimal)(Original_Cena));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(Original_ID_Klienta));
|
|
|
+ this.Adapter.UpdateCommand.Parameters[7].Value = ((int)(ID_Tovara));
|
|
|
+ global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
|
|
|
+ if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
|
|
|
+ != global::System.Data.ConnectionState.Open)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Open();
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection.Close();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
|
|
|
+ public virtual int Update(string Nazvanie, decimal Cena, int ID_Klienta, int Original_ID_Tovara, string Original_Nazvanie, decimal Original_Cena, int Original_ID_Klienta) {
|
|
|
+ return this.Update(Nazvanie, Cena, ID_Klienta, Original_ID_Tovara, Original_Nazvanie, Original_Cena, Original_ID_Klienta, Original_ID_Tovara);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Represents the connection and commands used to retrieve and save data.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
|
+ [global::System.ComponentModel.ToolboxItem(true)]
|
|
|
+ [global::System.ComponentModel.DataObjectAttribute(true)]
|
|
|
+ [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
|
|
|
+ ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ public partial class View_1TableAdapter : global::System.ComponentModel.Component {
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlDataAdapter _adapter;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlConnection _connection;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlTransaction _transaction;
|
|
|
+
|
|
|
+ private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
|
|
|
+
|
|
|
+ private bool _clearBeforeFill;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public View_1TableAdapter() {
|
|
|
+ this.ClearBeforeFill = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
|
|
|
+ get {
|
|
|
+ if ((this._adapter == null)) {
|
|
|
+ this.InitAdapter();
|
|
|
+ }
|
|
|
+ return this._adapter;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlConnection Connection {
|
|
|
+ get {
|
|
|
+ if ((this._connection == null)) {
|
|
|
+ this.InitConnection();
|
|
|
+ }
|
|
|
+ return this._connection;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._connection = value;
|
|
|
+ if ((this.Adapter.InsertCommand != null)) {
|
|
|
+ this.Adapter.InsertCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.DeleteCommand != null)) {
|
|
|
+ this.Adapter.DeleteCommand.Connection = value;
|
|
|
+ }
|
|
|
+ if ((this.Adapter.UpdateCommand != null)) {
|
|
|
+ this.Adapter.UpdateCommand.Connection = value;
|
|
|
+ }
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ if ((this.CommandCollection[i] != null)) {
|
|
|
+ ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal global::System.Data.SqlClient.SqlTransaction Transaction {
|
|
|
+ get {
|
|
|
+ return this._transaction;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._transaction = value;
|
|
|
+ for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
|
|
|
+ this.CommandCollection[i].Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.DeleteCommand != null))) {
|
|
|
+ this.Adapter.DeleteCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.InsertCommand != null))) {
|
|
|
+ this.Adapter.InsertCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ if (((this.Adapter != null)
|
|
|
+ && (this.Adapter.UpdateCommand != null))) {
|
|
|
+ this.Adapter.UpdateCommand.Transaction = this._transaction;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
|
|
|
+ get {
|
|
|
+ if ((this._commandCollection == null)) {
|
|
|
+ this.InitCommandCollection();
|
|
|
+ }
|
|
|
+ return this._commandCollection;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public bool ClearBeforeFill {
|
|
|
+ get {
|
|
|
+ return this._clearBeforeFill;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._clearBeforeFill = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitAdapter() {
|
|
|
+ this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
|
|
|
+ global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
|
|
|
+ tableMapping.SourceTable = "Table";
|
|
|
+ tableMapping.DataSetTable = "View_1";
|
|
|
+ tableMapping.ColumnMappings.Add("Дата", "Дата");
|
|
|
+ tableMapping.ColumnMappings.Add("Название", "Название");
|
|
|
+ this._adapter.TableMappings.Add(tableMapping);
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitConnection() {
|
|
|
+ this._connection = new global::System.Data.SqlClient.SqlConnection();
|
|
|
+ this._connection.ConnectionString = global::Lyakhov_Bilet10.Properties.Settings.Default.Lyakhov_Bilet10ConnectionString;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private void InitCommandCollection() {
|
|
|
+ this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
|
|
|
+ this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
|
|
|
+ this._commandCollection[0].Connection = this.Connection;
|
|
|
+ this._commandCollection[0].CommandText = "SELECT Дата, Название FROM dbo.View_1";
|
|
|
+ this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
|
|
|
+ public virtual int Fill(Lyakhov_Bilet10DataSet.View_1DataTable dataTable) {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ if ((this.ClearBeforeFill == true)) {
|
|
|
+ dataTable.Clear();
|
|
|
+ }
|
|
|
+ int returnValue = this.Adapter.Fill(dataTable);
|
|
|
+ return returnValue;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
|
|
|
+ [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
|
|
|
+ public virtual Lyakhov_Bilet10DataSet.View_1DataTable GetData() {
|
|
|
+ this.Adapter.SelectCommand = this.CommandCollection[0];
|
|
|
+ Lyakhov_Bilet10DataSet.View_1DataTable dataTable = new Lyakhov_Bilet10DataSet.View_1DataTable();
|
|
|
+ this.Adapter.Fill(dataTable);
|
|
|
+ return dataTable;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///TableAdapterManager is used to coordinate TableAdapters in the dataset to enable Hierarchical Update scenarios
|
|
|
+ ///</summary>
|
|
|
+ [global::System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
|
+ [global::System.ComponentModel.ToolboxItem(true)]
|
|
|
+ [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerDesigner, Microsoft.VSD" +
|
|
|
+ "esigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
|
|
|
+ [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapterManager")]
|
|
|
+ public partial class TableAdapterManager : global::System.ComponentModel.Component {
|
|
|
+
|
|
|
+ private UpdateOrderOption _updateOrder;
|
|
|
+
|
|
|
+ private ЗаказTableAdapter _заказTableAdapter;
|
|
|
+
|
|
|
+ private История_продажиTableAdapter _история_продажиTableAdapter;
|
|
|
+
|
|
|
+ private КлиентыTableAdapter _клиентыTableAdapter;
|
|
|
+
|
|
|
+ private ТоварыTableAdapter _товарыTableAdapter;
|
|
|
+
|
|
|
+ private bool _backupDataSetBeforeUpdate;
|
|
|
+
|
|
|
+ private global::System.Data.IDbConnection _connection;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public UpdateOrderOption UpdateOrder {
|
|
|
+ get {
|
|
|
+ return this._updateOrder;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._updateOrder = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
|
|
|
+ "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
|
|
|
+ "a", "System.Drawing.Design.UITypeEditor")]
|
|
|
+ public ЗаказTableAdapter ЗаказTableAdapter {
|
|
|
+ get {
|
|
|
+ return this._заказTableAdapter;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._заказTableAdapter = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
|
|
|
+ "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
|
|
|
+ "a", "System.Drawing.Design.UITypeEditor")]
|
|
|
+ public История_продажиTableAdapter История_продажиTableAdapter {
|
|
|
+ get {
|
|
|
+ return this._история_продажиTableAdapter;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._история_продажиTableAdapter = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
|
|
|
+ "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
|
|
|
+ "a", "System.Drawing.Design.UITypeEditor")]
|
|
|
+ public КлиентыTableAdapter КлиентыTableAdapter {
|
|
|
+ get {
|
|
|
+ return this._клиентыTableAdapter;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._клиентыTableAdapter = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
|
|
|
+ "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
|
|
|
+ "a", "System.Drawing.Design.UITypeEditor")]
|
|
|
+ public ТоварыTableAdapter ТоварыTableAdapter {
|
|
|
+ get {
|
|
|
+ return this._товарыTableAdapter;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._товарыTableAdapter = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public bool BackupDataSetBeforeUpdate {
|
|
|
+ get {
|
|
|
+ return this._backupDataSetBeforeUpdate;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._backupDataSetBeforeUpdate = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ public global::System.Data.IDbConnection Connection {
|
|
|
+ get {
|
|
|
+ if ((this._connection != null)) {
|
|
|
+ return this._connection;
|
|
|
+ }
|
|
|
+ if (((this._заказTableAdapter != null)
|
|
|
+ && (this._заказTableAdapter.Connection != null))) {
|
|
|
+ return this._заказTableAdapter.Connection;
|
|
|
+ }
|
|
|
+ if (((this._история_продажиTableAdapter != null)
|
|
|
+ && (this._история_продажиTableAdapter.Connection != null))) {
|
|
|
+ return this._история_продажиTableAdapter.Connection;
|
|
|
+ }
|
|
|
+ if (((this._клиентыTableAdapter != null)
|
|
|
+ && (this._клиентыTableAdapter.Connection != null))) {
|
|
|
+ return this._клиентыTableAdapter.Connection;
|
|
|
+ }
|
|
|
+ if (((this._товарыTableAdapter != null)
|
|
|
+ && (this._товарыTableAdapter.Connection != null))) {
|
|
|
+ return this._товарыTableAdapter.Connection;
|
|
|
+ }
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+ set {
|
|
|
+ this._connection = value;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ [global::System.ComponentModel.Browsable(false)]
|
|
|
+ public int TableAdapterInstanceCount {
|
|
|
+ get {
|
|
|
+ int count = 0;
|
|
|
+ if ((this._заказTableAdapter != null)) {
|
|
|
+ count = (count + 1);
|
|
|
+ }
|
|
|
+ if ((this._история_продажиTableAdapter != null)) {
|
|
|
+ count = (count + 1);
|
|
|
+ }
|
|
|
+ if ((this._клиентыTableAdapter != null)) {
|
|
|
+ count = (count + 1);
|
|
|
+ }
|
|
|
+ if ((this._товарыTableAdapter != null)) {
|
|
|
+ count = (count + 1);
|
|
|
+ }
|
|
|
+ return count;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Update rows in top-down order.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private int UpdateUpdatedRows(Lyakhov_Bilet10DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
|
|
|
+ int result = 0;
|
|
|
+ if ((this._клиентыTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] updatedRows = dataSet.Клиенты.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
|
|
|
+ updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
|
|
|
+ if (((updatedRows != null)
|
|
|
+ && (0 < updatedRows.Length))) {
|
|
|
+ result = (result + this._клиентыTableAdapter.Update(updatedRows));
|
|
|
+ allChangedRows.AddRange(updatedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._товарыTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] updatedRows = dataSet.Товары.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
|
|
|
+ updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
|
|
|
+ if (((updatedRows != null)
|
|
|
+ && (0 < updatedRows.Length))) {
|
|
|
+ result = (result + this._товарыTableAdapter.Update(updatedRows));
|
|
|
+ allChangedRows.AddRange(updatedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._заказTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] updatedRows = dataSet.Заказ.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
|
|
|
+ updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
|
|
|
+ if (((updatedRows != null)
|
|
|
+ && (0 < updatedRows.Length))) {
|
|
|
+ result = (result + this._заказTableAdapter.Update(updatedRows));
|
|
|
+ allChangedRows.AddRange(updatedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._история_продажиTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] updatedRows = dataSet.История_продажи.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
|
|
|
+ updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
|
|
|
+ if (((updatedRows != null)
|
|
|
+ && (0 < updatedRows.Length))) {
|
|
|
+ result = (result + this._история_продажиTableAdapter.Update(updatedRows));
|
|
|
+ allChangedRows.AddRange(updatedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return result;
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Insert rows in top-down order.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private int UpdateInsertedRows(Lyakhov_Bilet10DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
|
|
|
+ int result = 0;
|
|
|
+ if ((this._клиентыTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] addedRows = dataSet.Клиенты.Select(null, null, global::System.Data.DataViewRowState.Added);
|
|
|
+ if (((addedRows != null)
|
|
|
+ && (0 < addedRows.Length))) {
|
|
|
+ result = (result + this._клиентыTableAdapter.Update(addedRows));
|
|
|
+ allAddedRows.AddRange(addedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._товарыTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] addedRows = dataSet.Товары.Select(null, null, global::System.Data.DataViewRowState.Added);
|
|
|
+ if (((addedRows != null)
|
|
|
+ && (0 < addedRows.Length))) {
|
|
|
+ result = (result + this._товарыTableAdapter.Update(addedRows));
|
|
|
+ allAddedRows.AddRange(addedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._заказTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] addedRows = dataSet.Заказ.Select(null, null, global::System.Data.DataViewRowState.Added);
|
|
|
+ if (((addedRows != null)
|
|
|
+ && (0 < addedRows.Length))) {
|
|
|
+ result = (result + this._заказTableAdapter.Update(addedRows));
|
|
|
+ allAddedRows.AddRange(addedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._история_продажиTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] addedRows = dataSet.История_продажи.Select(null, null, global::System.Data.DataViewRowState.Added);
|
|
|
+ if (((addedRows != null)
|
|
|
+ && (0 < addedRows.Length))) {
|
|
|
+ result = (result + this._история_продажиTableAdapter.Update(addedRows));
|
|
|
+ allAddedRows.AddRange(addedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return result;
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Delete rows in bottom-up order.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private int UpdateDeletedRows(Lyakhov_Bilet10DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows) {
|
|
|
+ int result = 0;
|
|
|
+ if ((this._история_продажиTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] deletedRows = dataSet.История_продажи.Select(null, null, global::System.Data.DataViewRowState.Deleted);
|
|
|
+ if (((deletedRows != null)
|
|
|
+ && (0 < deletedRows.Length))) {
|
|
|
+ result = (result + this._история_продажиTableAdapter.Update(deletedRows));
|
|
|
+ allChangedRows.AddRange(deletedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._заказTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] deletedRows = dataSet.Заказ.Select(null, null, global::System.Data.DataViewRowState.Deleted);
|
|
|
+ if (((deletedRows != null)
|
|
|
+ && (0 < deletedRows.Length))) {
|
|
|
+ result = (result + this._заказTableAdapter.Update(deletedRows));
|
|
|
+ allChangedRows.AddRange(deletedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._товарыTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] deletedRows = dataSet.Товары.Select(null, null, global::System.Data.DataViewRowState.Deleted);
|
|
|
+ if (((deletedRows != null)
|
|
|
+ && (0 < deletedRows.Length))) {
|
|
|
+ result = (result + this._товарыTableAdapter.Update(deletedRows));
|
|
|
+ allChangedRows.AddRange(deletedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._клиентыTableAdapter != null)) {
|
|
|
+ global::System.Data.DataRow[] deletedRows = dataSet.Клиенты.Select(null, null, global::System.Data.DataViewRowState.Deleted);
|
|
|
+ if (((deletedRows != null)
|
|
|
+ && (0 < deletedRows.Length))) {
|
|
|
+ result = (result + this._клиентыTableAdapter.Update(deletedRows));
|
|
|
+ allChangedRows.AddRange(deletedRows);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return result;
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Remove inserted rows that become updated rows after calling TableAdapter.Update(inserted rows) first
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private global::System.Data.DataRow[] GetRealUpdatedRows(global::System.Data.DataRow[] updatedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
|
|
|
+ if (((updatedRows == null)
|
|
|
+ || (updatedRows.Length < 1))) {
|
|
|
+ return updatedRows;
|
|
|
+ }
|
|
|
+ if (((allAddedRows == null)
|
|
|
+ || (allAddedRows.Count < 1))) {
|
|
|
+ return updatedRows;
|
|
|
+ }
|
|
|
+ global::System.Collections.Generic.List<global::System.Data.DataRow> realUpdatedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
|
|
|
+ for (int i = 0; (i < updatedRows.Length); i = (i + 1)) {
|
|
|
+ global::System.Data.DataRow row = updatedRows[i];
|
|
|
+ if ((allAddedRows.Contains(row) == false)) {
|
|
|
+ realUpdatedRows.Add(row);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return realUpdatedRows.ToArray();
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Update all changes to the dataset.
|
|
|
+ ///</summary>
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public virtual int UpdateAll(Lyakhov_Bilet10DataSet dataSet) {
|
|
|
+ if ((dataSet == null)) {
|
|
|
+ throw new global::System.ArgumentNullException("dataSet");
|
|
|
+ }
|
|
|
+ if ((dataSet.HasChanges() == false)) {
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+ if (((this._заказTableAdapter != null)
|
|
|
+ && (this.MatchTableAdapterConnection(this._заказTableAdapter.Connection) == false))) {
|
|
|
+ throw new global::System.ArgumentException("Все адаптеры таблицы, управляемые диспетчером адаптера таблицы TableAdapterManage" +
|
|
|
+ "r, должны использовать одинаковую строку подключения.");
|
|
|
+ }
|
|
|
+ if (((this._история_продажиTableAdapter != null)
|
|
|
+ && (this.MatchTableAdapterConnection(this._история_продажиTableAdapter.Connection) == false))) {
|
|
|
+ throw new global::System.ArgumentException("Все адаптеры таблицы, управляемые диспетчером адаптера таблицы TableAdapterManage" +
|
|
|
+ "r, должны использовать одинаковую строку подключения.");
|
|
|
+ }
|
|
|
+ if (((this._клиентыTableAdapter != null)
|
|
|
+ && (this.MatchTableAdapterConnection(this._клиентыTableAdapter.Connection) == false))) {
|
|
|
+ throw new global::System.ArgumentException("Все адаптеры таблицы, управляемые диспетчером адаптера таблицы TableAdapterManage" +
|
|
|
+ "r, должны использовать одинаковую строку подключения.");
|
|
|
+ }
|
|
|
+ if (((this._товарыTableAdapter != null)
|
|
|
+ && (this.MatchTableAdapterConnection(this._товарыTableAdapter.Connection) == false))) {
|
|
|
+ throw new global::System.ArgumentException("Все адаптеры таблицы, управляемые диспетчером адаптера таблицы TableAdapterManage" +
|
|
|
+ "r, должны использовать одинаковую строку подключения.");
|
|
|
+ }
|
|
|
+ global::System.Data.IDbConnection workConnection = this.Connection;
|
|
|
+ if ((workConnection == null)) {
|
|
|
+ throw new global::System.ApplicationException("TableAdapterManager не содержит сведений о подключении. Укажите для каждого адапт" +
|
|
|
+ "ера таблицы TableAdapterManager допустимый экземпляр адаптера таблицы.");
|
|
|
+ }
|
|
|
+ bool workConnOpened = false;
|
|
|
+ if (((workConnection.State & global::System.Data.ConnectionState.Broken)
|
|
|
+ == global::System.Data.ConnectionState.Broken)) {
|
|
|
+ workConnection.Close();
|
|
|
+ }
|
|
|
+ if ((workConnection.State == global::System.Data.ConnectionState.Closed)) {
|
|
|
+ workConnection.Open();
|
|
|
+ workConnOpened = true;
|
|
|
+ }
|
|
|
+ global::System.Data.IDbTransaction workTransaction = workConnection.BeginTransaction();
|
|
|
+ if ((workTransaction == null)) {
|
|
|
+ throw new global::System.ApplicationException("Не удается начать транзакцию. Текущее соединение данных не поддерживает транзакци" +
|
|
|
+ "и или текущее состояние не позволяет начать транзакцию.");
|
|
|
+ }
|
|
|
+ global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
|
|
|
+ global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
|
|
|
+ global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter> adaptersWithAcceptChangesDuringUpdate = new global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter>();
|
|
|
+ global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection> revertConnections = new global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection>();
|
|
|
+ int result = 0;
|
|
|
+ global::System.Data.DataSet backupDataSet = null;
|
|
|
+ if (this.BackupDataSetBeforeUpdate) {
|
|
|
+ backupDataSet = new global::System.Data.DataSet();
|
|
|
+ backupDataSet.Merge(dataSet);
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ // ---- Prepare for update -----------
|
|
|
+ //
|
|
|
+ if ((this._заказTableAdapter != null)) {
|
|
|
+ revertConnections.Add(this._заказTableAdapter, this._заказTableAdapter.Connection);
|
|
|
+ this._заказTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
|
|
|
+ this._заказTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
|
|
|
+ if (this._заказTableAdapter.Adapter.AcceptChangesDuringUpdate) {
|
|
|
+ this._заказTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
|
|
|
+ adaptersWithAcceptChangesDuringUpdate.Add(this._заказTableAdapter.Adapter);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._история_продажиTableAdapter != null)) {
|
|
|
+ revertConnections.Add(this._история_продажиTableAdapter, this._история_продажиTableAdapter.Connection);
|
|
|
+ this._история_продажиTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
|
|
|
+ this._история_продажиTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
|
|
|
+ if (this._история_продажиTableAdapter.Adapter.AcceptChangesDuringUpdate) {
|
|
|
+ this._история_продажиTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
|
|
|
+ adaptersWithAcceptChangesDuringUpdate.Add(this._история_продажиTableAdapter.Adapter);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._клиентыTableAdapter != null)) {
|
|
|
+ revertConnections.Add(this._клиентыTableAdapter, this._клиентыTableAdapter.Connection);
|
|
|
+ this._клиентыTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
|
|
|
+ this._клиентыTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
|
|
|
+ if (this._клиентыTableAdapter.Adapter.AcceptChangesDuringUpdate) {
|
|
|
+ this._клиентыTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
|
|
|
+ adaptersWithAcceptChangesDuringUpdate.Add(this._клиентыTableAdapter.Adapter);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((this._товарыTableAdapter != null)) {
|
|
|
+ revertConnections.Add(this._товарыTableAdapter, this._товарыTableAdapter.Connection);
|
|
|
+ this._товарыTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
|
|
|
+ this._товарыTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
|
|
|
+ if (this._товарыTableAdapter.Adapter.AcceptChangesDuringUpdate) {
|
|
|
+ this._товарыTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
|
|
|
+ adaptersWithAcceptChangesDuringUpdate.Add(this._товарыTableAdapter.Adapter);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //
|
|
|
+ //---- Perform updates -----------
|
|
|
+ //
|
|
|
+ if ((this.UpdateOrder == UpdateOrderOption.UpdateInsertDelete)) {
|
|
|
+ result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
|
|
|
+ result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
|
|
|
+ result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
|
|
|
+ }
|
|
|
+ result = (result + this.UpdateDeletedRows(dataSet, allChangedRows));
|
|
|
+ //
|
|
|
+ //---- Commit updates -----------
|
|
|
+ //
|
|
|
+ workTransaction.Commit();
|
|
|
+ if ((0 < allAddedRows.Count)) {
|
|
|
+ global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
|
|
|
+ allAddedRows.CopyTo(rows);
|
|
|
+ for (int i = 0; (i < rows.Length); i = (i + 1)) {
|
|
|
+ global::System.Data.DataRow row = rows[i];
|
|
|
+ row.AcceptChanges();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if ((0 < allChangedRows.Count)) {
|
|
|
+ global::System.Data.DataRow[] rows = new System.Data.DataRow[allChangedRows.Count];
|
|
|
+ allChangedRows.CopyTo(rows);
|
|
|
+ for (int i = 0; (i < rows.Length); i = (i + 1)) {
|
|
|
+ global::System.Data.DataRow row = rows[i];
|
|
|
+ row.AcceptChanges();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ catch (global::System.Exception ex) {
|
|
|
+ workTransaction.Rollback();
|
|
|
+ // ---- Restore the dataset -----------
|
|
|
+ if (this.BackupDataSetBeforeUpdate) {
|
|
|
+ global::System.Diagnostics.Debug.Assert((backupDataSet != null));
|
|
|
+ dataSet.Clear();
|
|
|
+ dataSet.Merge(backupDataSet);
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ if ((0 < allAddedRows.Count)) {
|
|
|
+ global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
|
|
|
+ allAddedRows.CopyTo(rows);
|
|
|
+ for (int i = 0; (i < rows.Length); i = (i + 1)) {
|
|
|
+ global::System.Data.DataRow row = rows[i];
|
|
|
+ row.AcceptChanges();
|
|
|
+ row.SetAdded();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ throw ex;
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ if (workConnOpened) {
|
|
|
+ workConnection.Close();
|
|
|
+ }
|
|
|
+ if ((this._заказTableAdapter != null)) {
|
|
|
+ this._заказTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._заказTableAdapter]));
|
|
|
+ this._заказTableAdapter.Transaction = null;
|
|
|
+ }
|
|
|
+ if ((this._история_продажиTableAdapter != null)) {
|
|
|
+ this._история_продажиTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._история_продажиTableAdapter]));
|
|
|
+ this._история_продажиTableAdapter.Transaction = null;
|
|
|
+ }
|
|
|
+ if ((this._клиентыTableAdapter != null)) {
|
|
|
+ this._клиентыTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._клиентыTableAdapter]));
|
|
|
+ this._клиентыTableAdapter.Transaction = null;
|
|
|
+ }
|
|
|
+ if ((this._товарыTableAdapter != null)) {
|
|
|
+ this._товарыTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._товарыTableAdapter]));
|
|
|
+ this._товарыTableAdapter.Transaction = null;
|
|
|
+ }
|
|
|
+ if ((0 < adaptersWithAcceptChangesDuringUpdate.Count)) {
|
|
|
+ global::System.Data.Common.DataAdapter[] adapters = new System.Data.Common.DataAdapter[adaptersWithAcceptChangesDuringUpdate.Count];
|
|
|
+ adaptersWithAcceptChangesDuringUpdate.CopyTo(adapters);
|
|
|
+ for (int i = 0; (i < adapters.Length); i = (i + 1)) {
|
|
|
+ global::System.Data.Common.DataAdapter adapter = adapters[i];
|
|
|
+ adapter.AcceptChangesDuringUpdate = true;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return result;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected virtual void SortSelfReferenceRows(global::System.Data.DataRow[] rows, global::System.Data.DataRelation relation, bool childFirst) {
|
|
|
+ global::System.Array.Sort<global::System.Data.DataRow>(rows, new SelfReferenceComparer(relation, childFirst));
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ protected virtual bool MatchTableAdapterConnection(global::System.Data.IDbConnection inputConnection) {
|
|
|
+ if ((this._connection != null)) {
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if (((this.Connection == null)
|
|
|
+ || (inputConnection == null))) {
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if (string.Equals(this.Connection.ConnectionString, inputConnection.ConnectionString, global::System.StringComparison.Ordinal)) {
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Update Order Option
|
|
|
+ ///</summary>
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public enum UpdateOrderOption {
|
|
|
+
|
|
|
+ InsertUpdateDelete = 0,
|
|
|
+
|
|
|
+ UpdateInsertDelete = 1,
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ ///Used to sort self-referenced table's rows
|
|
|
+ ///</summary>
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private class SelfReferenceComparer : object, global::System.Collections.Generic.IComparer<global::System.Data.DataRow> {
|
|
|
+
|
|
|
+ private global::System.Data.DataRelation _relation;
|
|
|
+
|
|
|
+ private int _childFirst;
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ internal SelfReferenceComparer(global::System.Data.DataRelation relation, bool childFirst) {
|
|
|
+ this._relation = relation;
|
|
|
+ if (childFirst) {
|
|
|
+ this._childFirst = -1;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ this._childFirst = 1;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ private global::System.Data.DataRow GetRoot(global::System.Data.DataRow row, out int distance) {
|
|
|
+ global::System.Diagnostics.Debug.Assert((row != null));
|
|
|
+ global::System.Data.DataRow root = row;
|
|
|
+ distance = 0;
|
|
|
+
|
|
|
+ global::System.Collections.Generic.IDictionary<global::System.Data.DataRow, global::System.Data.DataRow> traversedRows = new global::System.Collections.Generic.Dictionary<global::System.Data.DataRow, global::System.Data.DataRow>();
|
|
|
+ traversedRows[row] = row;
|
|
|
+
|
|
|
+ global::System.Data.DataRow parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
|
|
|
+ for (
|
|
|
+ ; ((parent != null)
|
|
|
+ && (traversedRows.ContainsKey(parent) == false));
|
|
|
+ ) {
|
|
|
+ distance = (distance + 1);
|
|
|
+ root = parent;
|
|
|
+ traversedRows[parent] = parent;
|
|
|
+ parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
|
|
|
+ }
|
|
|
+
|
|
|
+ if ((distance == 0)) {
|
|
|
+ traversedRows.Clear();
|
|
|
+ traversedRows[row] = row;
|
|
|
+ parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
|
|
|
+ for (
|
|
|
+ ; ((parent != null)
|
|
|
+ && (traversedRows.ContainsKey(parent) == false));
|
|
|
+ ) {
|
|
|
+ distance = (distance + 1);
|
|
|
+ root = parent;
|
|
|
+ traversedRows[parent] = parent;
|
|
|
+ parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ return root;
|
|
|
+ }
|
|
|
+
|
|
|
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
|
|
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
|
|
|
+ public int Compare(global::System.Data.DataRow row1, global::System.Data.DataRow row2) {
|
|
|
+ if (object.ReferenceEquals(row1, row2)) {
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+ if ((row1 == null)) {
|
|
|
+ return -1;
|
|
|
+ }
|
|
|
+ if ((row2 == null)) {
|
|
|
+ return 1;
|
|
|
+ }
|
|
|
+
|
|
|
+ int distance1 = 0;
|
|
|
+ global::System.Data.DataRow root1 = this.GetRoot(row1, out distance1);
|
|
|
+
|
|
|
+ int distance2 = 0;
|
|
|
+ global::System.Data.DataRow root2 = this.GetRoot(row2, out distance2);
|
|
|
+
|
|
|
+ if (object.ReferenceEquals(root1, root2)) {
|
|
|
+ return (this._childFirst * distance1.CompareTo(distance2));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ global::System.Diagnostics.Debug.Assert(((root1.Table != null)
|
|
|
+ && (root2.Table != null)));
|
|
|
+ if ((root1.Table.Rows.IndexOf(root1) < root2.Table.Rows.IndexOf(root2))) {
|
|
|
+ return -1;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ return 1;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+#pragma warning restore 1591
|