ПМ5_ДергачевDataSet.Designer.cs 136 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271
  1. //------------------------------------------------------------------------------
  2. // <auto-generated>
  3. // Этот код создан программой.
  4. // Исполняемая версия:4.0.30319.42000
  5. //
  6. // Изменения в этом файле могут привести к неправильной работе и будут потеряны в случае
  7. // повторной генерации кода.
  8. // </auto-generated>
  9. //------------------------------------------------------------------------------
  10. #pragma warning disable 1591
  11. namespace Bilet5Dergachev {
  12. /// <summary>
  13. ///Represents a strongly typed in-memory cache of data.
  14. ///</summary>
  15. [global::System.Serializable()]
  16. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  17. [global::System.ComponentModel.ToolboxItem(true)]
  18. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedDataSetSchema")]
  19. [global::System.Xml.Serialization.XmlRootAttribute("ПМ5_ДергачевDataSet")]
  20. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.DataSet")]
  21. public partial class ПМ5_ДергачевDataSet : global::System.Data.DataSet {
  22. private ManufactureDataTable tableManufacture;
  23. private productsale_b_importDataTable tableproductsale_b_import;
  24. private global::System.Data.SchemaSerializationMode _schemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
  25. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  26. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  27. public ПМ5_ДергачевDataSet() {
  28. this.BeginInit();
  29. this.InitClass();
  30. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  31. base.Tables.CollectionChanged += schemaChangedHandler;
  32. base.Relations.CollectionChanged += schemaChangedHandler;
  33. this.EndInit();
  34. }
  35. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  36. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  37. protected ПМ5_ДергачевDataSet(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  38. base(info, context, false) {
  39. if ((this.IsBinarySerialized(info, context) == true)) {
  40. this.InitVars(false);
  41. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler1 = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  42. this.Tables.CollectionChanged += schemaChangedHandler1;
  43. this.Relations.CollectionChanged += schemaChangedHandler1;
  44. return;
  45. }
  46. string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
  47. if ((this.DetermineSchemaSerializationMode(info, context) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
  48. global::System.Data.DataSet ds = new global::System.Data.DataSet();
  49. ds.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
  50. if ((ds.Tables["Manufacture"] != null)) {
  51. base.Tables.Add(new ManufactureDataTable(ds.Tables["Manufacture"]));
  52. }
  53. if ((ds.Tables["productsale_b_import"] != null)) {
  54. base.Tables.Add(new productsale_b_importDataTable(ds.Tables["productsale_b_import"]));
  55. }
  56. this.DataSetName = ds.DataSetName;
  57. this.Prefix = ds.Prefix;
  58. this.Namespace = ds.Namespace;
  59. this.Locale = ds.Locale;
  60. this.CaseSensitive = ds.CaseSensitive;
  61. this.EnforceConstraints = ds.EnforceConstraints;
  62. this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
  63. this.InitVars();
  64. }
  65. else {
  66. this.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
  67. }
  68. this.GetSerializationData(info, context);
  69. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  70. base.Tables.CollectionChanged += schemaChangedHandler;
  71. this.Relations.CollectionChanged += schemaChangedHandler;
  72. }
  73. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  74. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  75. [global::System.ComponentModel.Browsable(false)]
  76. [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
  77. public ManufactureDataTable Manufacture {
  78. get {
  79. return this.tableManufacture;
  80. }
  81. }
  82. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  83. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  84. [global::System.ComponentModel.Browsable(false)]
  85. [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
  86. public productsale_b_importDataTable productsale_b_import {
  87. get {
  88. return this.tableproductsale_b_import;
  89. }
  90. }
  91. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  92. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  93. [global::System.ComponentModel.BrowsableAttribute(true)]
  94. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Visible)]
  95. public override global::System.Data.SchemaSerializationMode SchemaSerializationMode {
  96. get {
  97. return this._schemaSerializationMode;
  98. }
  99. set {
  100. this._schemaSerializationMode = value;
  101. }
  102. }
  103. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  104. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  105. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
  106. public new global::System.Data.DataTableCollection Tables {
  107. get {
  108. return base.Tables;
  109. }
  110. }
  111. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  112. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  113. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
  114. public new global::System.Data.DataRelationCollection Relations {
  115. get {
  116. return base.Relations;
  117. }
  118. }
  119. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  120. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  121. protected override void InitializeDerivedDataSet() {
  122. this.BeginInit();
  123. this.InitClass();
  124. this.EndInit();
  125. }
  126. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  127. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  128. public override global::System.Data.DataSet Clone() {
  129. ПМ5_ДергачевDataSet cln = ((ПМ5_ДергачевDataSet)(base.Clone()));
  130. cln.InitVars();
  131. cln.SchemaSerializationMode = this.SchemaSerializationMode;
  132. return cln;
  133. }
  134. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  135. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  136. protected override bool ShouldSerializeTables() {
  137. return false;
  138. }
  139. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  140. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  141. protected override bool ShouldSerializeRelations() {
  142. return false;
  143. }
  144. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  145. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  146. protected override void ReadXmlSerializable(global::System.Xml.XmlReader reader) {
  147. if ((this.DetermineSchemaSerializationMode(reader) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
  148. this.Reset();
  149. global::System.Data.DataSet ds = new global::System.Data.DataSet();
  150. ds.ReadXml(reader);
  151. if ((ds.Tables["Manufacture"] != null)) {
  152. base.Tables.Add(new ManufactureDataTable(ds.Tables["Manufacture"]));
  153. }
  154. if ((ds.Tables["productsale_b_import"] != null)) {
  155. base.Tables.Add(new productsale_b_importDataTable(ds.Tables["productsale_b_import"]));
  156. }
  157. this.DataSetName = ds.DataSetName;
  158. this.Prefix = ds.Prefix;
  159. this.Namespace = ds.Namespace;
  160. this.Locale = ds.Locale;
  161. this.CaseSensitive = ds.CaseSensitive;
  162. this.EnforceConstraints = ds.EnforceConstraints;
  163. this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
  164. this.InitVars();
  165. }
  166. else {
  167. this.ReadXml(reader);
  168. this.InitVars();
  169. }
  170. }
  171. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  172. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  173. protected override global::System.Xml.Schema.XmlSchema GetSchemaSerializable() {
  174. global::System.IO.MemoryStream stream = new global::System.IO.MemoryStream();
  175. this.WriteXmlSchema(new global::System.Xml.XmlTextWriter(stream, null));
  176. stream.Position = 0;
  177. return global::System.Xml.Schema.XmlSchema.Read(new global::System.Xml.XmlTextReader(stream), null);
  178. }
  179. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  180. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  181. internal void InitVars() {
  182. this.InitVars(true);
  183. }
  184. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  185. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  186. internal void InitVars(bool initTable) {
  187. this.tableManufacture = ((ManufactureDataTable)(base.Tables["Manufacture"]));
  188. if ((initTable == true)) {
  189. if ((this.tableManufacture != null)) {
  190. this.tableManufacture.InitVars();
  191. }
  192. }
  193. this.tableproductsale_b_import = ((productsale_b_importDataTable)(base.Tables["productsale_b_import"]));
  194. if ((initTable == true)) {
  195. if ((this.tableproductsale_b_import != null)) {
  196. this.tableproductsale_b_import.InitVars();
  197. }
  198. }
  199. }
  200. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  201. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  202. private void InitClass() {
  203. this.DataSetName = "ПМ5_ДергачевDataSet";
  204. this.Prefix = "";
  205. this.Namespace = "http://tempuri.org/ПМ5_ДергачевDataSet.xsd";
  206. this.EnforceConstraints = true;
  207. this.SchemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
  208. this.tableManufacture = new ManufactureDataTable();
  209. base.Tables.Add(this.tableManufacture);
  210. this.tableproductsale_b_import = new productsale_b_importDataTable();
  211. base.Tables.Add(this.tableproductsale_b_import);
  212. }
  213. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  214. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  215. private bool ShouldSerializeManufacture() {
  216. return false;
  217. }
  218. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  219. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  220. private bool ShouldSerializeproductsale_b_import() {
  221. return false;
  222. }
  223. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  224. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  225. private void SchemaChanged(object sender, global::System.ComponentModel.CollectionChangeEventArgs e) {
  226. if ((e.Action == global::System.ComponentModel.CollectionChangeAction.Remove)) {
  227. this.InitVars();
  228. }
  229. }
  230. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  231. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  232. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedDataSetSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  233. ПМ5_ДергачевDataSet ds = new ПМ5_ДергачевDataSet();
  234. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  235. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  236. global::System.Xml.Schema.XmlSchemaAny any = new global::System.Xml.Schema.XmlSchemaAny();
  237. any.Namespace = ds.Namespace;
  238. sequence.Items.Add(any);
  239. type.Particle = sequence;
  240. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  241. if (xs.Contains(dsSchema.TargetNamespace)) {
  242. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  243. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  244. try {
  245. global::System.Xml.Schema.XmlSchema schema = null;
  246. dsSchema.Write(s1);
  247. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  248. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  249. s2.SetLength(0);
  250. schema.Write(s2);
  251. if ((s1.Length == s2.Length)) {
  252. s1.Position = 0;
  253. s2.Position = 0;
  254. for (; ((s1.Position != s1.Length)
  255. && (s1.ReadByte() == s2.ReadByte())); ) {
  256. ;
  257. }
  258. if ((s1.Position == s1.Length)) {
  259. return type;
  260. }
  261. }
  262. }
  263. }
  264. finally {
  265. if ((s1 != null)) {
  266. s1.Close();
  267. }
  268. if ((s2 != null)) {
  269. s2.Close();
  270. }
  271. }
  272. }
  273. xs.Add(dsSchema);
  274. return type;
  275. }
  276. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  277. public delegate void ManufactureRowChangeEventHandler(object sender, ManufactureRowChangeEvent e);
  278. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  279. public delegate void productsale_b_importRowChangeEventHandler(object sender, productsale_b_importRowChangeEvent e);
  280. /// <summary>
  281. ///Represents the strongly named DataTable class.
  282. ///</summary>
  283. [global::System.Serializable()]
  284. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
  285. public partial class ManufactureDataTable : global::System.Data.TypedTableBase<ManufactureRow> {
  286. private global::System.Data.DataColumn columnid;
  287. private global::System.Data.DataColumn columnНазвание_производителя;
  288. private global::System.Data.DataColumn columnДата_начала_работы;
  289. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  290. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  291. public ManufactureDataTable() {
  292. this.TableName = "Manufacture";
  293. this.BeginInit();
  294. this.InitClass();
  295. this.EndInit();
  296. }
  297. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  298. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  299. internal ManufactureDataTable(global::System.Data.DataTable table) {
  300. this.TableName = table.TableName;
  301. if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
  302. this.CaseSensitive = table.CaseSensitive;
  303. }
  304. if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
  305. this.Locale = table.Locale;
  306. }
  307. if ((table.Namespace != table.DataSet.Namespace)) {
  308. this.Namespace = table.Namespace;
  309. }
  310. this.Prefix = table.Prefix;
  311. this.MinimumCapacity = table.MinimumCapacity;
  312. }
  313. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  314. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  315. protected ManufactureDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  316. base(info, context) {
  317. this.InitVars();
  318. }
  319. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  320. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  321. public global::System.Data.DataColumn idColumn {
  322. get {
  323. return this.columnid;
  324. }
  325. }
  326. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  327. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  328. public global::System.Data.DataColumn Название_производителяColumn {
  329. get {
  330. return this.columnНазвание_производителя;
  331. }
  332. }
  333. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  334. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  335. public global::System.Data.DataColumn Дата_начала_работыColumn {
  336. get {
  337. return this.columnДата_начала_работы;
  338. }
  339. }
  340. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  341. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  342. [global::System.ComponentModel.Browsable(false)]
  343. public int Count {
  344. get {
  345. return this.Rows.Count;
  346. }
  347. }
  348. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  349. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  350. public ManufactureRow this[int index] {
  351. get {
  352. return ((ManufactureRow)(this.Rows[index]));
  353. }
  354. }
  355. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  356. public event ManufactureRowChangeEventHandler ManufactureRowChanging;
  357. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  358. public event ManufactureRowChangeEventHandler ManufactureRowChanged;
  359. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  360. public event ManufactureRowChangeEventHandler ManufactureRowDeleting;
  361. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  362. public event ManufactureRowChangeEventHandler ManufactureRowDeleted;
  363. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  364. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  365. public void AddManufactureRow(ManufactureRow row) {
  366. this.Rows.Add(row);
  367. }
  368. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  369. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  370. public ManufactureRow AddManufactureRow(string Название_производителя, System.DateTime Дата_начала_работы) {
  371. ManufactureRow rowManufactureRow = ((ManufactureRow)(this.NewRow()));
  372. object[] columnValuesArray = new object[] {
  373. null,
  374. Название_производителя,
  375. Дата_начала_работы};
  376. rowManufactureRow.ItemArray = columnValuesArray;
  377. this.Rows.Add(rowManufactureRow);
  378. return rowManufactureRow;
  379. }
  380. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  381. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  382. public ManufactureRow FindByid(int id) {
  383. return ((ManufactureRow)(this.Rows.Find(new object[] {
  384. id})));
  385. }
  386. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  387. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  388. public override global::System.Data.DataTable Clone() {
  389. ManufactureDataTable cln = ((ManufactureDataTable)(base.Clone()));
  390. cln.InitVars();
  391. return cln;
  392. }
  393. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  394. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  395. protected override global::System.Data.DataTable CreateInstance() {
  396. return new ManufactureDataTable();
  397. }
  398. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  399. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  400. internal void InitVars() {
  401. this.columnid = base.Columns["id"];
  402. this.columnНазвание_производителя = base.Columns["Название_производителя"];
  403. this.columnДата_начала_работы = base.Columns["Дата_начала_работы"];
  404. }
  405. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  406. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  407. private void InitClass() {
  408. this.columnid = new global::System.Data.DataColumn("id", typeof(int), null, global::System.Data.MappingType.Element);
  409. base.Columns.Add(this.columnid);
  410. this.columnНазвание_производителя = new global::System.Data.DataColumn("Название_производителя", typeof(string), null, global::System.Data.MappingType.Element);
  411. base.Columns.Add(this.columnНазвание_производителя);
  412. this.columnДата_начала_работы = new global::System.Data.DataColumn("Дата_начала_работы", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element);
  413. base.Columns.Add(this.columnДата_начала_работы);
  414. this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
  415. this.columnid}, true));
  416. this.columnid.AutoIncrement = true;
  417. this.columnid.AutoIncrementSeed = -1;
  418. this.columnid.AutoIncrementStep = -1;
  419. this.columnid.AllowDBNull = false;
  420. this.columnid.ReadOnly = true;
  421. this.columnid.Unique = true;
  422. this.columnНазвание_производителя.AllowDBNull = false;
  423. this.columnНазвание_производителя.MaxLength = 100;
  424. this.columnДата_начала_работы.AllowDBNull = false;
  425. }
  426. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  427. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  428. public ManufactureRow NewManufactureRow() {
  429. return ((ManufactureRow)(this.NewRow()));
  430. }
  431. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  432. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  433. protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
  434. return new ManufactureRow(builder);
  435. }
  436. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  437. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  438. protected override global::System.Type GetRowType() {
  439. return typeof(ManufactureRow);
  440. }
  441. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  442. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  443. protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
  444. base.OnRowChanged(e);
  445. if ((this.ManufactureRowChanged != null)) {
  446. this.ManufactureRowChanged(this, new ManufactureRowChangeEvent(((ManufactureRow)(e.Row)), e.Action));
  447. }
  448. }
  449. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  450. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  451. protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
  452. base.OnRowChanging(e);
  453. if ((this.ManufactureRowChanging != null)) {
  454. this.ManufactureRowChanging(this, new ManufactureRowChangeEvent(((ManufactureRow)(e.Row)), e.Action));
  455. }
  456. }
  457. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  458. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  459. protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
  460. base.OnRowDeleted(e);
  461. if ((this.ManufactureRowDeleted != null)) {
  462. this.ManufactureRowDeleted(this, new ManufactureRowChangeEvent(((ManufactureRow)(e.Row)), e.Action));
  463. }
  464. }
  465. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  466. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  467. protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
  468. base.OnRowDeleting(e);
  469. if ((this.ManufactureRowDeleting != null)) {
  470. this.ManufactureRowDeleting(this, new ManufactureRowChangeEvent(((ManufactureRow)(e.Row)), e.Action));
  471. }
  472. }
  473. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  474. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  475. public void RemoveManufactureRow(ManufactureRow row) {
  476. this.Rows.Remove(row);
  477. }
  478. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  479. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  480. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  481. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  482. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  483. ПМ5_ДергачевDataSet ds = new ПМ5_ДергачевDataSet();
  484. global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
  485. any1.Namespace = "http://www.w3.org/2001/XMLSchema";
  486. any1.MinOccurs = new decimal(0);
  487. any1.MaxOccurs = decimal.MaxValue;
  488. any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  489. sequence.Items.Add(any1);
  490. global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
  491. any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
  492. any2.MinOccurs = new decimal(1);
  493. any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  494. sequence.Items.Add(any2);
  495. global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
  496. attribute1.Name = "namespace";
  497. attribute1.FixedValue = ds.Namespace;
  498. type.Attributes.Add(attribute1);
  499. global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
  500. attribute2.Name = "tableTypeName";
  501. attribute2.FixedValue = "ManufactureDataTable";
  502. type.Attributes.Add(attribute2);
  503. type.Particle = sequence;
  504. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  505. if (xs.Contains(dsSchema.TargetNamespace)) {
  506. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  507. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  508. try {
  509. global::System.Xml.Schema.XmlSchema schema = null;
  510. dsSchema.Write(s1);
  511. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  512. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  513. s2.SetLength(0);
  514. schema.Write(s2);
  515. if ((s1.Length == s2.Length)) {
  516. s1.Position = 0;
  517. s2.Position = 0;
  518. for (; ((s1.Position != s1.Length)
  519. && (s1.ReadByte() == s2.ReadByte())); ) {
  520. ;
  521. }
  522. if ((s1.Position == s1.Length)) {
  523. return type;
  524. }
  525. }
  526. }
  527. }
  528. finally {
  529. if ((s1 != null)) {
  530. s1.Close();
  531. }
  532. if ((s2 != null)) {
  533. s2.Close();
  534. }
  535. }
  536. }
  537. xs.Add(dsSchema);
  538. return type;
  539. }
  540. }
  541. /// <summary>
  542. ///Represents the strongly named DataTable class.
  543. ///</summary>
  544. [global::System.Serializable()]
  545. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
  546. public partial class productsale_b_importDataTable : global::System.Data.TypedTableBase<productsale_b_importRow> {
  547. private global::System.Data.DataColumn columnid;
  548. private global::System.Data.DataColumn columnТовар;
  549. private global::System.Data.DataColumn columnКоличество;
  550. private global::System.Data.DataColumn columnДата_и_время_продажи;
  551. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  552. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  553. public productsale_b_importDataTable() {
  554. this.TableName = "productsale_b_import";
  555. this.BeginInit();
  556. this.InitClass();
  557. this.EndInit();
  558. }
  559. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  560. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  561. internal productsale_b_importDataTable(global::System.Data.DataTable table) {
  562. this.TableName = table.TableName;
  563. if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
  564. this.CaseSensitive = table.CaseSensitive;
  565. }
  566. if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
  567. this.Locale = table.Locale;
  568. }
  569. if ((table.Namespace != table.DataSet.Namespace)) {
  570. this.Namespace = table.Namespace;
  571. }
  572. this.Prefix = table.Prefix;
  573. this.MinimumCapacity = table.MinimumCapacity;
  574. }
  575. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  576. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  577. protected productsale_b_importDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  578. base(info, context) {
  579. this.InitVars();
  580. }
  581. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  582. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  583. public global::System.Data.DataColumn idColumn {
  584. get {
  585. return this.columnid;
  586. }
  587. }
  588. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  589. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  590. public global::System.Data.DataColumn ТоварColumn {
  591. get {
  592. return this.columnТовар;
  593. }
  594. }
  595. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  596. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  597. public global::System.Data.DataColumn КоличествоColumn {
  598. get {
  599. return this.columnКоличество;
  600. }
  601. }
  602. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  603. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  604. public global::System.Data.DataColumn Дата_и_время_продажиColumn {
  605. get {
  606. return this.columnДата_и_время_продажи;
  607. }
  608. }
  609. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  610. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  611. [global::System.ComponentModel.Browsable(false)]
  612. public int Count {
  613. get {
  614. return this.Rows.Count;
  615. }
  616. }
  617. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  618. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  619. public productsale_b_importRow this[int index] {
  620. get {
  621. return ((productsale_b_importRow)(this.Rows[index]));
  622. }
  623. }
  624. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  625. public event productsale_b_importRowChangeEventHandler productsale_b_importRowChanging;
  626. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  627. public event productsale_b_importRowChangeEventHandler productsale_b_importRowChanged;
  628. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  629. public event productsale_b_importRowChangeEventHandler productsale_b_importRowDeleting;
  630. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  631. public event productsale_b_importRowChangeEventHandler productsale_b_importRowDeleted;
  632. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  633. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  634. public void Addproductsale_b_importRow(productsale_b_importRow row) {
  635. this.Rows.Add(row);
  636. }
  637. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  638. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  639. public productsale_b_importRow Addproductsale_b_importRow(string Товар, int Количество, string Дата_и_время_продажи) {
  640. productsale_b_importRow rowproductsale_b_importRow = ((productsale_b_importRow)(this.NewRow()));
  641. object[] columnValuesArray = new object[] {
  642. null,
  643. Товар,
  644. Количество,
  645. Дата_и_время_продажи};
  646. rowproductsale_b_importRow.ItemArray = columnValuesArray;
  647. this.Rows.Add(rowproductsale_b_importRow);
  648. return rowproductsale_b_importRow;
  649. }
  650. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  651. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  652. public productsale_b_importRow FindByid(int id) {
  653. return ((productsale_b_importRow)(this.Rows.Find(new object[] {
  654. id})));
  655. }
  656. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  657. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  658. public override global::System.Data.DataTable Clone() {
  659. productsale_b_importDataTable cln = ((productsale_b_importDataTable)(base.Clone()));
  660. cln.InitVars();
  661. return cln;
  662. }
  663. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  664. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  665. protected override global::System.Data.DataTable CreateInstance() {
  666. return new productsale_b_importDataTable();
  667. }
  668. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  669. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  670. internal void InitVars() {
  671. this.columnid = base.Columns["id"];
  672. this.columnТовар = base.Columns["Товар"];
  673. this.columnКоличество = base.Columns["Количество"];
  674. this.columnДата_и_время_продажи = base.Columns["Дата_и_время_продажи"];
  675. }
  676. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  677. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  678. private void InitClass() {
  679. this.columnid = new global::System.Data.DataColumn("id", typeof(int), null, global::System.Data.MappingType.Element);
  680. base.Columns.Add(this.columnid);
  681. this.columnТовар = new global::System.Data.DataColumn("Товар", typeof(string), null, global::System.Data.MappingType.Element);
  682. base.Columns.Add(this.columnТовар);
  683. this.columnКоличество = new global::System.Data.DataColumn("Количество", typeof(int), null, global::System.Data.MappingType.Element);
  684. base.Columns.Add(this.columnКоличество);
  685. this.columnДата_и_время_продажи = new global::System.Data.DataColumn("Дата_и_время_продажи", typeof(string), null, global::System.Data.MappingType.Element);
  686. base.Columns.Add(this.columnДата_и_время_продажи);
  687. this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
  688. this.columnid}, true));
  689. this.columnid.AutoIncrement = true;
  690. this.columnid.AutoIncrementSeed = -1;
  691. this.columnid.AutoIncrementStep = -1;
  692. this.columnid.AllowDBNull = false;
  693. this.columnid.ReadOnly = true;
  694. this.columnid.Unique = true;
  695. this.columnТовар.AllowDBNull = false;
  696. this.columnТовар.MaxLength = 100;
  697. this.columnКоличество.AllowDBNull = false;
  698. this.columnДата_и_время_продажи.AllowDBNull = false;
  699. this.columnДата_и_время_продажи.MaxLength = 50;
  700. }
  701. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  702. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  703. public productsale_b_importRow Newproductsale_b_importRow() {
  704. return ((productsale_b_importRow)(this.NewRow()));
  705. }
  706. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  707. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  708. protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
  709. return new productsale_b_importRow(builder);
  710. }
  711. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  712. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  713. protected override global::System.Type GetRowType() {
  714. return typeof(productsale_b_importRow);
  715. }
  716. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  717. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  718. protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
  719. base.OnRowChanged(e);
  720. if ((this.productsale_b_importRowChanged != null)) {
  721. this.productsale_b_importRowChanged(this, new productsale_b_importRowChangeEvent(((productsale_b_importRow)(e.Row)), e.Action));
  722. }
  723. }
  724. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  725. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  726. protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
  727. base.OnRowChanging(e);
  728. if ((this.productsale_b_importRowChanging != null)) {
  729. this.productsale_b_importRowChanging(this, new productsale_b_importRowChangeEvent(((productsale_b_importRow)(e.Row)), e.Action));
  730. }
  731. }
  732. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  733. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  734. protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
  735. base.OnRowDeleted(e);
  736. if ((this.productsale_b_importRowDeleted != null)) {
  737. this.productsale_b_importRowDeleted(this, new productsale_b_importRowChangeEvent(((productsale_b_importRow)(e.Row)), e.Action));
  738. }
  739. }
  740. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  741. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  742. protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
  743. base.OnRowDeleting(e);
  744. if ((this.productsale_b_importRowDeleting != null)) {
  745. this.productsale_b_importRowDeleting(this, new productsale_b_importRowChangeEvent(((productsale_b_importRow)(e.Row)), e.Action));
  746. }
  747. }
  748. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  749. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  750. public void Removeproductsale_b_importRow(productsale_b_importRow row) {
  751. this.Rows.Remove(row);
  752. }
  753. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  754. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  755. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  756. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  757. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  758. ПМ5_ДергачевDataSet ds = new ПМ5_ДергачевDataSet();
  759. global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
  760. any1.Namespace = "http://www.w3.org/2001/XMLSchema";
  761. any1.MinOccurs = new decimal(0);
  762. any1.MaxOccurs = decimal.MaxValue;
  763. any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  764. sequence.Items.Add(any1);
  765. global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
  766. any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
  767. any2.MinOccurs = new decimal(1);
  768. any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  769. sequence.Items.Add(any2);
  770. global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
  771. attribute1.Name = "namespace";
  772. attribute1.FixedValue = ds.Namespace;
  773. type.Attributes.Add(attribute1);
  774. global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
  775. attribute2.Name = "tableTypeName";
  776. attribute2.FixedValue = "productsale_b_importDataTable";
  777. type.Attributes.Add(attribute2);
  778. type.Particle = sequence;
  779. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  780. if (xs.Contains(dsSchema.TargetNamespace)) {
  781. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  782. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  783. try {
  784. global::System.Xml.Schema.XmlSchema schema = null;
  785. dsSchema.Write(s1);
  786. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  787. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  788. s2.SetLength(0);
  789. schema.Write(s2);
  790. if ((s1.Length == s2.Length)) {
  791. s1.Position = 0;
  792. s2.Position = 0;
  793. for (; ((s1.Position != s1.Length)
  794. && (s1.ReadByte() == s2.ReadByte())); ) {
  795. ;
  796. }
  797. if ((s1.Position == s1.Length)) {
  798. return type;
  799. }
  800. }
  801. }
  802. }
  803. finally {
  804. if ((s1 != null)) {
  805. s1.Close();
  806. }
  807. if ((s2 != null)) {
  808. s2.Close();
  809. }
  810. }
  811. }
  812. xs.Add(dsSchema);
  813. return type;
  814. }
  815. }
  816. /// <summary>
  817. ///Represents strongly named DataRow class.
  818. ///</summary>
  819. public partial class ManufactureRow : global::System.Data.DataRow {
  820. private ManufactureDataTable tableManufacture;
  821. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  822. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  823. internal ManufactureRow(global::System.Data.DataRowBuilder rb) :
  824. base(rb) {
  825. this.tableManufacture = ((ManufactureDataTable)(this.Table));
  826. }
  827. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  828. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  829. public int id {
  830. get {
  831. return ((int)(this[this.tableManufacture.idColumn]));
  832. }
  833. set {
  834. this[this.tableManufacture.idColumn] = value;
  835. }
  836. }
  837. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  838. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  839. public string Название_производителя {
  840. get {
  841. return ((string)(this[this.tableManufacture.Название_производителяColumn]));
  842. }
  843. set {
  844. this[this.tableManufacture.Название_производителяColumn] = value;
  845. }
  846. }
  847. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  848. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  849. public System.DateTime Дата_начала_работы {
  850. get {
  851. return ((global::System.DateTime)(this[this.tableManufacture.Дата_начала_работыColumn]));
  852. }
  853. set {
  854. this[this.tableManufacture.Дата_начала_работыColumn] = value;
  855. }
  856. }
  857. }
  858. /// <summary>
  859. ///Represents strongly named DataRow class.
  860. ///</summary>
  861. public partial class productsale_b_importRow : global::System.Data.DataRow {
  862. private productsale_b_importDataTable tableproductsale_b_import;
  863. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  864. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  865. internal productsale_b_importRow(global::System.Data.DataRowBuilder rb) :
  866. base(rb) {
  867. this.tableproductsale_b_import = ((productsale_b_importDataTable)(this.Table));
  868. }
  869. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  870. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  871. public int id {
  872. get {
  873. return ((int)(this[this.tableproductsale_b_import.idColumn]));
  874. }
  875. set {
  876. this[this.tableproductsale_b_import.idColumn] = value;
  877. }
  878. }
  879. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  880. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  881. public string Товар {
  882. get {
  883. return ((string)(this[this.tableproductsale_b_import.ТоварColumn]));
  884. }
  885. set {
  886. this[this.tableproductsale_b_import.ТоварColumn] = value;
  887. }
  888. }
  889. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  890. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  891. public int Количество {
  892. get {
  893. return ((int)(this[this.tableproductsale_b_import.КоличествоColumn]));
  894. }
  895. set {
  896. this[this.tableproductsale_b_import.КоличествоColumn] = value;
  897. }
  898. }
  899. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  900. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  901. public string Дата_и_время_продажи {
  902. get {
  903. return ((string)(this[this.tableproductsale_b_import.Дата_и_время_продажиColumn]));
  904. }
  905. set {
  906. this[this.tableproductsale_b_import.Дата_и_время_продажиColumn] = value;
  907. }
  908. }
  909. }
  910. /// <summary>
  911. ///Row event argument class
  912. ///</summary>
  913. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  914. public class ManufactureRowChangeEvent : global::System.EventArgs {
  915. private ManufactureRow eventRow;
  916. private global::System.Data.DataRowAction eventAction;
  917. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  918. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  919. public ManufactureRowChangeEvent(ManufactureRow row, global::System.Data.DataRowAction action) {
  920. this.eventRow = row;
  921. this.eventAction = action;
  922. }
  923. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  924. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  925. public ManufactureRow Row {
  926. get {
  927. return this.eventRow;
  928. }
  929. }
  930. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  931. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  932. public global::System.Data.DataRowAction Action {
  933. get {
  934. return this.eventAction;
  935. }
  936. }
  937. }
  938. /// <summary>
  939. ///Row event argument class
  940. ///</summary>
  941. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  942. public class productsale_b_importRowChangeEvent : global::System.EventArgs {
  943. private productsale_b_importRow eventRow;
  944. private global::System.Data.DataRowAction eventAction;
  945. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  946. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  947. public productsale_b_importRowChangeEvent(productsale_b_importRow row, global::System.Data.DataRowAction action) {
  948. this.eventRow = row;
  949. this.eventAction = action;
  950. }
  951. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  952. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  953. public productsale_b_importRow Row {
  954. get {
  955. return this.eventRow;
  956. }
  957. }
  958. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  959. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  960. public global::System.Data.DataRowAction Action {
  961. get {
  962. return this.eventAction;
  963. }
  964. }
  965. }
  966. }
  967. }
  968. namespace Bilet5Dergachev.ПМ5_ДергачевDataSetTableAdapters {
  969. /// <summary>
  970. ///Represents the connection and commands used to retrieve and save data.
  971. ///</summary>
  972. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  973. [global::System.ComponentModel.ToolboxItem(true)]
  974. [global::System.ComponentModel.DataObjectAttribute(true)]
  975. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
  976. ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  977. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  978. public partial class ManufactureTableAdapter : global::System.ComponentModel.Component {
  979. private global::System.Data.SqlClient.SqlDataAdapter _adapter;
  980. private global::System.Data.SqlClient.SqlConnection _connection;
  981. private global::System.Data.SqlClient.SqlTransaction _transaction;
  982. private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
  983. private bool _clearBeforeFill;
  984. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  985. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  986. public ManufactureTableAdapter() {
  987. this.ClearBeforeFill = true;
  988. }
  989. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  990. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  991. protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
  992. get {
  993. if ((this._adapter == null)) {
  994. this.InitAdapter();
  995. }
  996. return this._adapter;
  997. }
  998. }
  999. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1000. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1001. internal global::System.Data.SqlClient.SqlConnection Connection {
  1002. get {
  1003. if ((this._connection == null)) {
  1004. this.InitConnection();
  1005. }
  1006. return this._connection;
  1007. }
  1008. set {
  1009. this._connection = value;
  1010. if ((this.Adapter.InsertCommand != null)) {
  1011. this.Adapter.InsertCommand.Connection = value;
  1012. }
  1013. if ((this.Adapter.DeleteCommand != null)) {
  1014. this.Adapter.DeleteCommand.Connection = value;
  1015. }
  1016. if ((this.Adapter.UpdateCommand != null)) {
  1017. this.Adapter.UpdateCommand.Connection = value;
  1018. }
  1019. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  1020. if ((this.CommandCollection[i] != null)) {
  1021. ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
  1022. }
  1023. }
  1024. }
  1025. }
  1026. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1027. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1028. internal global::System.Data.SqlClient.SqlTransaction Transaction {
  1029. get {
  1030. return this._transaction;
  1031. }
  1032. set {
  1033. this._transaction = value;
  1034. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  1035. this.CommandCollection[i].Transaction = this._transaction;
  1036. }
  1037. if (((this.Adapter != null)
  1038. && (this.Adapter.DeleteCommand != null))) {
  1039. this.Adapter.DeleteCommand.Transaction = this._transaction;
  1040. }
  1041. if (((this.Adapter != null)
  1042. && (this.Adapter.InsertCommand != null))) {
  1043. this.Adapter.InsertCommand.Transaction = this._transaction;
  1044. }
  1045. if (((this.Adapter != null)
  1046. && (this.Adapter.UpdateCommand != null))) {
  1047. this.Adapter.UpdateCommand.Transaction = this._transaction;
  1048. }
  1049. }
  1050. }
  1051. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1052. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1053. protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
  1054. get {
  1055. if ((this._commandCollection == null)) {
  1056. this.InitCommandCollection();
  1057. }
  1058. return this._commandCollection;
  1059. }
  1060. }
  1061. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1062. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1063. public bool ClearBeforeFill {
  1064. get {
  1065. return this._clearBeforeFill;
  1066. }
  1067. set {
  1068. this._clearBeforeFill = value;
  1069. }
  1070. }
  1071. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1072. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1073. private void InitAdapter() {
  1074. this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
  1075. global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
  1076. tableMapping.SourceTable = "Table";
  1077. tableMapping.DataSetTable = "Manufacture";
  1078. tableMapping.ColumnMappings.Add("id", "id");
  1079. tableMapping.ColumnMappings.Add("Название_производителя", "Название_производителя");
  1080. tableMapping.ColumnMappings.Add("Дата_начала_работы", "Дата_начала_работы");
  1081. this._adapter.TableMappings.Add(tableMapping);
  1082. this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
  1083. this._adapter.DeleteCommand.Connection = this.Connection;
  1084. this._adapter.DeleteCommand.CommandText = "DELETE FROM [dbo].[Manufacture] WHERE (([id] = @Original_id) AND ([Название_произ" +
  1085. "водителя] = @Original_Название_производителя) AND ([Дата_начала_работы] = @Origi" +
  1086. "nal_Дата_начала_работы))";
  1087. this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
  1088. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_id", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "id", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1089. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Название_производителя", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Название_производителя", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1090. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Дата_начала_работы", global::System.Data.SqlDbType.DateTime2, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_начала_работы", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1091. this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
  1092. this._adapter.InsertCommand.Connection = this.Connection;
  1093. this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[Manufacture] ([Название_производителя], [Дата_начала_работы]) " +
  1094. "VALUES (@Название_производителя, @Дата_начала_работы);\r\nSELECT id, Название_прои" +
  1095. "зводителя, Дата_начала_работы FROM Manufacture WHERE (id = SCOPE_IDENTITY())";
  1096. this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
  1097. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Название_производителя", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Название_производителя", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1098. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Дата_начала_работы", global::System.Data.SqlDbType.DateTime2, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_начала_работы", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1099. this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
  1100. this._adapter.UpdateCommand.Connection = this.Connection;
  1101. this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Manufacture] SET [Название_производителя] = @Название_производителя, [Дата_начала_работы] = @Дата_начала_работы WHERE (([id] = @Original_id) AND ([Название_производителя] = @Original_Название_производителя) AND ([Дата_начала_работы] = @Original_Дата_начала_работы));
  1102. SELECT id, Название_производителя, Дата_начала_работы FROM Manufacture WHERE (id = @id)";
  1103. this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
  1104. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Название_производителя", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Название_производителя", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1105. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Дата_начала_работы", global::System.Data.SqlDbType.DateTime2, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_начала_работы", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1106. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_id", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "id", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1107. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Название_производителя", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Название_производителя", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1108. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Дата_начала_работы", global::System.Data.SqlDbType.DateTime2, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_начала_работы", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1109. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@id", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "id", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1110. }
  1111. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1112. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1113. private void InitConnection() {
  1114. this._connection = new global::System.Data.SqlClient.SqlConnection();
  1115. this._connection.ConnectionString = global::Bilet5Dergachev.Properties.Settings.Default.ПМ5_ДергачевConnectionString;
  1116. }
  1117. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1118. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1119. private void InitCommandCollection() {
  1120. this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
  1121. this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
  1122. this._commandCollection[0].Connection = this.Connection;
  1123. this._commandCollection[0].CommandText = "SELECT id, Название_производителя, Дата_начала_работы FROM dbo.Manufacture";
  1124. this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
  1125. }
  1126. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1127. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1128. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1129. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
  1130. public virtual int Fill(ПМ5_ДергачевDataSet.ManufactureDataTable dataTable) {
  1131. this.Adapter.SelectCommand = this.CommandCollection[0];
  1132. if ((this.ClearBeforeFill == true)) {
  1133. dataTable.Clear();
  1134. }
  1135. int returnValue = this.Adapter.Fill(dataTable);
  1136. return returnValue;
  1137. }
  1138. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1139. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1140. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1141. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
  1142. public virtual ПМ5_ДергачевDataSet.ManufactureDataTable GetData() {
  1143. this.Adapter.SelectCommand = this.CommandCollection[0];
  1144. ПМ5_ДергачевDataSet.ManufactureDataTable dataTable = new ПМ5_ДергачевDataSet.ManufactureDataTable();
  1145. this.Adapter.Fill(dataTable);
  1146. return dataTable;
  1147. }
  1148. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1149. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1150. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1151. public virtual int Update(ПМ5_ДергачевDataSet.ManufactureDataTable dataTable) {
  1152. return this.Adapter.Update(dataTable);
  1153. }
  1154. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1155. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1156. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1157. public virtual int Update(ПМ5_ДергачевDataSet dataSet) {
  1158. return this.Adapter.Update(dataSet, "Manufacture");
  1159. }
  1160. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1161. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1162. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1163. public virtual int Update(global::System.Data.DataRow dataRow) {
  1164. return this.Adapter.Update(new global::System.Data.DataRow[] {
  1165. dataRow});
  1166. }
  1167. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1168. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1169. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1170. public virtual int Update(global::System.Data.DataRow[] dataRows) {
  1171. return this.Adapter.Update(dataRows);
  1172. }
  1173. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1174. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1175. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1176. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
  1177. public virtual int Delete(int Original_id, string Original_Название_производителя, System.DateTime Original_Дата_начала_работы) {
  1178. this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_id));
  1179. if ((Original_Название_производителя == null)) {
  1180. throw new global::System.ArgumentNullException("Original_Название_производителя");
  1181. }
  1182. else {
  1183. this.Adapter.DeleteCommand.Parameters[1].Value = ((string)(Original_Название_производителя));
  1184. }
  1185. this.Adapter.DeleteCommand.Parameters[2].Value = ((System.DateTime)(Original_Дата_начала_работы));
  1186. global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
  1187. if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
  1188. != global::System.Data.ConnectionState.Open)) {
  1189. this.Adapter.DeleteCommand.Connection.Open();
  1190. }
  1191. try {
  1192. int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
  1193. return returnValue;
  1194. }
  1195. finally {
  1196. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  1197. this.Adapter.DeleteCommand.Connection.Close();
  1198. }
  1199. }
  1200. }
  1201. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1202. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1203. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1204. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
  1205. public virtual int Insert(string Название_производителя, System.DateTime Дата_начала_работы) {
  1206. if ((Название_производителя == null)) {
  1207. throw new global::System.ArgumentNullException("Название_производителя");
  1208. }
  1209. else {
  1210. this.Adapter.InsertCommand.Parameters[0].Value = ((string)(Название_производителя));
  1211. }
  1212. this.Adapter.InsertCommand.Parameters[1].Value = ((System.DateTime)(Дата_начала_работы));
  1213. global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
  1214. if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
  1215. != global::System.Data.ConnectionState.Open)) {
  1216. this.Adapter.InsertCommand.Connection.Open();
  1217. }
  1218. try {
  1219. int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
  1220. return returnValue;
  1221. }
  1222. finally {
  1223. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  1224. this.Adapter.InsertCommand.Connection.Close();
  1225. }
  1226. }
  1227. }
  1228. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1229. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1230. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1231. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  1232. public virtual int Update(string Название_производителя, System.DateTime Дата_начала_работы, int Original_id, string Original_Название_производителя, System.DateTime Original_Дата_начала_работы, int id) {
  1233. if ((Название_производителя == null)) {
  1234. throw new global::System.ArgumentNullException("Название_производителя");
  1235. }
  1236. else {
  1237. this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(Название_производителя));
  1238. }
  1239. this.Adapter.UpdateCommand.Parameters[1].Value = ((System.DateTime)(Дата_начала_работы));
  1240. this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(Original_id));
  1241. if ((Original_Название_производителя == null)) {
  1242. throw new global::System.ArgumentNullException("Original_Название_производителя");
  1243. }
  1244. else {
  1245. this.Adapter.UpdateCommand.Parameters[3].Value = ((string)(Original_Название_производителя));
  1246. }
  1247. this.Adapter.UpdateCommand.Parameters[4].Value = ((System.DateTime)(Original_Дата_начала_работы));
  1248. this.Adapter.UpdateCommand.Parameters[5].Value = ((int)(id));
  1249. global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
  1250. if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
  1251. != global::System.Data.ConnectionState.Open)) {
  1252. this.Adapter.UpdateCommand.Connection.Open();
  1253. }
  1254. try {
  1255. int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
  1256. return returnValue;
  1257. }
  1258. finally {
  1259. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  1260. this.Adapter.UpdateCommand.Connection.Close();
  1261. }
  1262. }
  1263. }
  1264. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1265. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1266. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1267. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  1268. public virtual int Update(string Название_производителя, System.DateTime Дата_начала_работы, int Original_id, string Original_Название_производителя, System.DateTime Original_Дата_начала_работы) {
  1269. return this.Update(Название_производителя, Дата_начала_работы, Original_id, Original_Название_производителя, Original_Дата_начала_работы, Original_id);
  1270. }
  1271. }
  1272. /// <summary>
  1273. ///Represents the connection and commands used to retrieve and save data.
  1274. ///</summary>
  1275. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  1276. [global::System.ComponentModel.ToolboxItem(true)]
  1277. [global::System.ComponentModel.DataObjectAttribute(true)]
  1278. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
  1279. ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  1280. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1281. public partial class productsale_b_importTableAdapter : global::System.ComponentModel.Component {
  1282. private global::System.Data.SqlClient.SqlDataAdapter _adapter;
  1283. private global::System.Data.SqlClient.SqlConnection _connection;
  1284. private global::System.Data.SqlClient.SqlTransaction _transaction;
  1285. private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
  1286. private bool _clearBeforeFill;
  1287. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1288. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1289. public productsale_b_importTableAdapter() {
  1290. this.ClearBeforeFill = true;
  1291. }
  1292. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1293. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1294. protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
  1295. get {
  1296. if ((this._adapter == null)) {
  1297. this.InitAdapter();
  1298. }
  1299. return this._adapter;
  1300. }
  1301. }
  1302. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1303. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1304. internal global::System.Data.SqlClient.SqlConnection Connection {
  1305. get {
  1306. if ((this._connection == null)) {
  1307. this.InitConnection();
  1308. }
  1309. return this._connection;
  1310. }
  1311. set {
  1312. this._connection = value;
  1313. if ((this.Adapter.InsertCommand != null)) {
  1314. this.Adapter.InsertCommand.Connection = value;
  1315. }
  1316. if ((this.Adapter.DeleteCommand != null)) {
  1317. this.Adapter.DeleteCommand.Connection = value;
  1318. }
  1319. if ((this.Adapter.UpdateCommand != null)) {
  1320. this.Adapter.UpdateCommand.Connection = value;
  1321. }
  1322. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  1323. if ((this.CommandCollection[i] != null)) {
  1324. ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
  1325. }
  1326. }
  1327. }
  1328. }
  1329. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1330. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1331. internal global::System.Data.SqlClient.SqlTransaction Transaction {
  1332. get {
  1333. return this._transaction;
  1334. }
  1335. set {
  1336. this._transaction = value;
  1337. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  1338. this.CommandCollection[i].Transaction = this._transaction;
  1339. }
  1340. if (((this.Adapter != null)
  1341. && (this.Adapter.DeleteCommand != null))) {
  1342. this.Adapter.DeleteCommand.Transaction = this._transaction;
  1343. }
  1344. if (((this.Adapter != null)
  1345. && (this.Adapter.InsertCommand != null))) {
  1346. this.Adapter.InsertCommand.Transaction = this._transaction;
  1347. }
  1348. if (((this.Adapter != null)
  1349. && (this.Adapter.UpdateCommand != null))) {
  1350. this.Adapter.UpdateCommand.Transaction = this._transaction;
  1351. }
  1352. }
  1353. }
  1354. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1355. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1356. protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
  1357. get {
  1358. if ((this._commandCollection == null)) {
  1359. this.InitCommandCollection();
  1360. }
  1361. return this._commandCollection;
  1362. }
  1363. }
  1364. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1365. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1366. public bool ClearBeforeFill {
  1367. get {
  1368. return this._clearBeforeFill;
  1369. }
  1370. set {
  1371. this._clearBeforeFill = value;
  1372. }
  1373. }
  1374. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1375. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1376. private void InitAdapter() {
  1377. this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
  1378. global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
  1379. tableMapping.SourceTable = "Table";
  1380. tableMapping.DataSetTable = "productsale_b_import";
  1381. tableMapping.ColumnMappings.Add("id", "id");
  1382. tableMapping.ColumnMappings.Add("Товар", "Товар");
  1383. tableMapping.ColumnMappings.Add("Количество", "Количество");
  1384. tableMapping.ColumnMappings.Add("Дата_и_время_продажи", "Дата_и_время_продажи");
  1385. this._adapter.TableMappings.Add(tableMapping);
  1386. this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
  1387. this._adapter.DeleteCommand.Connection = this.Connection;
  1388. this._adapter.DeleteCommand.CommandText = "DELETE FROM [dbo].[productsale_b_import] WHERE (([id] = @Original_id) AND ([Товар" +
  1389. "] = @Original_Товар) AND ([Количество] = @Original_Количество) AND ([Дата_и_врем" +
  1390. "я_продажи] = @Original_Дата_и_время_продажи))";
  1391. this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
  1392. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_id", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "id", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1393. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Товар", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Товар", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1394. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Количество", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Количество", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1395. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Дата_и_время_продажи", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_и_время_продажи", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1396. this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
  1397. this._adapter.InsertCommand.Connection = this.Connection;
  1398. this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[productsale_b_import] ([Товар], [Количество], [Дата_и_время_пр" +
  1399. "одажи]) VALUES (@Товар, @Количество, @Дата_и_время_продажи);\r\nSELECT id, Товар, " +
  1400. "Количество, Дата_и_время_продажи FROM productsale_b_import WHERE (id = SCOPE_IDE" +
  1401. "NTITY())";
  1402. this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
  1403. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Товар", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Товар", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1404. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Количество", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Количество", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1405. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Дата_и_время_продажи", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_и_время_продажи", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1406. this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
  1407. this._adapter.UpdateCommand.Connection = this.Connection;
  1408. this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[productsale_b_import] SET [Товар] = @Товар, [Количество] = @Количество, [Дата_и_время_продажи] = @Дата_и_время_продажи WHERE (([id] = @Original_id) AND ([Товар] = @Original_Товар) AND ([Количество] = @Original_Количество) AND ([Дата_и_время_продажи] = @Original_Дата_и_время_продажи));
  1409. SELECT id, Товар, Количество, Дата_и_время_продажи FROM productsale_b_import WHERE (id = @id)";
  1410. this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
  1411. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Товар", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Товар", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1412. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Количество", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Количество", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1413. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Дата_и_время_продажи", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_и_время_продажи", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1414. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_id", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "id", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1415. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Товар", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Товар", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1416. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Количество", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Количество", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1417. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Дата_и_время_продажи", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Дата_и_время_продажи", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  1418. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@id", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "id", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  1419. }
  1420. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1421. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1422. private void InitConnection() {
  1423. this._connection = new global::System.Data.SqlClient.SqlConnection();
  1424. this._connection.ConnectionString = global::Bilet5Dergachev.Properties.Settings.Default.ПМ5_ДергачевConnectionString;
  1425. }
  1426. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1427. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1428. private void InitCommandCollection() {
  1429. this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
  1430. this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
  1431. this._commandCollection[0].Connection = this.Connection;
  1432. this._commandCollection[0].CommandText = "SELECT id, Товар, Количество, Дата_и_время_продажи FROM dbo.productsale_b_import";
  1433. this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
  1434. }
  1435. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1436. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1437. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1438. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
  1439. public virtual int Fill(ПМ5_ДергачевDataSet.productsale_b_importDataTable dataTable) {
  1440. this.Adapter.SelectCommand = this.CommandCollection[0];
  1441. if ((this.ClearBeforeFill == true)) {
  1442. dataTable.Clear();
  1443. }
  1444. int returnValue = this.Adapter.Fill(dataTable);
  1445. return returnValue;
  1446. }
  1447. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1448. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1449. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1450. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
  1451. public virtual ПМ5_ДергачевDataSet.productsale_b_importDataTable GetData() {
  1452. this.Adapter.SelectCommand = this.CommandCollection[0];
  1453. ПМ5_ДергачевDataSet.productsale_b_importDataTable dataTable = new ПМ5_ДергачевDataSet.productsale_b_importDataTable();
  1454. this.Adapter.Fill(dataTable);
  1455. return dataTable;
  1456. }
  1457. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1458. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1459. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1460. public virtual int Update(ПМ5_ДергачевDataSet.productsale_b_importDataTable dataTable) {
  1461. return this.Adapter.Update(dataTable);
  1462. }
  1463. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1464. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1465. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1466. public virtual int Update(ПМ5_ДергачевDataSet dataSet) {
  1467. return this.Adapter.Update(dataSet, "productsale_b_import");
  1468. }
  1469. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1470. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1471. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1472. public virtual int Update(global::System.Data.DataRow dataRow) {
  1473. return this.Adapter.Update(new global::System.Data.DataRow[] {
  1474. dataRow});
  1475. }
  1476. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1477. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1478. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1479. public virtual int Update(global::System.Data.DataRow[] dataRows) {
  1480. return this.Adapter.Update(dataRows);
  1481. }
  1482. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1483. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1484. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1485. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
  1486. public virtual int Delete(int Original_id, string Original_Товар, int Original_Количество, string Original_Дата_и_время_продажи) {
  1487. this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_id));
  1488. if ((Original_Товар == null)) {
  1489. throw new global::System.ArgumentNullException("Original_Товар");
  1490. }
  1491. else {
  1492. this.Adapter.DeleteCommand.Parameters[1].Value = ((string)(Original_Товар));
  1493. }
  1494. this.Adapter.DeleteCommand.Parameters[2].Value = ((int)(Original_Количество));
  1495. if ((Original_Дата_и_время_продажи == null)) {
  1496. throw new global::System.ArgumentNullException("Original_Дата_и_время_продажи");
  1497. }
  1498. else {
  1499. this.Adapter.DeleteCommand.Parameters[3].Value = ((string)(Original_Дата_и_время_продажи));
  1500. }
  1501. global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
  1502. if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
  1503. != global::System.Data.ConnectionState.Open)) {
  1504. this.Adapter.DeleteCommand.Connection.Open();
  1505. }
  1506. try {
  1507. int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
  1508. return returnValue;
  1509. }
  1510. finally {
  1511. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  1512. this.Adapter.DeleteCommand.Connection.Close();
  1513. }
  1514. }
  1515. }
  1516. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1517. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1518. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1519. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
  1520. public virtual int Insert(string Товар, int Количество, string Дата_и_время_продажи) {
  1521. if ((Товар == null)) {
  1522. throw new global::System.ArgumentNullException("Товар");
  1523. }
  1524. else {
  1525. this.Adapter.InsertCommand.Parameters[0].Value = ((string)(Товар));
  1526. }
  1527. this.Adapter.InsertCommand.Parameters[1].Value = ((int)(Количество));
  1528. if ((Дата_и_время_продажи == null)) {
  1529. throw new global::System.ArgumentNullException("Дата_и_время_продажи");
  1530. }
  1531. else {
  1532. this.Adapter.InsertCommand.Parameters[2].Value = ((string)(Дата_и_время_продажи));
  1533. }
  1534. global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
  1535. if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
  1536. != global::System.Data.ConnectionState.Open)) {
  1537. this.Adapter.InsertCommand.Connection.Open();
  1538. }
  1539. try {
  1540. int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
  1541. return returnValue;
  1542. }
  1543. finally {
  1544. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  1545. this.Adapter.InsertCommand.Connection.Close();
  1546. }
  1547. }
  1548. }
  1549. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1550. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1551. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1552. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  1553. public virtual int Update(string Товар, int Количество, string Дата_и_время_продажи, int Original_id, string Original_Товар, int Original_Количество, string Original_Дата_и_время_продажи, int id) {
  1554. if ((Товар == null)) {
  1555. throw new global::System.ArgumentNullException("Товар");
  1556. }
  1557. else {
  1558. this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(Товар));
  1559. }
  1560. this.Adapter.UpdateCommand.Parameters[1].Value = ((int)(Количество));
  1561. if ((Дата_и_время_продажи == null)) {
  1562. throw new global::System.ArgumentNullException("Дата_и_время_продажи");
  1563. }
  1564. else {
  1565. this.Adapter.UpdateCommand.Parameters[2].Value = ((string)(Дата_и_время_продажи));
  1566. }
  1567. this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_id));
  1568. if ((Original_Товар == null)) {
  1569. throw new global::System.ArgumentNullException("Original_Товар");
  1570. }
  1571. else {
  1572. this.Adapter.UpdateCommand.Parameters[4].Value = ((string)(Original_Товар));
  1573. }
  1574. this.Adapter.UpdateCommand.Parameters[5].Value = ((int)(Original_Количество));
  1575. if ((Original_Дата_и_время_продажи == null)) {
  1576. throw new global::System.ArgumentNullException("Original_Дата_и_время_продажи");
  1577. }
  1578. else {
  1579. this.Adapter.UpdateCommand.Parameters[6].Value = ((string)(Original_Дата_и_время_продажи));
  1580. }
  1581. this.Adapter.UpdateCommand.Parameters[7].Value = ((int)(id));
  1582. global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
  1583. if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
  1584. != global::System.Data.ConnectionState.Open)) {
  1585. this.Adapter.UpdateCommand.Connection.Open();
  1586. }
  1587. try {
  1588. int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
  1589. return returnValue;
  1590. }
  1591. finally {
  1592. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  1593. this.Adapter.UpdateCommand.Connection.Close();
  1594. }
  1595. }
  1596. }
  1597. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1598. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1599. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1600. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  1601. public virtual int Update(string Товар, int Количество, string Дата_и_время_продажи, int Original_id, string Original_Товар, int Original_Количество, string Original_Дата_и_время_продажи) {
  1602. return this.Update(Товар, Количество, Дата_и_время_продажи, Original_id, Original_Товар, Original_Количество, Original_Дата_и_время_продажи, Original_id);
  1603. }
  1604. }
  1605. /// <summary>
  1606. ///TableAdapterManager is used to coordinate TableAdapters in the dataset to enable Hierarchical Update scenarios
  1607. ///</summary>
  1608. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  1609. [global::System.ComponentModel.ToolboxItem(true)]
  1610. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerDesigner, Microsoft.VSD" +
  1611. "esigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  1612. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapterManager")]
  1613. public partial class TableAdapterManager : global::System.ComponentModel.Component {
  1614. private UpdateOrderOption _updateOrder;
  1615. private ManufactureTableAdapter _manufactureTableAdapter;
  1616. private productsale_b_importTableAdapter _productsale_b_importTableAdapter;
  1617. private bool _backupDataSetBeforeUpdate;
  1618. private global::System.Data.IDbConnection _connection;
  1619. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1620. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1621. public UpdateOrderOption UpdateOrder {
  1622. get {
  1623. return this._updateOrder;
  1624. }
  1625. set {
  1626. this._updateOrder = value;
  1627. }
  1628. }
  1629. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1630. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1631. [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
  1632. "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
  1633. "a", "System.Drawing.Design.UITypeEditor")]
  1634. public ManufactureTableAdapter ManufactureTableAdapter {
  1635. get {
  1636. return this._manufactureTableAdapter;
  1637. }
  1638. set {
  1639. this._manufactureTableAdapter = value;
  1640. }
  1641. }
  1642. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1643. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1644. [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
  1645. "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
  1646. "a", "System.Drawing.Design.UITypeEditor")]
  1647. public productsale_b_importTableAdapter productsale_b_importTableAdapter {
  1648. get {
  1649. return this._productsale_b_importTableAdapter;
  1650. }
  1651. set {
  1652. this._productsale_b_importTableAdapter = value;
  1653. }
  1654. }
  1655. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1656. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1657. public bool BackupDataSetBeforeUpdate {
  1658. get {
  1659. return this._backupDataSetBeforeUpdate;
  1660. }
  1661. set {
  1662. this._backupDataSetBeforeUpdate = value;
  1663. }
  1664. }
  1665. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1666. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1667. [global::System.ComponentModel.Browsable(false)]
  1668. public global::System.Data.IDbConnection Connection {
  1669. get {
  1670. if ((this._connection != null)) {
  1671. return this._connection;
  1672. }
  1673. if (((this._manufactureTableAdapter != null)
  1674. && (this._manufactureTableAdapter.Connection != null))) {
  1675. return this._manufactureTableAdapter.Connection;
  1676. }
  1677. if (((this._productsale_b_importTableAdapter != null)
  1678. && (this._productsale_b_importTableAdapter.Connection != null))) {
  1679. return this._productsale_b_importTableAdapter.Connection;
  1680. }
  1681. return null;
  1682. }
  1683. set {
  1684. this._connection = value;
  1685. }
  1686. }
  1687. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1688. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1689. [global::System.ComponentModel.Browsable(false)]
  1690. public int TableAdapterInstanceCount {
  1691. get {
  1692. int count = 0;
  1693. if ((this._manufactureTableAdapter != null)) {
  1694. count = (count + 1);
  1695. }
  1696. if ((this._productsale_b_importTableAdapter != null)) {
  1697. count = (count + 1);
  1698. }
  1699. return count;
  1700. }
  1701. }
  1702. /// <summary>
  1703. ///Update rows in top-down order.
  1704. ///</summary>
  1705. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1706. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1707. private int UpdateUpdatedRows(ПМ5_ДергачевDataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  1708. int result = 0;
  1709. if ((this._manufactureTableAdapter != null)) {
  1710. global::System.Data.DataRow[] updatedRows = dataSet.Manufacture.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
  1711. updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
  1712. if (((updatedRows != null)
  1713. && (0 < updatedRows.Length))) {
  1714. result = (result + this._manufactureTableAdapter.Update(updatedRows));
  1715. allChangedRows.AddRange(updatedRows);
  1716. }
  1717. }
  1718. if ((this._productsale_b_importTableAdapter != null)) {
  1719. global::System.Data.DataRow[] updatedRows = dataSet.productsale_b_import.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
  1720. updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
  1721. if (((updatedRows != null)
  1722. && (0 < updatedRows.Length))) {
  1723. result = (result + this._productsale_b_importTableAdapter.Update(updatedRows));
  1724. allChangedRows.AddRange(updatedRows);
  1725. }
  1726. }
  1727. return result;
  1728. }
  1729. /// <summary>
  1730. ///Insert rows in top-down order.
  1731. ///</summary>
  1732. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1733. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1734. private int UpdateInsertedRows(ПМ5_ДергачевDataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  1735. int result = 0;
  1736. if ((this._manufactureTableAdapter != null)) {
  1737. global::System.Data.DataRow[] addedRows = dataSet.Manufacture.Select(null, null, global::System.Data.DataViewRowState.Added);
  1738. if (((addedRows != null)
  1739. && (0 < addedRows.Length))) {
  1740. result = (result + this._manufactureTableAdapter.Update(addedRows));
  1741. allAddedRows.AddRange(addedRows);
  1742. }
  1743. }
  1744. if ((this._productsale_b_importTableAdapter != null)) {
  1745. global::System.Data.DataRow[] addedRows = dataSet.productsale_b_import.Select(null, null, global::System.Data.DataViewRowState.Added);
  1746. if (((addedRows != null)
  1747. && (0 < addedRows.Length))) {
  1748. result = (result + this._productsale_b_importTableAdapter.Update(addedRows));
  1749. allAddedRows.AddRange(addedRows);
  1750. }
  1751. }
  1752. return result;
  1753. }
  1754. /// <summary>
  1755. ///Delete rows in bottom-up order.
  1756. ///</summary>
  1757. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1758. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1759. private int UpdateDeletedRows(ПМ5_ДергачевDataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows) {
  1760. int result = 0;
  1761. if ((this._productsale_b_importTableAdapter != null)) {
  1762. global::System.Data.DataRow[] deletedRows = dataSet.productsale_b_import.Select(null, null, global::System.Data.DataViewRowState.Deleted);
  1763. if (((deletedRows != null)
  1764. && (0 < deletedRows.Length))) {
  1765. result = (result + this._productsale_b_importTableAdapter.Update(deletedRows));
  1766. allChangedRows.AddRange(deletedRows);
  1767. }
  1768. }
  1769. if ((this._manufactureTableAdapter != null)) {
  1770. global::System.Data.DataRow[] deletedRows = dataSet.Manufacture.Select(null, null, global::System.Data.DataViewRowState.Deleted);
  1771. if (((deletedRows != null)
  1772. && (0 < deletedRows.Length))) {
  1773. result = (result + this._manufactureTableAdapter.Update(deletedRows));
  1774. allChangedRows.AddRange(deletedRows);
  1775. }
  1776. }
  1777. return result;
  1778. }
  1779. /// <summary>
  1780. ///Remove inserted rows that become updated rows after calling TableAdapter.Update(inserted rows) first
  1781. ///</summary>
  1782. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1783. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1784. private global::System.Data.DataRow[] GetRealUpdatedRows(global::System.Data.DataRow[] updatedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  1785. if (((updatedRows == null)
  1786. || (updatedRows.Length < 1))) {
  1787. return updatedRows;
  1788. }
  1789. if (((allAddedRows == null)
  1790. || (allAddedRows.Count < 1))) {
  1791. return updatedRows;
  1792. }
  1793. global::System.Collections.Generic.List<global::System.Data.DataRow> realUpdatedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  1794. for (int i = 0; (i < updatedRows.Length); i = (i + 1)) {
  1795. global::System.Data.DataRow row = updatedRows[i];
  1796. if ((allAddedRows.Contains(row) == false)) {
  1797. realUpdatedRows.Add(row);
  1798. }
  1799. }
  1800. return realUpdatedRows.ToArray();
  1801. }
  1802. /// <summary>
  1803. ///Update all changes to the dataset.
  1804. ///</summary>
  1805. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1806. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1807. public virtual int UpdateAll(ПМ5_ДергачевDataSet dataSet) {
  1808. if ((dataSet == null)) {
  1809. throw new global::System.ArgumentNullException("dataSet");
  1810. }
  1811. if ((dataSet.HasChanges() == false)) {
  1812. return 0;
  1813. }
  1814. if (((this._manufactureTableAdapter != null)
  1815. && (this.MatchTableAdapterConnection(this._manufactureTableAdapter.Connection) == false))) {
  1816. throw new global::System.ArgumentException("Все адаптеры таблицы, управляемые диспетчером адаптера таблицы TableAdapterManage" +
  1817. "r, должны использовать одинаковую строку подключения.");
  1818. }
  1819. if (((this._productsale_b_importTableAdapter != null)
  1820. && (this.MatchTableAdapterConnection(this._productsale_b_importTableAdapter.Connection) == false))) {
  1821. throw new global::System.ArgumentException("Все адаптеры таблицы, управляемые диспетчером адаптера таблицы TableAdapterManage" +
  1822. "r, должны использовать одинаковую строку подключения.");
  1823. }
  1824. global::System.Data.IDbConnection workConnection = this.Connection;
  1825. if ((workConnection == null)) {
  1826. throw new global::System.ApplicationException("TableAdapterManager не содержит сведений о подключении. Укажите для каждого адапт" +
  1827. "ера таблицы TableAdapterManager допустимый экземпляр адаптера таблицы.");
  1828. }
  1829. bool workConnOpened = false;
  1830. if (((workConnection.State & global::System.Data.ConnectionState.Broken)
  1831. == global::System.Data.ConnectionState.Broken)) {
  1832. workConnection.Close();
  1833. }
  1834. if ((workConnection.State == global::System.Data.ConnectionState.Closed)) {
  1835. workConnection.Open();
  1836. workConnOpened = true;
  1837. }
  1838. global::System.Data.IDbTransaction workTransaction = workConnection.BeginTransaction();
  1839. if ((workTransaction == null)) {
  1840. throw new global::System.ApplicationException("Не удается начать транзакцию. Текущее соединение данных не поддерживает транзакци" +
  1841. "и или текущее состояние не позволяет начать транзакцию.");
  1842. }
  1843. global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  1844. global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  1845. global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter> adaptersWithAcceptChangesDuringUpdate = new global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter>();
  1846. global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection> revertConnections = new global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection>();
  1847. int result = 0;
  1848. global::System.Data.DataSet backupDataSet = null;
  1849. if (this.BackupDataSetBeforeUpdate) {
  1850. backupDataSet = new global::System.Data.DataSet();
  1851. backupDataSet.Merge(dataSet);
  1852. }
  1853. try {
  1854. // ---- Prepare for update -----------
  1855. //
  1856. if ((this._manufactureTableAdapter != null)) {
  1857. revertConnections.Add(this._manufactureTableAdapter, this._manufactureTableAdapter.Connection);
  1858. this._manufactureTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
  1859. this._manufactureTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
  1860. if (this._manufactureTableAdapter.Adapter.AcceptChangesDuringUpdate) {
  1861. this._manufactureTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
  1862. adaptersWithAcceptChangesDuringUpdate.Add(this._manufactureTableAdapter.Adapter);
  1863. }
  1864. }
  1865. if ((this._productsale_b_importTableAdapter != null)) {
  1866. revertConnections.Add(this._productsale_b_importTableAdapter, this._productsale_b_importTableAdapter.Connection);
  1867. this._productsale_b_importTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
  1868. this._productsale_b_importTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
  1869. if (this._productsale_b_importTableAdapter.Adapter.AcceptChangesDuringUpdate) {
  1870. this._productsale_b_importTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
  1871. adaptersWithAcceptChangesDuringUpdate.Add(this._productsale_b_importTableAdapter.Adapter);
  1872. }
  1873. }
  1874. //
  1875. //---- Perform updates -----------
  1876. //
  1877. if ((this.UpdateOrder == UpdateOrderOption.UpdateInsertDelete)) {
  1878. result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
  1879. result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
  1880. }
  1881. else {
  1882. result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
  1883. result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
  1884. }
  1885. result = (result + this.UpdateDeletedRows(dataSet, allChangedRows));
  1886. //
  1887. //---- Commit updates -----------
  1888. //
  1889. workTransaction.Commit();
  1890. if ((0 < allAddedRows.Count)) {
  1891. global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
  1892. allAddedRows.CopyTo(rows);
  1893. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  1894. global::System.Data.DataRow row = rows[i];
  1895. row.AcceptChanges();
  1896. }
  1897. }
  1898. if ((0 < allChangedRows.Count)) {
  1899. global::System.Data.DataRow[] rows = new System.Data.DataRow[allChangedRows.Count];
  1900. allChangedRows.CopyTo(rows);
  1901. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  1902. global::System.Data.DataRow row = rows[i];
  1903. row.AcceptChanges();
  1904. }
  1905. }
  1906. }
  1907. catch (global::System.Exception ex) {
  1908. workTransaction.Rollback();
  1909. // ---- Restore the dataset -----------
  1910. if (this.BackupDataSetBeforeUpdate) {
  1911. global::System.Diagnostics.Debug.Assert((backupDataSet != null));
  1912. dataSet.Clear();
  1913. dataSet.Merge(backupDataSet);
  1914. }
  1915. else {
  1916. if ((0 < allAddedRows.Count)) {
  1917. global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
  1918. allAddedRows.CopyTo(rows);
  1919. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  1920. global::System.Data.DataRow row = rows[i];
  1921. row.AcceptChanges();
  1922. row.SetAdded();
  1923. }
  1924. }
  1925. }
  1926. throw ex;
  1927. }
  1928. finally {
  1929. if (workConnOpened) {
  1930. workConnection.Close();
  1931. }
  1932. if ((this._manufactureTableAdapter != null)) {
  1933. this._manufactureTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._manufactureTableAdapter]));
  1934. this._manufactureTableAdapter.Transaction = null;
  1935. }
  1936. if ((this._productsale_b_importTableAdapter != null)) {
  1937. this._productsale_b_importTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._productsale_b_importTableAdapter]));
  1938. this._productsale_b_importTableAdapter.Transaction = null;
  1939. }
  1940. if ((0 < adaptersWithAcceptChangesDuringUpdate.Count)) {
  1941. global::System.Data.Common.DataAdapter[] adapters = new System.Data.Common.DataAdapter[adaptersWithAcceptChangesDuringUpdate.Count];
  1942. adaptersWithAcceptChangesDuringUpdate.CopyTo(adapters);
  1943. for (int i = 0; (i < adapters.Length); i = (i + 1)) {
  1944. global::System.Data.Common.DataAdapter adapter = adapters[i];
  1945. adapter.AcceptChangesDuringUpdate = true;
  1946. }
  1947. }
  1948. }
  1949. return result;
  1950. }
  1951. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1952. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1953. protected virtual void SortSelfReferenceRows(global::System.Data.DataRow[] rows, global::System.Data.DataRelation relation, bool childFirst) {
  1954. global::System.Array.Sort<global::System.Data.DataRow>(rows, new SelfReferenceComparer(relation, childFirst));
  1955. }
  1956. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1957. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1958. protected virtual bool MatchTableAdapterConnection(global::System.Data.IDbConnection inputConnection) {
  1959. if ((this._connection != null)) {
  1960. return true;
  1961. }
  1962. if (((this.Connection == null)
  1963. || (inputConnection == null))) {
  1964. return true;
  1965. }
  1966. if (string.Equals(this.Connection.ConnectionString, inputConnection.ConnectionString, global::System.StringComparison.Ordinal)) {
  1967. return true;
  1968. }
  1969. return false;
  1970. }
  1971. /// <summary>
  1972. ///Update Order Option
  1973. ///</summary>
  1974. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1975. public enum UpdateOrderOption {
  1976. InsertUpdateDelete = 0,
  1977. UpdateInsertDelete = 1,
  1978. }
  1979. /// <summary>
  1980. ///Used to sort self-referenced table's rows
  1981. ///</summary>
  1982. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1983. private class SelfReferenceComparer : object, global::System.Collections.Generic.IComparer<global::System.Data.DataRow> {
  1984. private global::System.Data.DataRelation _relation;
  1985. private int _childFirst;
  1986. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1987. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1988. internal SelfReferenceComparer(global::System.Data.DataRelation relation, bool childFirst) {
  1989. this._relation = relation;
  1990. if (childFirst) {
  1991. this._childFirst = -1;
  1992. }
  1993. else {
  1994. this._childFirst = 1;
  1995. }
  1996. }
  1997. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1998. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  1999. private global::System.Data.DataRow GetRoot(global::System.Data.DataRow row, out int distance) {
  2000. global::System.Diagnostics.Debug.Assert((row != null));
  2001. global::System.Data.DataRow root = row;
  2002. distance = 0;
  2003. 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>();
  2004. traversedRows[row] = row;
  2005. global::System.Data.DataRow parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
  2006. for (
  2007. ; ((parent != null)
  2008. && (traversedRows.ContainsKey(parent) == false));
  2009. ) {
  2010. distance = (distance + 1);
  2011. root = parent;
  2012. traversedRows[parent] = parent;
  2013. parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
  2014. }
  2015. if ((distance == 0)) {
  2016. traversedRows.Clear();
  2017. traversedRows[row] = row;
  2018. parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
  2019. for (
  2020. ; ((parent != null)
  2021. && (traversedRows.ContainsKey(parent) == false));
  2022. ) {
  2023. distance = (distance + 1);
  2024. root = parent;
  2025. traversedRows[parent] = parent;
  2026. parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
  2027. }
  2028. }
  2029. return root;
  2030. }
  2031. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2032. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")]
  2033. public int Compare(global::System.Data.DataRow row1, global::System.Data.DataRow row2) {
  2034. if (object.ReferenceEquals(row1, row2)) {
  2035. return 0;
  2036. }
  2037. if ((row1 == null)) {
  2038. return -1;
  2039. }
  2040. if ((row2 == null)) {
  2041. return 1;
  2042. }
  2043. int distance1 = 0;
  2044. global::System.Data.DataRow root1 = this.GetRoot(row1, out distance1);
  2045. int distance2 = 0;
  2046. global::System.Data.DataRow root2 = this.GetRoot(row2, out distance2);
  2047. if (object.ReferenceEquals(root1, root2)) {
  2048. return (this._childFirst * distance1.CompareTo(distance2));
  2049. }
  2050. else {
  2051. global::System.Diagnostics.Debug.Assert(((root1.Table != null)
  2052. && (root2.Table != null)));
  2053. if ((root1.Table.Rows.IndexOf(root1) < root2.Table.Rows.IndexOf(root2))) {
  2054. return -1;
  2055. }
  2056. else {
  2057. return 1;
  2058. }
  2059. }
  2060. }
  2061. }
  2062. }
  2063. }
  2064. #pragma warning restore 1591