_ИСП41_ХолинР_А_DataSet.Designer.cs 155 KB

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