1
0

DBAgentstvoDataSet.Designer.cs 343 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545
  1. //------------------------------------------------------------------------------
  2. // <auto-generated>
  3. // This code was generated by a tool.
  4. // Runtime Version:4.0.30319.42000
  5. //
  6. // Changes to this file may cause incorrect behavior and will be lost if
  7. // the code is regenerated.
  8. // </auto-generated>
  9. //------------------------------------------------------------------------------
  10. #pragma warning disable 1591
  11. namespace СУБД_Агентство {
  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("DBAgentstvoDataSet")]
  20. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.DataSet")]
  21. public partial class DBAgentstvoDataSet : global::System.Data.DataSet {
  22. private PotrebnostDataTable tablePotrebnost;
  23. private predlozhenieDataTable tablepredlozhenie;
  24. private SdelkaDataTable tableSdelka;
  25. private UsersDataTable tableUsers;
  26. private global::System.Data.DataRelation relationFK_Potrebnost_Users;
  27. private global::System.Data.DataRelation relationFK_Potrebnost_Users1;
  28. private global::System.Data.DataRelation relationFK_predlozhenie_Users;
  29. private global::System.Data.DataRelation relationFK_predlozhenie_Users1;
  30. private global::System.Data.DataRelation relationFK_Sdelka_Potrebnost;
  31. private global::System.Data.DataRelation relationFK_Sdelka_predlozhenie;
  32. private global::System.Data.SchemaSerializationMode _schemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
  33. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  34. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  35. public DBAgentstvoDataSet() {
  36. this.BeginInit();
  37. this.InitClass();
  38. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  39. base.Tables.CollectionChanged += schemaChangedHandler;
  40. base.Relations.CollectionChanged += schemaChangedHandler;
  41. this.EndInit();
  42. }
  43. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  44. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  45. protected DBAgentstvoDataSet(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  46. base(info, context, false) {
  47. if ((this.IsBinarySerialized(info, context) == true)) {
  48. this.InitVars(false);
  49. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler1 = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  50. this.Tables.CollectionChanged += schemaChangedHandler1;
  51. this.Relations.CollectionChanged += schemaChangedHandler1;
  52. return;
  53. }
  54. string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
  55. if ((this.DetermineSchemaSerializationMode(info, context) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
  56. global::System.Data.DataSet ds = new global::System.Data.DataSet();
  57. ds.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
  58. if ((ds.Tables["Potrebnost"] != null)) {
  59. base.Tables.Add(new PotrebnostDataTable(ds.Tables["Potrebnost"]));
  60. }
  61. if ((ds.Tables["predlozhenie"] != null)) {
  62. base.Tables.Add(new predlozhenieDataTable(ds.Tables["predlozhenie"]));
  63. }
  64. if ((ds.Tables["Sdelka"] != null)) {
  65. base.Tables.Add(new SdelkaDataTable(ds.Tables["Sdelka"]));
  66. }
  67. if ((ds.Tables["Users"] != null)) {
  68. base.Tables.Add(new UsersDataTable(ds.Tables["Users"]));
  69. }
  70. this.DataSetName = ds.DataSetName;
  71. this.Prefix = ds.Prefix;
  72. this.Namespace = ds.Namespace;
  73. this.Locale = ds.Locale;
  74. this.CaseSensitive = ds.CaseSensitive;
  75. this.EnforceConstraints = ds.EnforceConstraints;
  76. this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
  77. this.InitVars();
  78. }
  79. else {
  80. this.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
  81. }
  82. this.GetSerializationData(info, context);
  83. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  84. base.Tables.CollectionChanged += schemaChangedHandler;
  85. this.Relations.CollectionChanged += schemaChangedHandler;
  86. }
  87. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  88. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  89. [global::System.ComponentModel.Browsable(false)]
  90. [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
  91. public PotrebnostDataTable Potrebnost {
  92. get {
  93. return this.tablePotrebnost;
  94. }
  95. }
  96. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  97. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  98. [global::System.ComponentModel.Browsable(false)]
  99. [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
  100. public predlozhenieDataTable predlozhenie {
  101. get {
  102. return this.tablepredlozhenie;
  103. }
  104. }
  105. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  106. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  107. [global::System.ComponentModel.Browsable(false)]
  108. [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
  109. public SdelkaDataTable Sdelka {
  110. get {
  111. return this.tableSdelka;
  112. }
  113. }
  114. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  115. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  116. [global::System.ComponentModel.Browsable(false)]
  117. [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
  118. public UsersDataTable Users {
  119. get {
  120. return this.tableUsers;
  121. }
  122. }
  123. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  124. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  125. [global::System.ComponentModel.BrowsableAttribute(true)]
  126. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Visible)]
  127. public override global::System.Data.SchemaSerializationMode SchemaSerializationMode {
  128. get {
  129. return this._schemaSerializationMode;
  130. }
  131. set {
  132. this._schemaSerializationMode = value;
  133. }
  134. }
  135. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  136. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  137. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
  138. public new global::System.Data.DataTableCollection Tables {
  139. get {
  140. return base.Tables;
  141. }
  142. }
  143. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  144. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  145. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
  146. public new global::System.Data.DataRelationCollection Relations {
  147. get {
  148. return base.Relations;
  149. }
  150. }
  151. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  152. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  153. protected override void InitializeDerivedDataSet() {
  154. this.BeginInit();
  155. this.InitClass();
  156. this.EndInit();
  157. }
  158. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  159. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  160. public override global::System.Data.DataSet Clone() {
  161. DBAgentstvoDataSet cln = ((DBAgentstvoDataSet)(base.Clone()));
  162. cln.InitVars();
  163. cln.SchemaSerializationMode = this.SchemaSerializationMode;
  164. return cln;
  165. }
  166. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  167. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  168. protected override bool ShouldSerializeTables() {
  169. return false;
  170. }
  171. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  172. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  173. protected override bool ShouldSerializeRelations() {
  174. return false;
  175. }
  176. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  177. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  178. protected override void ReadXmlSerializable(global::System.Xml.XmlReader reader) {
  179. if ((this.DetermineSchemaSerializationMode(reader) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
  180. this.Reset();
  181. global::System.Data.DataSet ds = new global::System.Data.DataSet();
  182. ds.ReadXml(reader);
  183. if ((ds.Tables["Potrebnost"] != null)) {
  184. base.Tables.Add(new PotrebnostDataTable(ds.Tables["Potrebnost"]));
  185. }
  186. if ((ds.Tables["predlozhenie"] != null)) {
  187. base.Tables.Add(new predlozhenieDataTable(ds.Tables["predlozhenie"]));
  188. }
  189. if ((ds.Tables["Sdelka"] != null)) {
  190. base.Tables.Add(new SdelkaDataTable(ds.Tables["Sdelka"]));
  191. }
  192. if ((ds.Tables["Users"] != null)) {
  193. base.Tables.Add(new UsersDataTable(ds.Tables["Users"]));
  194. }
  195. this.DataSetName = ds.DataSetName;
  196. this.Prefix = ds.Prefix;
  197. this.Namespace = ds.Namespace;
  198. this.Locale = ds.Locale;
  199. this.CaseSensitive = ds.CaseSensitive;
  200. this.EnforceConstraints = ds.EnforceConstraints;
  201. this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
  202. this.InitVars();
  203. }
  204. else {
  205. this.ReadXml(reader);
  206. this.InitVars();
  207. }
  208. }
  209. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  210. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  211. protected override global::System.Xml.Schema.XmlSchema GetSchemaSerializable() {
  212. global::System.IO.MemoryStream stream = new global::System.IO.MemoryStream();
  213. this.WriteXmlSchema(new global::System.Xml.XmlTextWriter(stream, null));
  214. stream.Position = 0;
  215. return global::System.Xml.Schema.XmlSchema.Read(new global::System.Xml.XmlTextReader(stream), null);
  216. }
  217. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  218. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  219. internal void InitVars() {
  220. this.InitVars(true);
  221. }
  222. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  223. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  224. internal void InitVars(bool initTable) {
  225. this.tablePotrebnost = ((PotrebnostDataTable)(base.Tables["Potrebnost"]));
  226. if ((initTable == true)) {
  227. if ((this.tablePotrebnost != null)) {
  228. this.tablePotrebnost.InitVars();
  229. }
  230. }
  231. this.tablepredlozhenie = ((predlozhenieDataTable)(base.Tables["predlozhenie"]));
  232. if ((initTable == true)) {
  233. if ((this.tablepredlozhenie != null)) {
  234. this.tablepredlozhenie.InitVars();
  235. }
  236. }
  237. this.tableSdelka = ((SdelkaDataTable)(base.Tables["Sdelka"]));
  238. if ((initTable == true)) {
  239. if ((this.tableSdelka != null)) {
  240. this.tableSdelka.InitVars();
  241. }
  242. }
  243. this.tableUsers = ((UsersDataTable)(base.Tables["Users"]));
  244. if ((initTable == true)) {
  245. if ((this.tableUsers != null)) {
  246. this.tableUsers.InitVars();
  247. }
  248. }
  249. this.relationFK_Potrebnost_Users = this.Relations["FK_Potrebnost_Users"];
  250. this.relationFK_Potrebnost_Users1 = this.Relations["FK_Potrebnost_Users1"];
  251. this.relationFK_predlozhenie_Users = this.Relations["FK_predlozhenie_Users"];
  252. this.relationFK_predlozhenie_Users1 = this.Relations["FK_predlozhenie_Users1"];
  253. this.relationFK_Sdelka_Potrebnost = this.Relations["FK_Sdelka_Potrebnost"];
  254. this.relationFK_Sdelka_predlozhenie = this.Relations["FK_Sdelka_predlozhenie"];
  255. }
  256. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  257. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  258. private void InitClass() {
  259. this.DataSetName = "DBAgentstvoDataSet";
  260. this.Prefix = "";
  261. this.Namespace = "http://tempuri.org/DBAgentstvoDataSet.xsd";
  262. this.EnforceConstraints = true;
  263. this.SchemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
  264. this.tablePotrebnost = new PotrebnostDataTable();
  265. base.Tables.Add(this.tablePotrebnost);
  266. this.tablepredlozhenie = new predlozhenieDataTable();
  267. base.Tables.Add(this.tablepredlozhenie);
  268. this.tableSdelka = new SdelkaDataTable();
  269. base.Tables.Add(this.tableSdelka);
  270. this.tableUsers = new UsersDataTable();
  271. base.Tables.Add(this.tableUsers);
  272. this.relationFK_Potrebnost_Users = new global::System.Data.DataRelation("FK_Potrebnost_Users", new global::System.Data.DataColumn[] {
  273. this.tableUsers.idusersColumn}, new global::System.Data.DataColumn[] {
  274. this.tablePotrebnost.idklientColumn}, false);
  275. this.Relations.Add(this.relationFK_Potrebnost_Users);
  276. this.relationFK_Potrebnost_Users1 = new global::System.Data.DataRelation("FK_Potrebnost_Users1", new global::System.Data.DataColumn[] {
  277. this.tableUsers.idusersColumn}, new global::System.Data.DataColumn[] {
  278. this.tablePotrebnost.idrielterColumn}, false);
  279. this.Relations.Add(this.relationFK_Potrebnost_Users1);
  280. this.relationFK_predlozhenie_Users = new global::System.Data.DataRelation("FK_predlozhenie_Users", new global::System.Data.DataColumn[] {
  281. this.tableUsers.idusersColumn}, new global::System.Data.DataColumn[] {
  282. this.tablepredlozhenie.idklientColumn}, false);
  283. this.Relations.Add(this.relationFK_predlozhenie_Users);
  284. this.relationFK_predlozhenie_Users1 = new global::System.Data.DataRelation("FK_predlozhenie_Users1", new global::System.Data.DataColumn[] {
  285. this.tableUsers.idusersColumn}, new global::System.Data.DataColumn[] {
  286. this.tablepredlozhenie.idrielterColumn}, false);
  287. this.Relations.Add(this.relationFK_predlozhenie_Users1);
  288. this.relationFK_Sdelka_Potrebnost = new global::System.Data.DataRelation("FK_Sdelka_Potrebnost", new global::System.Data.DataColumn[] {
  289. this.tablePotrebnost.idpotrebnostColumn}, new global::System.Data.DataColumn[] {
  290. this.tableSdelka.idpotrebnostColumn}, false);
  291. this.Relations.Add(this.relationFK_Sdelka_Potrebnost);
  292. this.relationFK_Sdelka_predlozhenie = new global::System.Data.DataRelation("FK_Sdelka_predlozhenie", new global::System.Data.DataColumn[] {
  293. this.tablepredlozhenie.idpredlozhenieColumn}, new global::System.Data.DataColumn[] {
  294. this.tableSdelka.idpredlozhenieColumn}, false);
  295. this.Relations.Add(this.relationFK_Sdelka_predlozhenie);
  296. }
  297. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  298. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  299. private bool ShouldSerializePotrebnost() {
  300. return false;
  301. }
  302. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  303. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  304. private bool ShouldSerializepredlozhenie() {
  305. return false;
  306. }
  307. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  308. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  309. private bool ShouldSerializeSdelka() {
  310. return false;
  311. }
  312. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  313. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  314. private bool ShouldSerializeUsers() {
  315. return false;
  316. }
  317. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  318. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  319. private void SchemaChanged(object sender, global::System.ComponentModel.CollectionChangeEventArgs e) {
  320. if ((e.Action == global::System.ComponentModel.CollectionChangeAction.Remove)) {
  321. this.InitVars();
  322. }
  323. }
  324. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  325. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  326. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedDataSetSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  327. DBAgentstvoDataSet ds = new DBAgentstvoDataSet();
  328. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  329. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  330. global::System.Xml.Schema.XmlSchemaAny any = new global::System.Xml.Schema.XmlSchemaAny();
  331. any.Namespace = ds.Namespace;
  332. sequence.Items.Add(any);
  333. type.Particle = sequence;
  334. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  335. if (xs.Contains(dsSchema.TargetNamespace)) {
  336. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  337. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  338. try {
  339. global::System.Xml.Schema.XmlSchema schema = null;
  340. dsSchema.Write(s1);
  341. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  342. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  343. s2.SetLength(0);
  344. schema.Write(s2);
  345. if ((s1.Length == s2.Length)) {
  346. s1.Position = 0;
  347. s2.Position = 0;
  348. for (; ((s1.Position != s1.Length)
  349. && (s1.ReadByte() == s2.ReadByte())); ) {
  350. ;
  351. }
  352. if ((s1.Position == s1.Length)) {
  353. return type;
  354. }
  355. }
  356. }
  357. }
  358. finally {
  359. if ((s1 != null)) {
  360. s1.Close();
  361. }
  362. if ((s2 != null)) {
  363. s2.Close();
  364. }
  365. }
  366. }
  367. xs.Add(dsSchema);
  368. return type;
  369. }
  370. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  371. public delegate void PotrebnostRowChangeEventHandler(object sender, PotrebnostRowChangeEvent e);
  372. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  373. public delegate void predlozhenieRowChangeEventHandler(object sender, predlozhenieRowChangeEvent e);
  374. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  375. public delegate void SdelkaRowChangeEventHandler(object sender, SdelkaRowChangeEvent e);
  376. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  377. public delegate void UsersRowChangeEventHandler(object sender, UsersRowChangeEvent e);
  378. /// <summary>
  379. ///Represents the strongly named DataTable class.
  380. ///</summary>
  381. [global::System.Serializable()]
  382. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
  383. public partial class PotrebnostDataTable : global::System.Data.TypedTableBase<PotrebnostRow> {
  384. private global::System.Data.DataColumn columnidpotrebnost;
  385. private global::System.Data.DataColumn columnidklient;
  386. private global::System.Data.DataColumn columnidrielter;
  387. private global::System.Data.DataColumn columnminplosh;
  388. private global::System.Data.DataColumn columnmaxplosh;
  389. private global::System.Data.DataColumn columnminetazh;
  390. private global::System.Data.DataColumn columnmaxetazh;
  391. private global::System.Data.DataColumn columnminkomnat;
  392. private global::System.Data.DataColumn columnmaxkomnat;
  393. private global::System.Data.DataColumn columnmincena;
  394. private global::System.Data.DataColumn columnmaxcena;
  395. private global::System.Data.DataColumn columnzaversheno;
  396. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  397. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  398. public PotrebnostDataTable() {
  399. this.TableName = "Potrebnost";
  400. this.BeginInit();
  401. this.InitClass();
  402. this.EndInit();
  403. }
  404. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  405. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  406. internal PotrebnostDataTable(global::System.Data.DataTable table) {
  407. this.TableName = table.TableName;
  408. if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
  409. this.CaseSensitive = table.CaseSensitive;
  410. }
  411. if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
  412. this.Locale = table.Locale;
  413. }
  414. if ((table.Namespace != table.DataSet.Namespace)) {
  415. this.Namespace = table.Namespace;
  416. }
  417. this.Prefix = table.Prefix;
  418. this.MinimumCapacity = table.MinimumCapacity;
  419. }
  420. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  421. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  422. protected PotrebnostDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  423. base(info, context) {
  424. this.InitVars();
  425. }
  426. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  427. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  428. public global::System.Data.DataColumn idpotrebnostColumn {
  429. get {
  430. return this.columnidpotrebnost;
  431. }
  432. }
  433. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  434. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  435. public global::System.Data.DataColumn idklientColumn {
  436. get {
  437. return this.columnidklient;
  438. }
  439. }
  440. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  441. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  442. public global::System.Data.DataColumn idrielterColumn {
  443. get {
  444. return this.columnidrielter;
  445. }
  446. }
  447. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  448. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  449. public global::System.Data.DataColumn minploshColumn {
  450. get {
  451. return this.columnminplosh;
  452. }
  453. }
  454. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  455. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  456. public global::System.Data.DataColumn maxploshColumn {
  457. get {
  458. return this.columnmaxplosh;
  459. }
  460. }
  461. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  462. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  463. public global::System.Data.DataColumn minetazhColumn {
  464. get {
  465. return this.columnminetazh;
  466. }
  467. }
  468. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  469. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  470. public global::System.Data.DataColumn maxetazhColumn {
  471. get {
  472. return this.columnmaxetazh;
  473. }
  474. }
  475. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  476. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  477. public global::System.Data.DataColumn minkomnatColumn {
  478. get {
  479. return this.columnminkomnat;
  480. }
  481. }
  482. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  483. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  484. public global::System.Data.DataColumn maxkomnatColumn {
  485. get {
  486. return this.columnmaxkomnat;
  487. }
  488. }
  489. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  490. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  491. public global::System.Data.DataColumn mincenaColumn {
  492. get {
  493. return this.columnmincena;
  494. }
  495. }
  496. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  497. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  498. public global::System.Data.DataColumn maxcenaColumn {
  499. get {
  500. return this.columnmaxcena;
  501. }
  502. }
  503. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  504. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  505. public global::System.Data.DataColumn zavershenoColumn {
  506. get {
  507. return this.columnzaversheno;
  508. }
  509. }
  510. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  511. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  512. [global::System.ComponentModel.Browsable(false)]
  513. public int Count {
  514. get {
  515. return this.Rows.Count;
  516. }
  517. }
  518. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  519. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  520. public PotrebnostRow this[int index] {
  521. get {
  522. return ((PotrebnostRow)(this.Rows[index]));
  523. }
  524. }
  525. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  526. public event PotrebnostRowChangeEventHandler PotrebnostRowChanging;
  527. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  528. public event PotrebnostRowChangeEventHandler PotrebnostRowChanged;
  529. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  530. public event PotrebnostRowChangeEventHandler PotrebnostRowDeleting;
  531. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  532. public event PotrebnostRowChangeEventHandler PotrebnostRowDeleted;
  533. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  534. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  535. public void AddPotrebnostRow(PotrebnostRow row) {
  536. this.Rows.Add(row);
  537. }
  538. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  539. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  540. public PotrebnostRow AddPotrebnostRow(UsersRow parentUsersRowByFK_Potrebnost_Users, UsersRow parentUsersRowByFK_Potrebnost_Users1, int minplosh, int maxplosh, int minetazh, int maxetazh, int minkomnat, int maxkomnat, decimal mincena, decimal maxcena, bool zaversheno) {
  541. PotrebnostRow rowPotrebnostRow = ((PotrebnostRow)(this.NewRow()));
  542. object[] columnValuesArray = new object[] {
  543. null,
  544. null,
  545. null,
  546. minplosh,
  547. maxplosh,
  548. minetazh,
  549. maxetazh,
  550. minkomnat,
  551. maxkomnat,
  552. mincena,
  553. maxcena,
  554. zaversheno};
  555. if ((parentUsersRowByFK_Potrebnost_Users != null)) {
  556. columnValuesArray[1] = parentUsersRowByFK_Potrebnost_Users[0];
  557. }
  558. if ((parentUsersRowByFK_Potrebnost_Users1 != null)) {
  559. columnValuesArray[2] = parentUsersRowByFK_Potrebnost_Users1[0];
  560. }
  561. rowPotrebnostRow.ItemArray = columnValuesArray;
  562. this.Rows.Add(rowPotrebnostRow);
  563. return rowPotrebnostRow;
  564. }
  565. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  566. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  567. public PotrebnostRow FindByidpotrebnost(int idpotrebnost) {
  568. return ((PotrebnostRow)(this.Rows.Find(new object[] {
  569. idpotrebnost})));
  570. }
  571. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  572. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  573. public override global::System.Data.DataTable Clone() {
  574. PotrebnostDataTable cln = ((PotrebnostDataTable)(base.Clone()));
  575. cln.InitVars();
  576. return cln;
  577. }
  578. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  579. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  580. protected override global::System.Data.DataTable CreateInstance() {
  581. return new PotrebnostDataTable();
  582. }
  583. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  584. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  585. internal void InitVars() {
  586. this.columnidpotrebnost = base.Columns["idpotrebnost"];
  587. this.columnidklient = base.Columns["idklient"];
  588. this.columnidrielter = base.Columns["idrielter"];
  589. this.columnminplosh = base.Columns["minplosh"];
  590. this.columnmaxplosh = base.Columns["maxplosh"];
  591. this.columnminetazh = base.Columns["minetazh"];
  592. this.columnmaxetazh = base.Columns["maxetazh"];
  593. this.columnminkomnat = base.Columns["minkomnat"];
  594. this.columnmaxkomnat = base.Columns["maxkomnat"];
  595. this.columnmincena = base.Columns["mincena"];
  596. this.columnmaxcena = base.Columns["maxcena"];
  597. this.columnzaversheno = base.Columns["zaversheno"];
  598. }
  599. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  600. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  601. private void InitClass() {
  602. this.columnidpotrebnost = new global::System.Data.DataColumn("idpotrebnost", typeof(int), null, global::System.Data.MappingType.Element);
  603. base.Columns.Add(this.columnidpotrebnost);
  604. this.columnidklient = new global::System.Data.DataColumn("idklient", typeof(int), null, global::System.Data.MappingType.Element);
  605. base.Columns.Add(this.columnidklient);
  606. this.columnidrielter = new global::System.Data.DataColumn("idrielter", typeof(int), null, global::System.Data.MappingType.Element);
  607. base.Columns.Add(this.columnidrielter);
  608. this.columnminplosh = new global::System.Data.DataColumn("minplosh", typeof(int), null, global::System.Data.MappingType.Element);
  609. base.Columns.Add(this.columnminplosh);
  610. this.columnmaxplosh = new global::System.Data.DataColumn("maxplosh", typeof(int), null, global::System.Data.MappingType.Element);
  611. base.Columns.Add(this.columnmaxplosh);
  612. this.columnminetazh = new global::System.Data.DataColumn("minetazh", typeof(int), null, global::System.Data.MappingType.Element);
  613. base.Columns.Add(this.columnminetazh);
  614. this.columnmaxetazh = new global::System.Data.DataColumn("maxetazh", typeof(int), null, global::System.Data.MappingType.Element);
  615. base.Columns.Add(this.columnmaxetazh);
  616. this.columnminkomnat = new global::System.Data.DataColumn("minkomnat", typeof(int), null, global::System.Data.MappingType.Element);
  617. base.Columns.Add(this.columnminkomnat);
  618. this.columnmaxkomnat = new global::System.Data.DataColumn("maxkomnat", typeof(int), null, global::System.Data.MappingType.Element);
  619. base.Columns.Add(this.columnmaxkomnat);
  620. this.columnmincena = new global::System.Data.DataColumn("mincena", typeof(decimal), null, global::System.Data.MappingType.Element);
  621. base.Columns.Add(this.columnmincena);
  622. this.columnmaxcena = new global::System.Data.DataColumn("maxcena", typeof(decimal), null, global::System.Data.MappingType.Element);
  623. base.Columns.Add(this.columnmaxcena);
  624. this.columnzaversheno = new global::System.Data.DataColumn("zaversheno", typeof(bool), null, global::System.Data.MappingType.Element);
  625. base.Columns.Add(this.columnzaversheno);
  626. this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
  627. this.columnidpotrebnost}, true));
  628. this.columnidpotrebnost.AutoIncrement = true;
  629. this.columnidpotrebnost.AutoIncrementSeed = 1;
  630. this.columnidpotrebnost.AllowDBNull = false;
  631. this.columnidpotrebnost.ReadOnly = true;
  632. this.columnidpotrebnost.Unique = true;
  633. this.columnidklient.AllowDBNull = false;
  634. this.columnidrielter.AllowDBNull = false;
  635. }
  636. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  637. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  638. public PotrebnostRow NewPotrebnostRow() {
  639. return ((PotrebnostRow)(this.NewRow()));
  640. }
  641. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  642. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  643. protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
  644. return new PotrebnostRow(builder);
  645. }
  646. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  647. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  648. protected override global::System.Type GetRowType() {
  649. return typeof(PotrebnostRow);
  650. }
  651. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  652. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  653. protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
  654. base.OnRowChanged(e);
  655. if ((this.PotrebnostRowChanged != null)) {
  656. this.PotrebnostRowChanged(this, new PotrebnostRowChangeEvent(((PotrebnostRow)(e.Row)), e.Action));
  657. }
  658. }
  659. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  660. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  661. protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
  662. base.OnRowChanging(e);
  663. if ((this.PotrebnostRowChanging != null)) {
  664. this.PotrebnostRowChanging(this, new PotrebnostRowChangeEvent(((PotrebnostRow)(e.Row)), e.Action));
  665. }
  666. }
  667. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  668. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  669. protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
  670. base.OnRowDeleted(e);
  671. if ((this.PotrebnostRowDeleted != null)) {
  672. this.PotrebnostRowDeleted(this, new PotrebnostRowChangeEvent(((PotrebnostRow)(e.Row)), e.Action));
  673. }
  674. }
  675. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  676. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  677. protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
  678. base.OnRowDeleting(e);
  679. if ((this.PotrebnostRowDeleting != null)) {
  680. this.PotrebnostRowDeleting(this, new PotrebnostRowChangeEvent(((PotrebnostRow)(e.Row)), e.Action));
  681. }
  682. }
  683. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  684. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  685. public void RemovePotrebnostRow(PotrebnostRow row) {
  686. this.Rows.Remove(row);
  687. }
  688. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  689. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  690. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  691. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  692. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  693. DBAgentstvoDataSet ds = new DBAgentstvoDataSet();
  694. global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
  695. any1.Namespace = "http://www.w3.org/2001/XMLSchema";
  696. any1.MinOccurs = new decimal(0);
  697. any1.MaxOccurs = decimal.MaxValue;
  698. any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  699. sequence.Items.Add(any1);
  700. global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
  701. any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
  702. any2.MinOccurs = new decimal(1);
  703. any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  704. sequence.Items.Add(any2);
  705. global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
  706. attribute1.Name = "namespace";
  707. attribute1.FixedValue = ds.Namespace;
  708. type.Attributes.Add(attribute1);
  709. global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
  710. attribute2.Name = "tableTypeName";
  711. attribute2.FixedValue = "PotrebnostDataTable";
  712. type.Attributes.Add(attribute2);
  713. type.Particle = sequence;
  714. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  715. if (xs.Contains(dsSchema.TargetNamespace)) {
  716. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  717. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  718. try {
  719. global::System.Xml.Schema.XmlSchema schema = null;
  720. dsSchema.Write(s1);
  721. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  722. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  723. s2.SetLength(0);
  724. schema.Write(s2);
  725. if ((s1.Length == s2.Length)) {
  726. s1.Position = 0;
  727. s2.Position = 0;
  728. for (; ((s1.Position != s1.Length)
  729. && (s1.ReadByte() == s2.ReadByte())); ) {
  730. ;
  731. }
  732. if ((s1.Position == s1.Length)) {
  733. return type;
  734. }
  735. }
  736. }
  737. }
  738. finally {
  739. if ((s1 != null)) {
  740. s1.Close();
  741. }
  742. if ((s2 != null)) {
  743. s2.Close();
  744. }
  745. }
  746. }
  747. xs.Add(dsSchema);
  748. return type;
  749. }
  750. }
  751. /// <summary>
  752. ///Represents the strongly named DataTable class.
  753. ///</summary>
  754. [global::System.Serializable()]
  755. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
  756. public partial class predlozhenieDataTable : global::System.Data.TypedTableBase<predlozhenieRow> {
  757. private global::System.Data.DataColumn columnidpredlozhenie;
  758. private global::System.Data.DataColumn columnidklient;
  759. private global::System.Data.DataColumn columnidrielter;
  760. private global::System.Data.DataColumn columnadres;
  761. private global::System.Data.DataColumn columnplosh;
  762. private global::System.Data.DataColumn columnetazh;
  763. private global::System.Data.DataColumn columnkomnat;
  764. private global::System.Data.DataColumn columncena;
  765. private global::System.Data.DataColumn columnzaversheno;
  766. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  767. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  768. public predlozhenieDataTable() {
  769. this.TableName = "predlozhenie";
  770. this.BeginInit();
  771. this.InitClass();
  772. this.EndInit();
  773. }
  774. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  775. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  776. internal predlozhenieDataTable(global::System.Data.DataTable table) {
  777. this.TableName = table.TableName;
  778. if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
  779. this.CaseSensitive = table.CaseSensitive;
  780. }
  781. if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
  782. this.Locale = table.Locale;
  783. }
  784. if ((table.Namespace != table.DataSet.Namespace)) {
  785. this.Namespace = table.Namespace;
  786. }
  787. this.Prefix = table.Prefix;
  788. this.MinimumCapacity = table.MinimumCapacity;
  789. }
  790. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  791. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  792. protected predlozhenieDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  793. base(info, context) {
  794. this.InitVars();
  795. }
  796. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  797. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  798. public global::System.Data.DataColumn idpredlozhenieColumn {
  799. get {
  800. return this.columnidpredlozhenie;
  801. }
  802. }
  803. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  804. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  805. public global::System.Data.DataColumn idklientColumn {
  806. get {
  807. return this.columnidklient;
  808. }
  809. }
  810. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  811. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  812. public global::System.Data.DataColumn idrielterColumn {
  813. get {
  814. return this.columnidrielter;
  815. }
  816. }
  817. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  818. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  819. public global::System.Data.DataColumn adresColumn {
  820. get {
  821. return this.columnadres;
  822. }
  823. }
  824. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  825. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  826. public global::System.Data.DataColumn ploshColumn {
  827. get {
  828. return this.columnplosh;
  829. }
  830. }
  831. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  832. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  833. public global::System.Data.DataColumn etazhColumn {
  834. get {
  835. return this.columnetazh;
  836. }
  837. }
  838. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  839. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  840. public global::System.Data.DataColumn komnatColumn {
  841. get {
  842. return this.columnkomnat;
  843. }
  844. }
  845. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  846. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  847. public global::System.Data.DataColumn cenaColumn {
  848. get {
  849. return this.columncena;
  850. }
  851. }
  852. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  853. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  854. public global::System.Data.DataColumn zavershenoColumn {
  855. get {
  856. return this.columnzaversheno;
  857. }
  858. }
  859. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  860. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  861. [global::System.ComponentModel.Browsable(false)]
  862. public int Count {
  863. get {
  864. return this.Rows.Count;
  865. }
  866. }
  867. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  868. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  869. public predlozhenieRow this[int index] {
  870. get {
  871. return ((predlozhenieRow)(this.Rows[index]));
  872. }
  873. }
  874. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  875. public event predlozhenieRowChangeEventHandler predlozhenieRowChanging;
  876. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  877. public event predlozhenieRowChangeEventHandler predlozhenieRowChanged;
  878. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  879. public event predlozhenieRowChangeEventHandler predlozhenieRowDeleting;
  880. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  881. public event predlozhenieRowChangeEventHandler predlozhenieRowDeleted;
  882. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  883. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  884. public void AddpredlozhenieRow(predlozhenieRow row) {
  885. this.Rows.Add(row);
  886. }
  887. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  888. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  889. public predlozhenieRow AddpredlozhenieRow(UsersRow parentUsersRowByFK_predlozhenie_Users, UsersRow parentUsersRowByFK_predlozhenie_Users1, string adres, int plosh, int etazh, int komnat, decimal cena, bool zaversheno) {
  890. predlozhenieRow rowpredlozhenieRow = ((predlozhenieRow)(this.NewRow()));
  891. object[] columnValuesArray = new object[] {
  892. null,
  893. null,
  894. null,
  895. adres,
  896. plosh,
  897. etazh,
  898. komnat,
  899. cena,
  900. zaversheno};
  901. if ((parentUsersRowByFK_predlozhenie_Users != null)) {
  902. columnValuesArray[1] = parentUsersRowByFK_predlozhenie_Users[0];
  903. }
  904. if ((parentUsersRowByFK_predlozhenie_Users1 != null)) {
  905. columnValuesArray[2] = parentUsersRowByFK_predlozhenie_Users1[0];
  906. }
  907. rowpredlozhenieRow.ItemArray = columnValuesArray;
  908. this.Rows.Add(rowpredlozhenieRow);
  909. return rowpredlozhenieRow;
  910. }
  911. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  912. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  913. public predlozhenieRow FindByidpredlozhenie(int idpredlozhenie) {
  914. return ((predlozhenieRow)(this.Rows.Find(new object[] {
  915. idpredlozhenie})));
  916. }
  917. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  918. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  919. public override global::System.Data.DataTable Clone() {
  920. predlozhenieDataTable cln = ((predlozhenieDataTable)(base.Clone()));
  921. cln.InitVars();
  922. return cln;
  923. }
  924. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  925. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  926. protected override global::System.Data.DataTable CreateInstance() {
  927. return new predlozhenieDataTable();
  928. }
  929. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  930. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  931. internal void InitVars() {
  932. this.columnidpredlozhenie = base.Columns["idpredlozhenie"];
  933. this.columnidklient = base.Columns["idklient"];
  934. this.columnidrielter = base.Columns["idrielter"];
  935. this.columnadres = base.Columns["adres"];
  936. this.columnplosh = base.Columns["plosh"];
  937. this.columnetazh = base.Columns["etazh"];
  938. this.columnkomnat = base.Columns["komnat"];
  939. this.columncena = base.Columns["cena"];
  940. this.columnzaversheno = base.Columns["zaversheno"];
  941. }
  942. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  943. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  944. private void InitClass() {
  945. this.columnidpredlozhenie = new global::System.Data.DataColumn("idpredlozhenie", typeof(int), null, global::System.Data.MappingType.Element);
  946. base.Columns.Add(this.columnidpredlozhenie);
  947. this.columnidklient = new global::System.Data.DataColumn("idklient", typeof(int), null, global::System.Data.MappingType.Element);
  948. base.Columns.Add(this.columnidklient);
  949. this.columnidrielter = new global::System.Data.DataColumn("idrielter", typeof(int), null, global::System.Data.MappingType.Element);
  950. base.Columns.Add(this.columnidrielter);
  951. this.columnadres = new global::System.Data.DataColumn("adres", typeof(string), null, global::System.Data.MappingType.Element);
  952. base.Columns.Add(this.columnadres);
  953. this.columnplosh = new global::System.Data.DataColumn("plosh", typeof(int), null, global::System.Data.MappingType.Element);
  954. base.Columns.Add(this.columnplosh);
  955. this.columnetazh = new global::System.Data.DataColumn("etazh", typeof(int), null, global::System.Data.MappingType.Element);
  956. base.Columns.Add(this.columnetazh);
  957. this.columnkomnat = new global::System.Data.DataColumn("komnat", typeof(int), null, global::System.Data.MappingType.Element);
  958. base.Columns.Add(this.columnkomnat);
  959. this.columncena = new global::System.Data.DataColumn("cena", typeof(decimal), null, global::System.Data.MappingType.Element);
  960. base.Columns.Add(this.columncena);
  961. this.columnzaversheno = new global::System.Data.DataColumn("zaversheno", typeof(bool), null, global::System.Data.MappingType.Element);
  962. base.Columns.Add(this.columnzaversheno);
  963. this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
  964. this.columnidpredlozhenie}, true));
  965. this.columnidpredlozhenie.AutoIncrement = true;
  966. this.columnidpredlozhenie.AutoIncrementSeed = 1;
  967. this.columnidpredlozhenie.AllowDBNull = false;
  968. this.columnidpredlozhenie.ReadOnly = true;
  969. this.columnidpredlozhenie.Unique = true;
  970. this.columnidklient.AllowDBNull = false;
  971. this.columnidrielter.AllowDBNull = false;
  972. this.columnadres.MaxLength = 50;
  973. }
  974. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  975. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  976. public predlozhenieRow NewpredlozhenieRow() {
  977. return ((predlozhenieRow)(this.NewRow()));
  978. }
  979. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  980. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  981. protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
  982. return new predlozhenieRow(builder);
  983. }
  984. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  985. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  986. protected override global::System.Type GetRowType() {
  987. return typeof(predlozhenieRow);
  988. }
  989. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  990. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  991. protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
  992. base.OnRowChanged(e);
  993. if ((this.predlozhenieRowChanged != null)) {
  994. this.predlozhenieRowChanged(this, new predlozhenieRowChangeEvent(((predlozhenieRow)(e.Row)), e.Action));
  995. }
  996. }
  997. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  998. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  999. protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
  1000. base.OnRowChanging(e);
  1001. if ((this.predlozhenieRowChanging != null)) {
  1002. this.predlozhenieRowChanging(this, new predlozhenieRowChangeEvent(((predlozhenieRow)(e.Row)), e.Action));
  1003. }
  1004. }
  1005. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1006. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1007. protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
  1008. base.OnRowDeleted(e);
  1009. if ((this.predlozhenieRowDeleted != null)) {
  1010. this.predlozhenieRowDeleted(this, new predlozhenieRowChangeEvent(((predlozhenieRow)(e.Row)), e.Action));
  1011. }
  1012. }
  1013. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1014. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1015. protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
  1016. base.OnRowDeleting(e);
  1017. if ((this.predlozhenieRowDeleting != null)) {
  1018. this.predlozhenieRowDeleting(this, new predlozhenieRowChangeEvent(((predlozhenieRow)(e.Row)), e.Action));
  1019. }
  1020. }
  1021. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1022. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1023. public void RemovepredlozhenieRow(predlozhenieRow row) {
  1024. this.Rows.Remove(row);
  1025. }
  1026. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1027. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1028. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  1029. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  1030. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  1031. DBAgentstvoDataSet ds = new DBAgentstvoDataSet();
  1032. global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
  1033. any1.Namespace = "http://www.w3.org/2001/XMLSchema";
  1034. any1.MinOccurs = new decimal(0);
  1035. any1.MaxOccurs = decimal.MaxValue;
  1036. any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  1037. sequence.Items.Add(any1);
  1038. global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
  1039. any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
  1040. any2.MinOccurs = new decimal(1);
  1041. any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  1042. sequence.Items.Add(any2);
  1043. global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
  1044. attribute1.Name = "namespace";
  1045. attribute1.FixedValue = ds.Namespace;
  1046. type.Attributes.Add(attribute1);
  1047. global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
  1048. attribute2.Name = "tableTypeName";
  1049. attribute2.FixedValue = "predlozhenieDataTable";
  1050. type.Attributes.Add(attribute2);
  1051. type.Particle = sequence;
  1052. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  1053. if (xs.Contains(dsSchema.TargetNamespace)) {
  1054. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  1055. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  1056. try {
  1057. global::System.Xml.Schema.XmlSchema schema = null;
  1058. dsSchema.Write(s1);
  1059. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  1060. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  1061. s2.SetLength(0);
  1062. schema.Write(s2);
  1063. if ((s1.Length == s2.Length)) {
  1064. s1.Position = 0;
  1065. s2.Position = 0;
  1066. for (; ((s1.Position != s1.Length)
  1067. && (s1.ReadByte() == s2.ReadByte())); ) {
  1068. ;
  1069. }
  1070. if ((s1.Position == s1.Length)) {
  1071. return type;
  1072. }
  1073. }
  1074. }
  1075. }
  1076. finally {
  1077. if ((s1 != null)) {
  1078. s1.Close();
  1079. }
  1080. if ((s2 != null)) {
  1081. s2.Close();
  1082. }
  1083. }
  1084. }
  1085. xs.Add(dsSchema);
  1086. return type;
  1087. }
  1088. }
  1089. /// <summary>
  1090. ///Represents the strongly named DataTable class.
  1091. ///</summary>
  1092. [global::System.Serializable()]
  1093. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
  1094. public partial class SdelkaDataTable : global::System.Data.TypedTableBase<SdelkaRow> {
  1095. private global::System.Data.DataColumn columnidsdelka;
  1096. private global::System.Data.DataColumn columnidpotrebnost;
  1097. private global::System.Data.DataColumn columnidpredlozhenie;
  1098. private global::System.Data.DataColumn columndatesdelka;
  1099. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1100. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1101. public SdelkaDataTable() {
  1102. this.TableName = "Sdelka";
  1103. this.BeginInit();
  1104. this.InitClass();
  1105. this.EndInit();
  1106. }
  1107. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1108. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1109. internal SdelkaDataTable(global::System.Data.DataTable table) {
  1110. this.TableName = table.TableName;
  1111. if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
  1112. this.CaseSensitive = table.CaseSensitive;
  1113. }
  1114. if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
  1115. this.Locale = table.Locale;
  1116. }
  1117. if ((table.Namespace != table.DataSet.Namespace)) {
  1118. this.Namespace = table.Namespace;
  1119. }
  1120. this.Prefix = table.Prefix;
  1121. this.MinimumCapacity = table.MinimumCapacity;
  1122. }
  1123. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1124. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1125. protected SdelkaDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  1126. base(info, context) {
  1127. this.InitVars();
  1128. }
  1129. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1130. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1131. public global::System.Data.DataColumn idsdelkaColumn {
  1132. get {
  1133. return this.columnidsdelka;
  1134. }
  1135. }
  1136. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1137. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1138. public global::System.Data.DataColumn idpotrebnostColumn {
  1139. get {
  1140. return this.columnidpotrebnost;
  1141. }
  1142. }
  1143. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1144. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1145. public global::System.Data.DataColumn idpredlozhenieColumn {
  1146. get {
  1147. return this.columnidpredlozhenie;
  1148. }
  1149. }
  1150. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1151. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1152. public global::System.Data.DataColumn datesdelkaColumn {
  1153. get {
  1154. return this.columndatesdelka;
  1155. }
  1156. }
  1157. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1158. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1159. [global::System.ComponentModel.Browsable(false)]
  1160. public int Count {
  1161. get {
  1162. return this.Rows.Count;
  1163. }
  1164. }
  1165. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1166. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1167. public SdelkaRow this[int index] {
  1168. get {
  1169. return ((SdelkaRow)(this.Rows[index]));
  1170. }
  1171. }
  1172. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1173. public event SdelkaRowChangeEventHandler SdelkaRowChanging;
  1174. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1175. public event SdelkaRowChangeEventHandler SdelkaRowChanged;
  1176. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1177. public event SdelkaRowChangeEventHandler SdelkaRowDeleting;
  1178. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1179. public event SdelkaRowChangeEventHandler SdelkaRowDeleted;
  1180. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1181. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1182. public void AddSdelkaRow(SdelkaRow row) {
  1183. this.Rows.Add(row);
  1184. }
  1185. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1186. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1187. public SdelkaRow AddSdelkaRow(PotrebnostRow parentPotrebnostRowByFK_Sdelka_Potrebnost, predlozhenieRow parentpredlozhenieRowByFK_Sdelka_predlozhenie, System.DateTime datesdelka) {
  1188. SdelkaRow rowSdelkaRow = ((SdelkaRow)(this.NewRow()));
  1189. object[] columnValuesArray = new object[] {
  1190. null,
  1191. null,
  1192. null,
  1193. datesdelka};
  1194. if ((parentPotrebnostRowByFK_Sdelka_Potrebnost != null)) {
  1195. columnValuesArray[1] = parentPotrebnostRowByFK_Sdelka_Potrebnost[0];
  1196. }
  1197. if ((parentpredlozhenieRowByFK_Sdelka_predlozhenie != null)) {
  1198. columnValuesArray[2] = parentpredlozhenieRowByFK_Sdelka_predlozhenie[0];
  1199. }
  1200. rowSdelkaRow.ItemArray = columnValuesArray;
  1201. this.Rows.Add(rowSdelkaRow);
  1202. return rowSdelkaRow;
  1203. }
  1204. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1205. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1206. public SdelkaRow FindByidsdelka(int idsdelka) {
  1207. return ((SdelkaRow)(this.Rows.Find(new object[] {
  1208. idsdelka})));
  1209. }
  1210. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1211. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1212. public override global::System.Data.DataTable Clone() {
  1213. SdelkaDataTable cln = ((SdelkaDataTable)(base.Clone()));
  1214. cln.InitVars();
  1215. return cln;
  1216. }
  1217. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1218. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1219. protected override global::System.Data.DataTable CreateInstance() {
  1220. return new SdelkaDataTable();
  1221. }
  1222. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1223. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1224. internal void InitVars() {
  1225. this.columnidsdelka = base.Columns["idsdelka"];
  1226. this.columnidpotrebnost = base.Columns["idpotrebnost"];
  1227. this.columnidpredlozhenie = base.Columns["idpredlozhenie"];
  1228. this.columndatesdelka = base.Columns["datesdelka"];
  1229. }
  1230. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1231. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1232. private void InitClass() {
  1233. this.columnidsdelka = new global::System.Data.DataColumn("idsdelka", typeof(int), null, global::System.Data.MappingType.Element);
  1234. base.Columns.Add(this.columnidsdelka);
  1235. this.columnidpotrebnost = new global::System.Data.DataColumn("idpotrebnost", typeof(int), null, global::System.Data.MappingType.Element);
  1236. base.Columns.Add(this.columnidpotrebnost);
  1237. this.columnidpredlozhenie = new global::System.Data.DataColumn("idpredlozhenie", typeof(int), null, global::System.Data.MappingType.Element);
  1238. base.Columns.Add(this.columnidpredlozhenie);
  1239. this.columndatesdelka = new global::System.Data.DataColumn("datesdelka", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element);
  1240. base.Columns.Add(this.columndatesdelka);
  1241. this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
  1242. this.columnidsdelka}, true));
  1243. this.columnidsdelka.AutoIncrement = true;
  1244. this.columnidsdelka.AutoIncrementSeed = 1;
  1245. this.columnidsdelka.AllowDBNull = false;
  1246. this.columnidsdelka.ReadOnly = true;
  1247. this.columnidsdelka.Unique = true;
  1248. this.columnidpotrebnost.AllowDBNull = false;
  1249. this.columnidpredlozhenie.AllowDBNull = false;
  1250. }
  1251. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1252. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1253. public SdelkaRow NewSdelkaRow() {
  1254. return ((SdelkaRow)(this.NewRow()));
  1255. }
  1256. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1257. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1258. protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
  1259. return new SdelkaRow(builder);
  1260. }
  1261. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1262. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1263. protected override global::System.Type GetRowType() {
  1264. return typeof(SdelkaRow);
  1265. }
  1266. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1267. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1268. protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
  1269. base.OnRowChanged(e);
  1270. if ((this.SdelkaRowChanged != null)) {
  1271. this.SdelkaRowChanged(this, new SdelkaRowChangeEvent(((SdelkaRow)(e.Row)), e.Action));
  1272. }
  1273. }
  1274. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1275. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1276. protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
  1277. base.OnRowChanging(e);
  1278. if ((this.SdelkaRowChanging != null)) {
  1279. this.SdelkaRowChanging(this, new SdelkaRowChangeEvent(((SdelkaRow)(e.Row)), e.Action));
  1280. }
  1281. }
  1282. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1283. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1284. protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
  1285. base.OnRowDeleted(e);
  1286. if ((this.SdelkaRowDeleted != null)) {
  1287. this.SdelkaRowDeleted(this, new SdelkaRowChangeEvent(((SdelkaRow)(e.Row)), e.Action));
  1288. }
  1289. }
  1290. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1291. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1292. protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
  1293. base.OnRowDeleting(e);
  1294. if ((this.SdelkaRowDeleting != null)) {
  1295. this.SdelkaRowDeleting(this, new SdelkaRowChangeEvent(((SdelkaRow)(e.Row)), e.Action));
  1296. }
  1297. }
  1298. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1299. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1300. public void RemoveSdelkaRow(SdelkaRow row) {
  1301. this.Rows.Remove(row);
  1302. }
  1303. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1304. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1305. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  1306. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  1307. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  1308. DBAgentstvoDataSet ds = new DBAgentstvoDataSet();
  1309. global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
  1310. any1.Namespace = "http://www.w3.org/2001/XMLSchema";
  1311. any1.MinOccurs = new decimal(0);
  1312. any1.MaxOccurs = decimal.MaxValue;
  1313. any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  1314. sequence.Items.Add(any1);
  1315. global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
  1316. any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
  1317. any2.MinOccurs = new decimal(1);
  1318. any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  1319. sequence.Items.Add(any2);
  1320. global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
  1321. attribute1.Name = "namespace";
  1322. attribute1.FixedValue = ds.Namespace;
  1323. type.Attributes.Add(attribute1);
  1324. global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
  1325. attribute2.Name = "tableTypeName";
  1326. attribute2.FixedValue = "SdelkaDataTable";
  1327. type.Attributes.Add(attribute2);
  1328. type.Particle = sequence;
  1329. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  1330. if (xs.Contains(dsSchema.TargetNamespace)) {
  1331. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  1332. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  1333. try {
  1334. global::System.Xml.Schema.XmlSchema schema = null;
  1335. dsSchema.Write(s1);
  1336. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  1337. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  1338. s2.SetLength(0);
  1339. schema.Write(s2);
  1340. if ((s1.Length == s2.Length)) {
  1341. s1.Position = 0;
  1342. s2.Position = 0;
  1343. for (; ((s1.Position != s1.Length)
  1344. && (s1.ReadByte() == s2.ReadByte())); ) {
  1345. ;
  1346. }
  1347. if ((s1.Position == s1.Length)) {
  1348. return type;
  1349. }
  1350. }
  1351. }
  1352. }
  1353. finally {
  1354. if ((s1 != null)) {
  1355. s1.Close();
  1356. }
  1357. if ((s2 != null)) {
  1358. s2.Close();
  1359. }
  1360. }
  1361. }
  1362. xs.Add(dsSchema);
  1363. return type;
  1364. }
  1365. }
  1366. /// <summary>
  1367. ///Represents the strongly named DataTable class.
  1368. ///</summary>
  1369. [global::System.Serializable()]
  1370. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
  1371. public partial class UsersDataTable : global::System.Data.TypedTableBase<UsersRow> {
  1372. private global::System.Data.DataColumn columnidusers;
  1373. private global::System.Data.DataColumn columnfam;
  1374. private global::System.Data.DataColumn columnname;
  1375. private global::System.Data.DataColumn columnlogin;
  1376. private global::System.Data.DataColumn columnpassword;
  1377. private global::System.Data.DataColumn columntype;
  1378. private global::System.Data.DataColumn columnphoto;
  1379. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1380. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1381. public UsersDataTable() {
  1382. this.TableName = "Users";
  1383. this.BeginInit();
  1384. this.InitClass();
  1385. this.EndInit();
  1386. }
  1387. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1388. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1389. internal UsersDataTable(global::System.Data.DataTable table) {
  1390. this.TableName = table.TableName;
  1391. if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
  1392. this.CaseSensitive = table.CaseSensitive;
  1393. }
  1394. if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
  1395. this.Locale = table.Locale;
  1396. }
  1397. if ((table.Namespace != table.DataSet.Namespace)) {
  1398. this.Namespace = table.Namespace;
  1399. }
  1400. this.Prefix = table.Prefix;
  1401. this.MinimumCapacity = table.MinimumCapacity;
  1402. }
  1403. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1404. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1405. protected UsersDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  1406. base(info, context) {
  1407. this.InitVars();
  1408. }
  1409. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1410. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1411. public global::System.Data.DataColumn idusersColumn {
  1412. get {
  1413. return this.columnidusers;
  1414. }
  1415. }
  1416. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1417. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1418. public global::System.Data.DataColumn famColumn {
  1419. get {
  1420. return this.columnfam;
  1421. }
  1422. }
  1423. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1424. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1425. public global::System.Data.DataColumn nameColumn {
  1426. get {
  1427. return this.columnname;
  1428. }
  1429. }
  1430. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1431. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1432. public global::System.Data.DataColumn loginColumn {
  1433. get {
  1434. return this.columnlogin;
  1435. }
  1436. }
  1437. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1438. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1439. public global::System.Data.DataColumn passwordColumn {
  1440. get {
  1441. return this.columnpassword;
  1442. }
  1443. }
  1444. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1445. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1446. public global::System.Data.DataColumn typeColumn {
  1447. get {
  1448. return this.columntype;
  1449. }
  1450. }
  1451. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1452. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1453. public global::System.Data.DataColumn photoColumn {
  1454. get {
  1455. return this.columnphoto;
  1456. }
  1457. }
  1458. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1459. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1460. [global::System.ComponentModel.Browsable(false)]
  1461. public int Count {
  1462. get {
  1463. return this.Rows.Count;
  1464. }
  1465. }
  1466. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1467. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1468. public UsersRow this[int index] {
  1469. get {
  1470. return ((UsersRow)(this.Rows[index]));
  1471. }
  1472. }
  1473. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1474. public event UsersRowChangeEventHandler UsersRowChanging;
  1475. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1476. public event UsersRowChangeEventHandler UsersRowChanged;
  1477. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1478. public event UsersRowChangeEventHandler UsersRowDeleting;
  1479. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1480. public event UsersRowChangeEventHandler UsersRowDeleted;
  1481. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1482. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1483. public void AddUsersRow(UsersRow row) {
  1484. this.Rows.Add(row);
  1485. }
  1486. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1487. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1488. public UsersRow AddUsersRow(string fam, string name, string login, string password, string type, byte[] photo) {
  1489. UsersRow rowUsersRow = ((UsersRow)(this.NewRow()));
  1490. object[] columnValuesArray = new object[] {
  1491. null,
  1492. fam,
  1493. name,
  1494. login,
  1495. password,
  1496. type,
  1497. photo};
  1498. rowUsersRow.ItemArray = columnValuesArray;
  1499. this.Rows.Add(rowUsersRow);
  1500. return rowUsersRow;
  1501. }
  1502. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1503. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1504. public UsersRow FindByidusers(int idusers) {
  1505. return ((UsersRow)(this.Rows.Find(new object[] {
  1506. idusers})));
  1507. }
  1508. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1509. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1510. public override global::System.Data.DataTable Clone() {
  1511. UsersDataTable cln = ((UsersDataTable)(base.Clone()));
  1512. cln.InitVars();
  1513. return cln;
  1514. }
  1515. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1516. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1517. protected override global::System.Data.DataTable CreateInstance() {
  1518. return new UsersDataTable();
  1519. }
  1520. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1521. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1522. internal void InitVars() {
  1523. this.columnidusers = base.Columns["idusers"];
  1524. this.columnfam = base.Columns["fam"];
  1525. this.columnname = base.Columns["name"];
  1526. this.columnlogin = base.Columns["login"];
  1527. this.columnpassword = base.Columns["password"];
  1528. this.columntype = base.Columns["type"];
  1529. this.columnphoto = base.Columns["photo"];
  1530. }
  1531. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1532. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1533. private void InitClass() {
  1534. this.columnidusers = new global::System.Data.DataColumn("idusers", typeof(int), null, global::System.Data.MappingType.Element);
  1535. base.Columns.Add(this.columnidusers);
  1536. this.columnfam = new global::System.Data.DataColumn("fam", typeof(string), null, global::System.Data.MappingType.Element);
  1537. base.Columns.Add(this.columnfam);
  1538. this.columnname = new global::System.Data.DataColumn("name", typeof(string), null, global::System.Data.MappingType.Element);
  1539. base.Columns.Add(this.columnname);
  1540. this.columnlogin = new global::System.Data.DataColumn("login", typeof(string), null, global::System.Data.MappingType.Element);
  1541. base.Columns.Add(this.columnlogin);
  1542. this.columnpassword = new global::System.Data.DataColumn("password", typeof(string), null, global::System.Data.MappingType.Element);
  1543. base.Columns.Add(this.columnpassword);
  1544. this.columntype = new global::System.Data.DataColumn("type", typeof(string), null, global::System.Data.MappingType.Element);
  1545. base.Columns.Add(this.columntype);
  1546. this.columnphoto = new global::System.Data.DataColumn("photo", typeof(byte[]), null, global::System.Data.MappingType.Element);
  1547. base.Columns.Add(this.columnphoto);
  1548. this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
  1549. this.columnidusers}, true));
  1550. this.columnidusers.AutoIncrement = true;
  1551. this.columnidusers.AutoIncrementSeed = 1;
  1552. this.columnidusers.AllowDBNull = false;
  1553. this.columnidusers.ReadOnly = true;
  1554. this.columnidusers.Unique = true;
  1555. this.columnfam.MaxLength = 50;
  1556. this.columnname.MaxLength = 50;
  1557. this.columnlogin.AllowDBNull = false;
  1558. this.columnlogin.MaxLength = 50;
  1559. this.columnpassword.AllowDBNull = false;
  1560. this.columnpassword.MaxLength = 50;
  1561. this.columntype.AllowDBNull = false;
  1562. this.columntype.DefaultValue = ((string)("1"));
  1563. this.columntype.MaxLength = 50;
  1564. }
  1565. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1566. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1567. public UsersRow NewUsersRow() {
  1568. return ((UsersRow)(this.NewRow()));
  1569. }
  1570. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1571. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1572. protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
  1573. return new UsersRow(builder);
  1574. }
  1575. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1576. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1577. protected override global::System.Type GetRowType() {
  1578. return typeof(UsersRow);
  1579. }
  1580. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1581. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1582. protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
  1583. base.OnRowChanged(e);
  1584. if ((this.UsersRowChanged != null)) {
  1585. this.UsersRowChanged(this, new UsersRowChangeEvent(((UsersRow)(e.Row)), e.Action));
  1586. }
  1587. }
  1588. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1589. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1590. protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
  1591. base.OnRowChanging(e);
  1592. if ((this.UsersRowChanging != null)) {
  1593. this.UsersRowChanging(this, new UsersRowChangeEvent(((UsersRow)(e.Row)), e.Action));
  1594. }
  1595. }
  1596. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1597. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1598. protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
  1599. base.OnRowDeleted(e);
  1600. if ((this.UsersRowDeleted != null)) {
  1601. this.UsersRowDeleted(this, new UsersRowChangeEvent(((UsersRow)(e.Row)), e.Action));
  1602. }
  1603. }
  1604. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1605. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1606. protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
  1607. base.OnRowDeleting(e);
  1608. if ((this.UsersRowDeleting != null)) {
  1609. this.UsersRowDeleting(this, new UsersRowChangeEvent(((UsersRow)(e.Row)), e.Action));
  1610. }
  1611. }
  1612. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1613. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1614. public void RemoveUsersRow(UsersRow row) {
  1615. this.Rows.Remove(row);
  1616. }
  1617. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1618. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1619. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  1620. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  1621. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  1622. DBAgentstvoDataSet ds = new DBAgentstvoDataSet();
  1623. global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
  1624. any1.Namespace = "http://www.w3.org/2001/XMLSchema";
  1625. any1.MinOccurs = new decimal(0);
  1626. any1.MaxOccurs = decimal.MaxValue;
  1627. any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  1628. sequence.Items.Add(any1);
  1629. global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
  1630. any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
  1631. any2.MinOccurs = new decimal(1);
  1632. any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  1633. sequence.Items.Add(any2);
  1634. global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
  1635. attribute1.Name = "namespace";
  1636. attribute1.FixedValue = ds.Namespace;
  1637. type.Attributes.Add(attribute1);
  1638. global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
  1639. attribute2.Name = "tableTypeName";
  1640. attribute2.FixedValue = "UsersDataTable";
  1641. type.Attributes.Add(attribute2);
  1642. type.Particle = sequence;
  1643. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  1644. if (xs.Contains(dsSchema.TargetNamespace)) {
  1645. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  1646. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  1647. try {
  1648. global::System.Xml.Schema.XmlSchema schema = null;
  1649. dsSchema.Write(s1);
  1650. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  1651. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  1652. s2.SetLength(0);
  1653. schema.Write(s2);
  1654. if ((s1.Length == s2.Length)) {
  1655. s1.Position = 0;
  1656. s2.Position = 0;
  1657. for (; ((s1.Position != s1.Length)
  1658. && (s1.ReadByte() == s2.ReadByte())); ) {
  1659. ;
  1660. }
  1661. if ((s1.Position == s1.Length)) {
  1662. return type;
  1663. }
  1664. }
  1665. }
  1666. }
  1667. finally {
  1668. if ((s1 != null)) {
  1669. s1.Close();
  1670. }
  1671. if ((s2 != null)) {
  1672. s2.Close();
  1673. }
  1674. }
  1675. }
  1676. xs.Add(dsSchema);
  1677. return type;
  1678. }
  1679. }
  1680. /// <summary>
  1681. ///Represents strongly named DataRow class.
  1682. ///</summary>
  1683. public partial class PotrebnostRow : global::System.Data.DataRow {
  1684. private PotrebnostDataTable tablePotrebnost;
  1685. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1686. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1687. internal PotrebnostRow(global::System.Data.DataRowBuilder rb) :
  1688. base(rb) {
  1689. this.tablePotrebnost = ((PotrebnostDataTable)(this.Table));
  1690. }
  1691. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1692. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1693. public int idpotrebnost {
  1694. get {
  1695. return ((int)(this[this.tablePotrebnost.idpotrebnostColumn]));
  1696. }
  1697. set {
  1698. this[this.tablePotrebnost.idpotrebnostColumn] = value;
  1699. }
  1700. }
  1701. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1702. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1703. public int idklient {
  1704. get {
  1705. return ((int)(this[this.tablePotrebnost.idklientColumn]));
  1706. }
  1707. set {
  1708. this[this.tablePotrebnost.idklientColumn] = value;
  1709. }
  1710. }
  1711. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1712. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1713. public int idrielter {
  1714. get {
  1715. return ((int)(this[this.tablePotrebnost.idrielterColumn]));
  1716. }
  1717. set {
  1718. this[this.tablePotrebnost.idrielterColumn] = value;
  1719. }
  1720. }
  1721. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1722. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1723. public int minplosh {
  1724. get {
  1725. try {
  1726. return ((int)(this[this.tablePotrebnost.minploshColumn]));
  1727. }
  1728. catch (global::System.InvalidCastException e) {
  1729. throw new global::System.Data.StrongTypingException("The value for column \'minplosh\' in table \'Potrebnost\' is DBNull.", e);
  1730. }
  1731. }
  1732. set {
  1733. this[this.tablePotrebnost.minploshColumn] = value;
  1734. }
  1735. }
  1736. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1737. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1738. public int maxplosh {
  1739. get {
  1740. try {
  1741. return ((int)(this[this.tablePotrebnost.maxploshColumn]));
  1742. }
  1743. catch (global::System.InvalidCastException e) {
  1744. throw new global::System.Data.StrongTypingException("The value for column \'maxplosh\' in table \'Potrebnost\' is DBNull.", e);
  1745. }
  1746. }
  1747. set {
  1748. this[this.tablePotrebnost.maxploshColumn] = value;
  1749. }
  1750. }
  1751. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1752. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1753. public int minetazh {
  1754. get {
  1755. try {
  1756. return ((int)(this[this.tablePotrebnost.minetazhColumn]));
  1757. }
  1758. catch (global::System.InvalidCastException e) {
  1759. throw new global::System.Data.StrongTypingException("The value for column \'minetazh\' in table \'Potrebnost\' is DBNull.", e);
  1760. }
  1761. }
  1762. set {
  1763. this[this.tablePotrebnost.minetazhColumn] = value;
  1764. }
  1765. }
  1766. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1767. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1768. public int maxetazh {
  1769. get {
  1770. try {
  1771. return ((int)(this[this.tablePotrebnost.maxetazhColumn]));
  1772. }
  1773. catch (global::System.InvalidCastException e) {
  1774. throw new global::System.Data.StrongTypingException("The value for column \'maxetazh\' in table \'Potrebnost\' is DBNull.", e);
  1775. }
  1776. }
  1777. set {
  1778. this[this.tablePotrebnost.maxetazhColumn] = value;
  1779. }
  1780. }
  1781. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1782. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1783. public int minkomnat {
  1784. get {
  1785. try {
  1786. return ((int)(this[this.tablePotrebnost.minkomnatColumn]));
  1787. }
  1788. catch (global::System.InvalidCastException e) {
  1789. throw new global::System.Data.StrongTypingException("The value for column \'minkomnat\' in table \'Potrebnost\' is DBNull.", e);
  1790. }
  1791. }
  1792. set {
  1793. this[this.tablePotrebnost.minkomnatColumn] = value;
  1794. }
  1795. }
  1796. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1797. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1798. public int maxkomnat {
  1799. get {
  1800. try {
  1801. return ((int)(this[this.tablePotrebnost.maxkomnatColumn]));
  1802. }
  1803. catch (global::System.InvalidCastException e) {
  1804. throw new global::System.Data.StrongTypingException("The value for column \'maxkomnat\' in table \'Potrebnost\' is DBNull.", e);
  1805. }
  1806. }
  1807. set {
  1808. this[this.tablePotrebnost.maxkomnatColumn] = value;
  1809. }
  1810. }
  1811. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1812. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1813. public decimal mincena {
  1814. get {
  1815. try {
  1816. return ((decimal)(this[this.tablePotrebnost.mincenaColumn]));
  1817. }
  1818. catch (global::System.InvalidCastException e) {
  1819. throw new global::System.Data.StrongTypingException("The value for column \'mincena\' in table \'Potrebnost\' is DBNull.", e);
  1820. }
  1821. }
  1822. set {
  1823. this[this.tablePotrebnost.mincenaColumn] = value;
  1824. }
  1825. }
  1826. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1827. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1828. public decimal maxcena {
  1829. get {
  1830. try {
  1831. return ((decimal)(this[this.tablePotrebnost.maxcenaColumn]));
  1832. }
  1833. catch (global::System.InvalidCastException e) {
  1834. throw new global::System.Data.StrongTypingException("The value for column \'maxcena\' in table \'Potrebnost\' is DBNull.", e);
  1835. }
  1836. }
  1837. set {
  1838. this[this.tablePotrebnost.maxcenaColumn] = value;
  1839. }
  1840. }
  1841. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1842. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1843. public bool zaversheno {
  1844. get {
  1845. try {
  1846. return ((bool)(this[this.tablePotrebnost.zavershenoColumn]));
  1847. }
  1848. catch (global::System.InvalidCastException e) {
  1849. throw new global::System.Data.StrongTypingException("The value for column \'zaversheno\' in table \'Potrebnost\' is DBNull.", e);
  1850. }
  1851. }
  1852. set {
  1853. this[this.tablePotrebnost.zavershenoColumn] = value;
  1854. }
  1855. }
  1856. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1857. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1858. public UsersRow UsersRowByFK_Potrebnost_Users {
  1859. get {
  1860. return ((UsersRow)(this.GetParentRow(this.Table.ParentRelations["FK_Potrebnost_Users"])));
  1861. }
  1862. set {
  1863. this.SetParentRow(value, this.Table.ParentRelations["FK_Potrebnost_Users"]);
  1864. }
  1865. }
  1866. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1867. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1868. public UsersRow UsersRowByFK_Potrebnost_Users1 {
  1869. get {
  1870. return ((UsersRow)(this.GetParentRow(this.Table.ParentRelations["FK_Potrebnost_Users1"])));
  1871. }
  1872. set {
  1873. this.SetParentRow(value, this.Table.ParentRelations["FK_Potrebnost_Users1"]);
  1874. }
  1875. }
  1876. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1877. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1878. public bool IsminploshNull() {
  1879. return this.IsNull(this.tablePotrebnost.minploshColumn);
  1880. }
  1881. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1882. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1883. public void SetminploshNull() {
  1884. this[this.tablePotrebnost.minploshColumn] = global::System.Convert.DBNull;
  1885. }
  1886. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1887. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1888. public bool IsmaxploshNull() {
  1889. return this.IsNull(this.tablePotrebnost.maxploshColumn);
  1890. }
  1891. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1892. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1893. public void SetmaxploshNull() {
  1894. this[this.tablePotrebnost.maxploshColumn] = global::System.Convert.DBNull;
  1895. }
  1896. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1897. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1898. public bool IsminetazhNull() {
  1899. return this.IsNull(this.tablePotrebnost.minetazhColumn);
  1900. }
  1901. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1902. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1903. public void SetminetazhNull() {
  1904. this[this.tablePotrebnost.minetazhColumn] = global::System.Convert.DBNull;
  1905. }
  1906. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1907. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1908. public bool IsmaxetazhNull() {
  1909. return this.IsNull(this.tablePotrebnost.maxetazhColumn);
  1910. }
  1911. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1912. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1913. public void SetmaxetazhNull() {
  1914. this[this.tablePotrebnost.maxetazhColumn] = global::System.Convert.DBNull;
  1915. }
  1916. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1917. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1918. public bool IsminkomnatNull() {
  1919. return this.IsNull(this.tablePotrebnost.minkomnatColumn);
  1920. }
  1921. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1922. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1923. public void SetminkomnatNull() {
  1924. this[this.tablePotrebnost.minkomnatColumn] = global::System.Convert.DBNull;
  1925. }
  1926. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1927. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1928. public bool IsmaxkomnatNull() {
  1929. return this.IsNull(this.tablePotrebnost.maxkomnatColumn);
  1930. }
  1931. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1932. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1933. public void SetmaxkomnatNull() {
  1934. this[this.tablePotrebnost.maxkomnatColumn] = global::System.Convert.DBNull;
  1935. }
  1936. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1937. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1938. public bool IsmincenaNull() {
  1939. return this.IsNull(this.tablePotrebnost.mincenaColumn);
  1940. }
  1941. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1942. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1943. public void SetmincenaNull() {
  1944. this[this.tablePotrebnost.mincenaColumn] = global::System.Convert.DBNull;
  1945. }
  1946. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1947. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1948. public bool IsmaxcenaNull() {
  1949. return this.IsNull(this.tablePotrebnost.maxcenaColumn);
  1950. }
  1951. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1952. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1953. public void SetmaxcenaNull() {
  1954. this[this.tablePotrebnost.maxcenaColumn] = global::System.Convert.DBNull;
  1955. }
  1956. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1957. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1958. public bool IszavershenoNull() {
  1959. return this.IsNull(this.tablePotrebnost.zavershenoColumn);
  1960. }
  1961. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1962. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1963. public void SetzavershenoNull() {
  1964. this[this.tablePotrebnost.zavershenoColumn] = global::System.Convert.DBNull;
  1965. }
  1966. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1967. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1968. public SdelkaRow[] GetSdelkaRows() {
  1969. if ((this.Table.ChildRelations["FK_Sdelka_Potrebnost"] == null)) {
  1970. return new SdelkaRow[0];
  1971. }
  1972. else {
  1973. return ((SdelkaRow[])(base.GetChildRows(this.Table.ChildRelations["FK_Sdelka_Potrebnost"])));
  1974. }
  1975. }
  1976. }
  1977. /// <summary>
  1978. ///Represents strongly named DataRow class.
  1979. ///</summary>
  1980. public partial class predlozhenieRow : global::System.Data.DataRow {
  1981. private predlozhenieDataTable tablepredlozhenie;
  1982. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1983. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1984. internal predlozhenieRow(global::System.Data.DataRowBuilder rb) :
  1985. base(rb) {
  1986. this.tablepredlozhenie = ((predlozhenieDataTable)(this.Table));
  1987. }
  1988. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1989. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  1990. public int idpredlozhenie {
  1991. get {
  1992. return ((int)(this[this.tablepredlozhenie.idpredlozhenieColumn]));
  1993. }
  1994. set {
  1995. this[this.tablepredlozhenie.idpredlozhenieColumn] = value;
  1996. }
  1997. }
  1998. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1999. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2000. public int idklient {
  2001. get {
  2002. return ((int)(this[this.tablepredlozhenie.idklientColumn]));
  2003. }
  2004. set {
  2005. this[this.tablepredlozhenie.idklientColumn] = value;
  2006. }
  2007. }
  2008. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2009. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2010. public int idrielter {
  2011. get {
  2012. return ((int)(this[this.tablepredlozhenie.idrielterColumn]));
  2013. }
  2014. set {
  2015. this[this.tablepredlozhenie.idrielterColumn] = value;
  2016. }
  2017. }
  2018. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2019. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2020. public string adres {
  2021. get {
  2022. try {
  2023. return ((string)(this[this.tablepredlozhenie.adresColumn]));
  2024. }
  2025. catch (global::System.InvalidCastException e) {
  2026. throw new global::System.Data.StrongTypingException("The value for column \'adres\' in table \'predlozhenie\' is DBNull.", e);
  2027. }
  2028. }
  2029. set {
  2030. this[this.tablepredlozhenie.adresColumn] = value;
  2031. }
  2032. }
  2033. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2034. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2035. public int plosh {
  2036. get {
  2037. try {
  2038. return ((int)(this[this.tablepredlozhenie.ploshColumn]));
  2039. }
  2040. catch (global::System.InvalidCastException e) {
  2041. throw new global::System.Data.StrongTypingException("The value for column \'plosh\' in table \'predlozhenie\' is DBNull.", e);
  2042. }
  2043. }
  2044. set {
  2045. this[this.tablepredlozhenie.ploshColumn] = value;
  2046. }
  2047. }
  2048. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2049. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2050. public int etazh {
  2051. get {
  2052. try {
  2053. return ((int)(this[this.tablepredlozhenie.etazhColumn]));
  2054. }
  2055. catch (global::System.InvalidCastException e) {
  2056. throw new global::System.Data.StrongTypingException("The value for column \'etazh\' in table \'predlozhenie\' is DBNull.", e);
  2057. }
  2058. }
  2059. set {
  2060. this[this.tablepredlozhenie.etazhColumn] = value;
  2061. }
  2062. }
  2063. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2064. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2065. public int komnat {
  2066. get {
  2067. try {
  2068. return ((int)(this[this.tablepredlozhenie.komnatColumn]));
  2069. }
  2070. catch (global::System.InvalidCastException e) {
  2071. throw new global::System.Data.StrongTypingException("The value for column \'komnat\' in table \'predlozhenie\' is DBNull.", e);
  2072. }
  2073. }
  2074. set {
  2075. this[this.tablepredlozhenie.komnatColumn] = value;
  2076. }
  2077. }
  2078. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2079. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2080. public decimal cena {
  2081. get {
  2082. try {
  2083. return ((decimal)(this[this.tablepredlozhenie.cenaColumn]));
  2084. }
  2085. catch (global::System.InvalidCastException e) {
  2086. throw new global::System.Data.StrongTypingException("The value for column \'cena\' in table \'predlozhenie\' is DBNull.", e);
  2087. }
  2088. }
  2089. set {
  2090. this[this.tablepredlozhenie.cenaColumn] = value;
  2091. }
  2092. }
  2093. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2094. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2095. public bool zaversheno {
  2096. get {
  2097. try {
  2098. return ((bool)(this[this.tablepredlozhenie.zavershenoColumn]));
  2099. }
  2100. catch (global::System.InvalidCastException e) {
  2101. throw new global::System.Data.StrongTypingException("The value for column \'zaversheno\' in table \'predlozhenie\' is DBNull.", e);
  2102. }
  2103. }
  2104. set {
  2105. this[this.tablepredlozhenie.zavershenoColumn] = value;
  2106. }
  2107. }
  2108. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2109. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2110. public UsersRow UsersRowByFK_predlozhenie_Users {
  2111. get {
  2112. return ((UsersRow)(this.GetParentRow(this.Table.ParentRelations["FK_predlozhenie_Users"])));
  2113. }
  2114. set {
  2115. this.SetParentRow(value, this.Table.ParentRelations["FK_predlozhenie_Users"]);
  2116. }
  2117. }
  2118. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2119. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2120. public UsersRow UsersRowByFK_predlozhenie_Users1 {
  2121. get {
  2122. return ((UsersRow)(this.GetParentRow(this.Table.ParentRelations["FK_predlozhenie_Users1"])));
  2123. }
  2124. set {
  2125. this.SetParentRow(value, this.Table.ParentRelations["FK_predlozhenie_Users1"]);
  2126. }
  2127. }
  2128. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2129. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2130. public bool IsadresNull() {
  2131. return this.IsNull(this.tablepredlozhenie.adresColumn);
  2132. }
  2133. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2134. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2135. public void SetadresNull() {
  2136. this[this.tablepredlozhenie.adresColumn] = global::System.Convert.DBNull;
  2137. }
  2138. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2139. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2140. public bool IsploshNull() {
  2141. return this.IsNull(this.tablepredlozhenie.ploshColumn);
  2142. }
  2143. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2144. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2145. public void SetploshNull() {
  2146. this[this.tablepredlozhenie.ploshColumn] = global::System.Convert.DBNull;
  2147. }
  2148. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2149. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2150. public bool IsetazhNull() {
  2151. return this.IsNull(this.tablepredlozhenie.etazhColumn);
  2152. }
  2153. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2154. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2155. public void SetetazhNull() {
  2156. this[this.tablepredlozhenie.etazhColumn] = global::System.Convert.DBNull;
  2157. }
  2158. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2159. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2160. public bool IskomnatNull() {
  2161. return this.IsNull(this.tablepredlozhenie.komnatColumn);
  2162. }
  2163. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2164. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2165. public void SetkomnatNull() {
  2166. this[this.tablepredlozhenie.komnatColumn] = global::System.Convert.DBNull;
  2167. }
  2168. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2169. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2170. public bool IscenaNull() {
  2171. return this.IsNull(this.tablepredlozhenie.cenaColumn);
  2172. }
  2173. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2174. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2175. public void SetcenaNull() {
  2176. this[this.tablepredlozhenie.cenaColumn] = global::System.Convert.DBNull;
  2177. }
  2178. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2179. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2180. public bool IszavershenoNull() {
  2181. return this.IsNull(this.tablepredlozhenie.zavershenoColumn);
  2182. }
  2183. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2184. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2185. public void SetzavershenoNull() {
  2186. this[this.tablepredlozhenie.zavershenoColumn] = global::System.Convert.DBNull;
  2187. }
  2188. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2189. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2190. public SdelkaRow[] GetSdelkaRows() {
  2191. if ((this.Table.ChildRelations["FK_Sdelka_predlozhenie"] == null)) {
  2192. return new SdelkaRow[0];
  2193. }
  2194. else {
  2195. return ((SdelkaRow[])(base.GetChildRows(this.Table.ChildRelations["FK_Sdelka_predlozhenie"])));
  2196. }
  2197. }
  2198. }
  2199. /// <summary>
  2200. ///Represents strongly named DataRow class.
  2201. ///</summary>
  2202. public partial class SdelkaRow : global::System.Data.DataRow {
  2203. private SdelkaDataTable tableSdelka;
  2204. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2205. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2206. internal SdelkaRow(global::System.Data.DataRowBuilder rb) :
  2207. base(rb) {
  2208. this.tableSdelka = ((SdelkaDataTable)(this.Table));
  2209. }
  2210. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2211. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2212. public int idsdelka {
  2213. get {
  2214. return ((int)(this[this.tableSdelka.idsdelkaColumn]));
  2215. }
  2216. set {
  2217. this[this.tableSdelka.idsdelkaColumn] = value;
  2218. }
  2219. }
  2220. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2221. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2222. public int idpotrebnost {
  2223. get {
  2224. return ((int)(this[this.tableSdelka.idpotrebnostColumn]));
  2225. }
  2226. set {
  2227. this[this.tableSdelka.idpotrebnostColumn] = value;
  2228. }
  2229. }
  2230. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2231. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2232. public int idpredlozhenie {
  2233. get {
  2234. return ((int)(this[this.tableSdelka.idpredlozhenieColumn]));
  2235. }
  2236. set {
  2237. this[this.tableSdelka.idpredlozhenieColumn] = value;
  2238. }
  2239. }
  2240. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2241. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2242. public System.DateTime datesdelka {
  2243. get {
  2244. try {
  2245. return ((global::System.DateTime)(this[this.tableSdelka.datesdelkaColumn]));
  2246. }
  2247. catch (global::System.InvalidCastException e) {
  2248. throw new global::System.Data.StrongTypingException("The value for column \'datesdelka\' in table \'Sdelka\' is DBNull.", e);
  2249. }
  2250. }
  2251. set {
  2252. this[this.tableSdelka.datesdelkaColumn] = value;
  2253. }
  2254. }
  2255. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2256. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2257. public PotrebnostRow PotrebnostRow {
  2258. get {
  2259. return ((PotrebnostRow)(this.GetParentRow(this.Table.ParentRelations["FK_Sdelka_Potrebnost"])));
  2260. }
  2261. set {
  2262. this.SetParentRow(value, this.Table.ParentRelations["FK_Sdelka_Potrebnost"]);
  2263. }
  2264. }
  2265. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2266. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2267. public predlozhenieRow predlozhenieRow {
  2268. get {
  2269. return ((predlozhenieRow)(this.GetParentRow(this.Table.ParentRelations["FK_Sdelka_predlozhenie"])));
  2270. }
  2271. set {
  2272. this.SetParentRow(value, this.Table.ParentRelations["FK_Sdelka_predlozhenie"]);
  2273. }
  2274. }
  2275. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2276. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2277. public bool IsdatesdelkaNull() {
  2278. return this.IsNull(this.tableSdelka.datesdelkaColumn);
  2279. }
  2280. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2281. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2282. public void SetdatesdelkaNull() {
  2283. this[this.tableSdelka.datesdelkaColumn] = global::System.Convert.DBNull;
  2284. }
  2285. }
  2286. /// <summary>
  2287. ///Represents strongly named DataRow class.
  2288. ///</summary>
  2289. public partial class UsersRow : global::System.Data.DataRow {
  2290. private UsersDataTable tableUsers;
  2291. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2292. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2293. internal UsersRow(global::System.Data.DataRowBuilder rb) :
  2294. base(rb) {
  2295. this.tableUsers = ((UsersDataTable)(this.Table));
  2296. }
  2297. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2298. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2299. public int idusers {
  2300. get {
  2301. return ((int)(this[this.tableUsers.idusersColumn]));
  2302. }
  2303. set {
  2304. this[this.tableUsers.idusersColumn] = value;
  2305. }
  2306. }
  2307. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2308. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2309. public string fam {
  2310. get {
  2311. try {
  2312. return ((string)(this[this.tableUsers.famColumn]));
  2313. }
  2314. catch (global::System.InvalidCastException e) {
  2315. throw new global::System.Data.StrongTypingException("The value for column \'fam\' in table \'Users\' is DBNull.", e);
  2316. }
  2317. }
  2318. set {
  2319. this[this.tableUsers.famColumn] = value;
  2320. }
  2321. }
  2322. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2323. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2324. public string name {
  2325. get {
  2326. try {
  2327. return ((string)(this[this.tableUsers.nameColumn]));
  2328. }
  2329. catch (global::System.InvalidCastException e) {
  2330. throw new global::System.Data.StrongTypingException("The value for column \'name\' in table \'Users\' is DBNull.", e);
  2331. }
  2332. }
  2333. set {
  2334. this[this.tableUsers.nameColumn] = value;
  2335. }
  2336. }
  2337. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2338. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2339. public string login {
  2340. get {
  2341. return ((string)(this[this.tableUsers.loginColumn]));
  2342. }
  2343. set {
  2344. this[this.tableUsers.loginColumn] = value;
  2345. }
  2346. }
  2347. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2348. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2349. public string password {
  2350. get {
  2351. return ((string)(this[this.tableUsers.passwordColumn]));
  2352. }
  2353. set {
  2354. this[this.tableUsers.passwordColumn] = value;
  2355. }
  2356. }
  2357. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2358. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2359. public string type {
  2360. get {
  2361. return ((string)(this[this.tableUsers.typeColumn]));
  2362. }
  2363. set {
  2364. this[this.tableUsers.typeColumn] = value;
  2365. }
  2366. }
  2367. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2368. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2369. public byte[] photo {
  2370. get {
  2371. try {
  2372. return ((byte[])(this[this.tableUsers.photoColumn]));
  2373. }
  2374. catch (global::System.InvalidCastException e) {
  2375. throw new global::System.Data.StrongTypingException("The value for column \'photo\' in table \'Users\' is DBNull.", e);
  2376. }
  2377. }
  2378. set {
  2379. this[this.tableUsers.photoColumn] = value;
  2380. }
  2381. }
  2382. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2383. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2384. public bool IsfamNull() {
  2385. return this.IsNull(this.tableUsers.famColumn);
  2386. }
  2387. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2388. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2389. public void SetfamNull() {
  2390. this[this.tableUsers.famColumn] = global::System.Convert.DBNull;
  2391. }
  2392. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2393. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2394. public bool IsnameNull() {
  2395. return this.IsNull(this.tableUsers.nameColumn);
  2396. }
  2397. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2398. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2399. public void SetnameNull() {
  2400. this[this.tableUsers.nameColumn] = global::System.Convert.DBNull;
  2401. }
  2402. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2403. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2404. public bool IsphotoNull() {
  2405. return this.IsNull(this.tableUsers.photoColumn);
  2406. }
  2407. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2408. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2409. public void SetphotoNull() {
  2410. this[this.tableUsers.photoColumn] = global::System.Convert.DBNull;
  2411. }
  2412. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2413. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2414. public PotrebnostRow[] GetPotrebnostRowsByFK_Potrebnost_Users() {
  2415. if ((this.Table.ChildRelations["FK_Potrebnost_Users"] == null)) {
  2416. return new PotrebnostRow[0];
  2417. }
  2418. else {
  2419. return ((PotrebnostRow[])(base.GetChildRows(this.Table.ChildRelations["FK_Potrebnost_Users"])));
  2420. }
  2421. }
  2422. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2423. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2424. public PotrebnostRow[] GetPotrebnostRowsByFK_Potrebnost_Users1() {
  2425. if ((this.Table.ChildRelations["FK_Potrebnost_Users1"] == null)) {
  2426. return new PotrebnostRow[0];
  2427. }
  2428. else {
  2429. return ((PotrebnostRow[])(base.GetChildRows(this.Table.ChildRelations["FK_Potrebnost_Users1"])));
  2430. }
  2431. }
  2432. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2433. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2434. public predlozhenieRow[] GetpredlozhenieRowsByFK_predlozhenie_Users() {
  2435. if ((this.Table.ChildRelations["FK_predlozhenie_Users"] == null)) {
  2436. return new predlozhenieRow[0];
  2437. }
  2438. else {
  2439. return ((predlozhenieRow[])(base.GetChildRows(this.Table.ChildRelations["FK_predlozhenie_Users"])));
  2440. }
  2441. }
  2442. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2443. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2444. public predlozhenieRow[] GetpredlozhenieRowsByFK_predlozhenie_Users1() {
  2445. if ((this.Table.ChildRelations["FK_predlozhenie_Users1"] == null)) {
  2446. return new predlozhenieRow[0];
  2447. }
  2448. else {
  2449. return ((predlozhenieRow[])(base.GetChildRows(this.Table.ChildRelations["FK_predlozhenie_Users1"])));
  2450. }
  2451. }
  2452. }
  2453. /// <summary>
  2454. ///Row event argument class
  2455. ///</summary>
  2456. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2457. public class PotrebnostRowChangeEvent : global::System.EventArgs {
  2458. private PotrebnostRow eventRow;
  2459. private global::System.Data.DataRowAction eventAction;
  2460. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2461. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2462. public PotrebnostRowChangeEvent(PotrebnostRow row, global::System.Data.DataRowAction action) {
  2463. this.eventRow = row;
  2464. this.eventAction = action;
  2465. }
  2466. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2467. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2468. public PotrebnostRow Row {
  2469. get {
  2470. return this.eventRow;
  2471. }
  2472. }
  2473. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2474. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2475. public global::System.Data.DataRowAction Action {
  2476. get {
  2477. return this.eventAction;
  2478. }
  2479. }
  2480. }
  2481. /// <summary>
  2482. ///Row event argument class
  2483. ///</summary>
  2484. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2485. public class predlozhenieRowChangeEvent : global::System.EventArgs {
  2486. private predlozhenieRow eventRow;
  2487. private global::System.Data.DataRowAction eventAction;
  2488. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2489. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2490. public predlozhenieRowChangeEvent(predlozhenieRow row, global::System.Data.DataRowAction action) {
  2491. this.eventRow = row;
  2492. this.eventAction = action;
  2493. }
  2494. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2495. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2496. public predlozhenieRow Row {
  2497. get {
  2498. return this.eventRow;
  2499. }
  2500. }
  2501. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2502. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2503. public global::System.Data.DataRowAction Action {
  2504. get {
  2505. return this.eventAction;
  2506. }
  2507. }
  2508. }
  2509. /// <summary>
  2510. ///Row event argument class
  2511. ///</summary>
  2512. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2513. public class SdelkaRowChangeEvent : global::System.EventArgs {
  2514. private SdelkaRow eventRow;
  2515. private global::System.Data.DataRowAction eventAction;
  2516. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2517. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2518. public SdelkaRowChangeEvent(SdelkaRow row, global::System.Data.DataRowAction action) {
  2519. this.eventRow = row;
  2520. this.eventAction = action;
  2521. }
  2522. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2523. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2524. public SdelkaRow Row {
  2525. get {
  2526. return this.eventRow;
  2527. }
  2528. }
  2529. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2530. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2531. public global::System.Data.DataRowAction Action {
  2532. get {
  2533. return this.eventAction;
  2534. }
  2535. }
  2536. }
  2537. /// <summary>
  2538. ///Row event argument class
  2539. ///</summary>
  2540. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2541. public class UsersRowChangeEvent : global::System.EventArgs {
  2542. private UsersRow eventRow;
  2543. private global::System.Data.DataRowAction eventAction;
  2544. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2545. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2546. public UsersRowChangeEvent(UsersRow row, global::System.Data.DataRowAction action) {
  2547. this.eventRow = row;
  2548. this.eventAction = action;
  2549. }
  2550. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2551. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2552. public UsersRow Row {
  2553. get {
  2554. return this.eventRow;
  2555. }
  2556. }
  2557. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2558. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2559. public global::System.Data.DataRowAction Action {
  2560. get {
  2561. return this.eventAction;
  2562. }
  2563. }
  2564. }
  2565. }
  2566. }
  2567. namespace СУБД_Агентство.DBAgentstvoDataSetTableAdapters {
  2568. /// <summary>
  2569. ///Represents the connection and commands used to retrieve and save data.
  2570. ///</summary>
  2571. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  2572. [global::System.ComponentModel.ToolboxItem(true)]
  2573. [global::System.ComponentModel.DataObjectAttribute(true)]
  2574. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
  2575. ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  2576. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2577. public partial class PotrebnostTableAdapter : global::System.ComponentModel.Component {
  2578. private global::System.Data.SqlClient.SqlDataAdapter _adapter;
  2579. private global::System.Data.SqlClient.SqlConnection _connection;
  2580. private global::System.Data.SqlClient.SqlTransaction _transaction;
  2581. private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
  2582. private bool _clearBeforeFill;
  2583. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2584. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2585. public PotrebnostTableAdapter() {
  2586. this.ClearBeforeFill = true;
  2587. }
  2588. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2589. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2590. protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
  2591. get {
  2592. if ((this._adapter == null)) {
  2593. this.InitAdapter();
  2594. }
  2595. return this._adapter;
  2596. }
  2597. }
  2598. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2599. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2600. internal global::System.Data.SqlClient.SqlConnection Connection {
  2601. get {
  2602. if ((this._connection == null)) {
  2603. this.InitConnection();
  2604. }
  2605. return this._connection;
  2606. }
  2607. set {
  2608. this._connection = value;
  2609. if ((this.Adapter.InsertCommand != null)) {
  2610. this.Adapter.InsertCommand.Connection = value;
  2611. }
  2612. if ((this.Adapter.DeleteCommand != null)) {
  2613. this.Adapter.DeleteCommand.Connection = value;
  2614. }
  2615. if ((this.Adapter.UpdateCommand != null)) {
  2616. this.Adapter.UpdateCommand.Connection = value;
  2617. }
  2618. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  2619. if ((this.CommandCollection[i] != null)) {
  2620. ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
  2621. }
  2622. }
  2623. }
  2624. }
  2625. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2626. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2627. internal global::System.Data.SqlClient.SqlTransaction Transaction {
  2628. get {
  2629. return this._transaction;
  2630. }
  2631. set {
  2632. this._transaction = value;
  2633. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  2634. this.CommandCollection[i].Transaction = this._transaction;
  2635. }
  2636. if (((this.Adapter != null)
  2637. && (this.Adapter.DeleteCommand != null))) {
  2638. this.Adapter.DeleteCommand.Transaction = this._transaction;
  2639. }
  2640. if (((this.Adapter != null)
  2641. && (this.Adapter.InsertCommand != null))) {
  2642. this.Adapter.InsertCommand.Transaction = this._transaction;
  2643. }
  2644. if (((this.Adapter != null)
  2645. && (this.Adapter.UpdateCommand != null))) {
  2646. this.Adapter.UpdateCommand.Transaction = this._transaction;
  2647. }
  2648. }
  2649. }
  2650. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2651. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2652. protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
  2653. get {
  2654. if ((this._commandCollection == null)) {
  2655. this.InitCommandCollection();
  2656. }
  2657. return this._commandCollection;
  2658. }
  2659. }
  2660. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2661. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2662. public bool ClearBeforeFill {
  2663. get {
  2664. return this._clearBeforeFill;
  2665. }
  2666. set {
  2667. this._clearBeforeFill = value;
  2668. }
  2669. }
  2670. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2671. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2672. private void InitAdapter() {
  2673. this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
  2674. global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
  2675. tableMapping.SourceTable = "Table";
  2676. tableMapping.DataSetTable = "Potrebnost";
  2677. tableMapping.ColumnMappings.Add("idpotrebnost", "idpotrebnost");
  2678. tableMapping.ColumnMappings.Add("idklient", "idklient");
  2679. tableMapping.ColumnMappings.Add("idrielter", "idrielter");
  2680. tableMapping.ColumnMappings.Add("minplosh", "minplosh");
  2681. tableMapping.ColumnMappings.Add("maxplosh", "maxplosh");
  2682. tableMapping.ColumnMappings.Add("minetazh", "minetazh");
  2683. tableMapping.ColumnMappings.Add("maxetazh", "maxetazh");
  2684. tableMapping.ColumnMappings.Add("minkomnat", "minkomnat");
  2685. tableMapping.ColumnMappings.Add("maxkomnat", "maxkomnat");
  2686. tableMapping.ColumnMappings.Add("mincena", "mincena");
  2687. tableMapping.ColumnMappings.Add("maxcena", "maxcena");
  2688. tableMapping.ColumnMappings.Add("zaversheno", "zaversheno");
  2689. this._adapter.TableMappings.Add(tableMapping);
  2690. this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
  2691. this._adapter.DeleteCommand.Connection = this.Connection;
  2692. this._adapter.DeleteCommand.CommandText = @"DELETE FROM [dbo].[Potrebnost] WHERE (([idpotrebnost] = @Original_idpotrebnost) AND ([idklient] = @Original_idklient) AND ([idrielter] = @Original_idrielter) AND ((@IsNull_minplosh = 1 AND [minplosh] IS NULL) OR ([minplosh] = @Original_minplosh)) AND ((@IsNull_maxplosh = 1 AND [maxplosh] IS NULL) OR ([maxplosh] = @Original_maxplosh)) AND ((@IsNull_minetazh = 1 AND [minetazh] IS NULL) OR ([minetazh] = @Original_minetazh)) AND ((@IsNull_maxetazh = 1 AND [maxetazh] IS NULL) OR ([maxetazh] = @Original_maxetazh)) AND ((@IsNull_minkomnat = 1 AND [minkomnat] IS NULL) OR ([minkomnat] = @Original_minkomnat)) AND ((@IsNull_maxkomnat = 1 AND [maxkomnat] IS NULL) OR ([maxkomnat] = @Original_maxkomnat)) AND ((@IsNull_mincena = 1 AND [mincena] IS NULL) OR ([mincena] = @Original_mincena)) AND ((@IsNull_maxcena = 1 AND [maxcena] IS NULL) OR ([maxcena] = @Original_maxcena)) AND ((@IsNull_zaversheno = 1 AND [zaversheno] IS NULL) OR ([zaversheno] = @Original_zaversheno)))";
  2693. this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
  2694. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpotrebnost", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpotrebnost", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2695. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2696. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2697. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_minplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minplosh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2698. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_minplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minplosh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2699. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxplosh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2700. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxplosh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2701. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_minetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minetazh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2702. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_minetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minetazh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2703. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxetazh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2704. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxetazh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2705. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_minkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minkomnat", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2706. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_minkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minkomnat", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2707. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxkomnat", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2708. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxkomnat", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2709. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_mincena", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "mincena", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2710. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_mincena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "mincena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2711. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxcena", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxcena", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2712. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxcena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxcena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2713. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_zaversheno", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2714. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2715. this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
  2716. this._adapter.InsertCommand.Connection = this.Connection;
  2717. this._adapter.InsertCommand.CommandText = @"INSERT INTO [dbo].[Potrebnost] ([idklient], [idrielter], [minplosh], [maxplosh], [minetazh], [maxetazh], [minkomnat], [maxkomnat], [mincena], [maxcena], [zaversheno]) VALUES (@idklient, @idrielter, @minplosh, @maxplosh, @minetazh, @maxetazh, @minkomnat, @maxkomnat, @mincena, @maxcena, @zaversheno);
  2718. SELECT idpotrebnost, idklient, idrielter, minplosh, maxplosh, minetazh, maxetazh, minkomnat, maxkomnat, mincena, maxcena, zaversheno FROM Potrebnost WHERE (idpotrebnost = SCOPE_IDENTITY())";
  2719. this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
  2720. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2721. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2722. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@minplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minplosh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2723. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxplosh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2724. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@minetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minetazh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2725. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxetazh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2726. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@minkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minkomnat", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2727. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxkomnat", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2728. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@mincena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "mincena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2729. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxcena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxcena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2730. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2731. this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
  2732. this._adapter.UpdateCommand.Connection = this.Connection;
  2733. this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Potrebnost] SET [idklient] = @idklient, [idrielter] = @idrielter, [minplosh] = @minplosh, [maxplosh] = @maxplosh, [minetazh] = @minetazh, [maxetazh] = @maxetazh, [minkomnat] = @minkomnat, [maxkomnat] = @maxkomnat, [mincena] = @mincena, [maxcena] = @maxcena, [zaversheno] = @zaversheno WHERE (([idpotrebnost] = @Original_idpotrebnost) AND ([idklient] = @Original_idklient) AND ([idrielter] = @Original_idrielter) AND ((@IsNull_minplosh = 1 AND [minplosh] IS NULL) OR ([minplosh] = @Original_minplosh)) AND ((@IsNull_maxplosh = 1 AND [maxplosh] IS NULL) OR ([maxplosh] = @Original_maxplosh)) AND ((@IsNull_minetazh = 1 AND [minetazh] IS NULL) OR ([minetazh] = @Original_minetazh)) AND ((@IsNull_maxetazh = 1 AND [maxetazh] IS NULL) OR ([maxetazh] = @Original_maxetazh)) AND ((@IsNull_minkomnat = 1 AND [minkomnat] IS NULL) OR ([minkomnat] = @Original_minkomnat)) AND ((@IsNull_maxkomnat = 1 AND [maxkomnat] IS NULL) OR ([maxkomnat] = @Original_maxkomnat)) AND ((@IsNull_mincena = 1 AND [mincena] IS NULL) OR ([mincena] = @Original_mincena)) AND ((@IsNull_maxcena = 1 AND [maxcena] IS NULL) OR ([maxcena] = @Original_maxcena)) AND ((@IsNull_zaversheno = 1 AND [zaversheno] IS NULL) OR ([zaversheno] = @Original_zaversheno)));
  2734. SELECT idpotrebnost, idklient, idrielter, minplosh, maxplosh, minetazh, maxetazh, minkomnat, maxkomnat, mincena, maxcena, zaversheno FROM Potrebnost WHERE (idpotrebnost = @idpotrebnost)";
  2735. this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
  2736. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2737. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2738. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@minplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minplosh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2739. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxplosh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2740. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@minetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minetazh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2741. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxetazh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2742. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@minkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minkomnat", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2743. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxkomnat", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2744. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@mincena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "mincena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2745. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@maxcena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxcena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2746. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2747. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpotrebnost", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpotrebnost", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2748. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2749. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2750. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_minplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minplosh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2751. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_minplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minplosh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2752. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxplosh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2753. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxplosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxplosh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2754. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_minetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minetazh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2755. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_minetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minetazh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2756. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxetazh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2757. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxetazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxetazh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2758. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_minkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minkomnat", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2759. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_minkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "minkomnat", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2760. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxkomnat", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2761. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxkomnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxkomnat", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2762. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_mincena", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "mincena", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2763. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_mincena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "mincena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2764. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_maxcena", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxcena", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2765. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_maxcena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "maxcena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2766. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_zaversheno", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  2767. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  2768. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idpotrebnost", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idpotrebnost", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  2769. }
  2770. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2771. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2772. private void InitConnection() {
  2773. this._connection = new global::System.Data.SqlClient.SqlConnection();
  2774. this._connection.ConnectionString = global::СУБД_Агентство.Properties.Settings.Default.DBAgentstvoConnectionString;
  2775. }
  2776. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2777. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2778. private void InitCommandCollection() {
  2779. this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
  2780. this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
  2781. this._commandCollection[0].Connection = this.Connection;
  2782. this._commandCollection[0].CommandText = "SELECT idpotrebnost, idklient, idrielter, minplosh, maxplosh, minetazh, maxetazh," +
  2783. " minkomnat, maxkomnat, mincena, maxcena, zaversheno FROM dbo.Potrebnost";
  2784. this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
  2785. }
  2786. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2787. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2788. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2789. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
  2790. public virtual int Fill(DBAgentstvoDataSet.PotrebnostDataTable dataTable) {
  2791. this.Adapter.SelectCommand = this.CommandCollection[0];
  2792. if ((this.ClearBeforeFill == true)) {
  2793. dataTable.Clear();
  2794. }
  2795. int returnValue = this.Adapter.Fill(dataTable);
  2796. return returnValue;
  2797. }
  2798. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2799. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2800. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2801. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
  2802. public virtual DBAgentstvoDataSet.PotrebnostDataTable GetData() {
  2803. this.Adapter.SelectCommand = this.CommandCollection[0];
  2804. DBAgentstvoDataSet.PotrebnostDataTable dataTable = new DBAgentstvoDataSet.PotrebnostDataTable();
  2805. this.Adapter.Fill(dataTable);
  2806. return dataTable;
  2807. }
  2808. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2809. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2810. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2811. public virtual int Update(DBAgentstvoDataSet.PotrebnostDataTable dataTable) {
  2812. return this.Adapter.Update(dataTable);
  2813. }
  2814. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2815. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2816. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2817. public virtual int Update(DBAgentstvoDataSet dataSet) {
  2818. return this.Adapter.Update(dataSet, "Potrebnost");
  2819. }
  2820. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2821. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2822. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2823. public virtual int Update(global::System.Data.DataRow dataRow) {
  2824. return this.Adapter.Update(new global::System.Data.DataRow[] {
  2825. dataRow});
  2826. }
  2827. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2828. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2829. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2830. public virtual int Update(global::System.Data.DataRow[] dataRows) {
  2831. return this.Adapter.Update(dataRows);
  2832. }
  2833. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2834. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2835. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2836. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
  2837. public virtual int Delete(int Original_idpotrebnost, int Original_idklient, int Original_idrielter, global::System.Nullable<int> Original_minplosh, global::System.Nullable<int> Original_maxplosh, global::System.Nullable<int> Original_minetazh, global::System.Nullable<int> Original_maxetazh, global::System.Nullable<int> Original_minkomnat, global::System.Nullable<int> Original_maxkomnat, global::System.Nullable<decimal> Original_mincena, global::System.Nullable<decimal> Original_maxcena, global::System.Nullable<bool> Original_zaversheno) {
  2838. this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_idpotrebnost));
  2839. this.Adapter.DeleteCommand.Parameters[1].Value = ((int)(Original_idklient));
  2840. this.Adapter.DeleteCommand.Parameters[2].Value = ((int)(Original_idrielter));
  2841. if ((Original_minplosh.HasValue == true)) {
  2842. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
  2843. this.Adapter.DeleteCommand.Parameters[4].Value = ((int)(Original_minplosh.Value));
  2844. }
  2845. else {
  2846. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
  2847. this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
  2848. }
  2849. if ((Original_maxplosh.HasValue == true)) {
  2850. this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(0));
  2851. this.Adapter.DeleteCommand.Parameters[6].Value = ((int)(Original_maxplosh.Value));
  2852. }
  2853. else {
  2854. this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(1));
  2855. this.Adapter.DeleteCommand.Parameters[6].Value = global::System.DBNull.Value;
  2856. }
  2857. if ((Original_minetazh.HasValue == true)) {
  2858. this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(0));
  2859. this.Adapter.DeleteCommand.Parameters[8].Value = ((int)(Original_minetazh.Value));
  2860. }
  2861. else {
  2862. this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(1));
  2863. this.Adapter.DeleteCommand.Parameters[8].Value = global::System.DBNull.Value;
  2864. }
  2865. if ((Original_maxetazh.HasValue == true)) {
  2866. this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(0));
  2867. this.Adapter.DeleteCommand.Parameters[10].Value = ((int)(Original_maxetazh.Value));
  2868. }
  2869. else {
  2870. this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(1));
  2871. this.Adapter.DeleteCommand.Parameters[10].Value = global::System.DBNull.Value;
  2872. }
  2873. if ((Original_minkomnat.HasValue == true)) {
  2874. this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(0));
  2875. this.Adapter.DeleteCommand.Parameters[12].Value = ((int)(Original_minkomnat.Value));
  2876. }
  2877. else {
  2878. this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(1));
  2879. this.Adapter.DeleteCommand.Parameters[12].Value = global::System.DBNull.Value;
  2880. }
  2881. if ((Original_maxkomnat.HasValue == true)) {
  2882. this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(0));
  2883. this.Adapter.DeleteCommand.Parameters[14].Value = ((int)(Original_maxkomnat.Value));
  2884. }
  2885. else {
  2886. this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(1));
  2887. this.Adapter.DeleteCommand.Parameters[14].Value = global::System.DBNull.Value;
  2888. }
  2889. if ((Original_mincena.HasValue == true)) {
  2890. this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(0));
  2891. this.Adapter.DeleteCommand.Parameters[16].Value = ((decimal)(Original_mincena.Value));
  2892. }
  2893. else {
  2894. this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(1));
  2895. this.Adapter.DeleteCommand.Parameters[16].Value = global::System.DBNull.Value;
  2896. }
  2897. if ((Original_maxcena.HasValue == true)) {
  2898. this.Adapter.DeleteCommand.Parameters[17].Value = ((object)(0));
  2899. this.Adapter.DeleteCommand.Parameters[18].Value = ((decimal)(Original_maxcena.Value));
  2900. }
  2901. else {
  2902. this.Adapter.DeleteCommand.Parameters[17].Value = ((object)(1));
  2903. this.Adapter.DeleteCommand.Parameters[18].Value = global::System.DBNull.Value;
  2904. }
  2905. if ((Original_zaversheno.HasValue == true)) {
  2906. this.Adapter.DeleteCommand.Parameters[19].Value = ((object)(0));
  2907. this.Adapter.DeleteCommand.Parameters[20].Value = ((bool)(Original_zaversheno.Value));
  2908. }
  2909. else {
  2910. this.Adapter.DeleteCommand.Parameters[19].Value = ((object)(1));
  2911. this.Adapter.DeleteCommand.Parameters[20].Value = global::System.DBNull.Value;
  2912. }
  2913. global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
  2914. if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
  2915. != global::System.Data.ConnectionState.Open)) {
  2916. this.Adapter.DeleteCommand.Connection.Open();
  2917. }
  2918. try {
  2919. int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
  2920. return returnValue;
  2921. }
  2922. finally {
  2923. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  2924. this.Adapter.DeleteCommand.Connection.Close();
  2925. }
  2926. }
  2927. }
  2928. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  2929. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  2930. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  2931. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
  2932. public virtual int Insert(int idklient, int idrielter, global::System.Nullable<int> minplosh, global::System.Nullable<int> maxplosh, global::System.Nullable<int> minetazh, global::System.Nullable<int> maxetazh, global::System.Nullable<int> minkomnat, global::System.Nullable<int> maxkomnat, global::System.Nullable<decimal> mincena, global::System.Nullable<decimal> maxcena, global::System.Nullable<bool> zaversheno) {
  2933. this.Adapter.InsertCommand.Parameters[0].Value = ((int)(idklient));
  2934. this.Adapter.InsertCommand.Parameters[1].Value = ((int)(idrielter));
  2935. if ((minplosh.HasValue == true)) {
  2936. this.Adapter.InsertCommand.Parameters[2].Value = ((int)(minplosh.Value));
  2937. }
  2938. else {
  2939. this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
  2940. }
  2941. if ((maxplosh.HasValue == true)) {
  2942. this.Adapter.InsertCommand.Parameters[3].Value = ((int)(maxplosh.Value));
  2943. }
  2944. else {
  2945. this.Adapter.InsertCommand.Parameters[3].Value = global::System.DBNull.Value;
  2946. }
  2947. if ((minetazh.HasValue == true)) {
  2948. this.Adapter.InsertCommand.Parameters[4].Value = ((int)(minetazh.Value));
  2949. }
  2950. else {
  2951. this.Adapter.InsertCommand.Parameters[4].Value = global::System.DBNull.Value;
  2952. }
  2953. if ((maxetazh.HasValue == true)) {
  2954. this.Adapter.InsertCommand.Parameters[5].Value = ((int)(maxetazh.Value));
  2955. }
  2956. else {
  2957. this.Adapter.InsertCommand.Parameters[5].Value = global::System.DBNull.Value;
  2958. }
  2959. if ((minkomnat.HasValue == true)) {
  2960. this.Adapter.InsertCommand.Parameters[6].Value = ((int)(minkomnat.Value));
  2961. }
  2962. else {
  2963. this.Adapter.InsertCommand.Parameters[6].Value = global::System.DBNull.Value;
  2964. }
  2965. if ((maxkomnat.HasValue == true)) {
  2966. this.Adapter.InsertCommand.Parameters[7].Value = ((int)(maxkomnat.Value));
  2967. }
  2968. else {
  2969. this.Adapter.InsertCommand.Parameters[7].Value = global::System.DBNull.Value;
  2970. }
  2971. if ((mincena.HasValue == true)) {
  2972. this.Adapter.InsertCommand.Parameters[8].Value = ((decimal)(mincena.Value));
  2973. }
  2974. else {
  2975. this.Adapter.InsertCommand.Parameters[8].Value = global::System.DBNull.Value;
  2976. }
  2977. if ((maxcena.HasValue == true)) {
  2978. this.Adapter.InsertCommand.Parameters[9].Value = ((decimal)(maxcena.Value));
  2979. }
  2980. else {
  2981. this.Adapter.InsertCommand.Parameters[9].Value = global::System.DBNull.Value;
  2982. }
  2983. if ((zaversheno.HasValue == true)) {
  2984. this.Adapter.InsertCommand.Parameters[10].Value = ((bool)(zaversheno.Value));
  2985. }
  2986. else {
  2987. this.Adapter.InsertCommand.Parameters[10].Value = global::System.DBNull.Value;
  2988. }
  2989. global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
  2990. if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
  2991. != global::System.Data.ConnectionState.Open)) {
  2992. this.Adapter.InsertCommand.Connection.Open();
  2993. }
  2994. try {
  2995. int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
  2996. return returnValue;
  2997. }
  2998. finally {
  2999. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  3000. this.Adapter.InsertCommand.Connection.Close();
  3001. }
  3002. }
  3003. }
  3004. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3005. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3006. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3007. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  3008. public virtual int Update(
  3009. int idklient,
  3010. int idrielter,
  3011. global::System.Nullable<int> minplosh,
  3012. global::System.Nullable<int> maxplosh,
  3013. global::System.Nullable<int> minetazh,
  3014. global::System.Nullable<int> maxetazh,
  3015. global::System.Nullable<int> minkomnat,
  3016. global::System.Nullable<int> maxkomnat,
  3017. global::System.Nullable<decimal> mincena,
  3018. global::System.Nullable<decimal> maxcena,
  3019. global::System.Nullable<bool> zaversheno,
  3020. int Original_idpotrebnost,
  3021. int Original_idklient,
  3022. int Original_idrielter,
  3023. global::System.Nullable<int> Original_minplosh,
  3024. global::System.Nullable<int> Original_maxplosh,
  3025. global::System.Nullable<int> Original_minetazh,
  3026. global::System.Nullable<int> Original_maxetazh,
  3027. global::System.Nullable<int> Original_minkomnat,
  3028. global::System.Nullable<int> Original_maxkomnat,
  3029. global::System.Nullable<decimal> Original_mincena,
  3030. global::System.Nullable<decimal> Original_maxcena,
  3031. global::System.Nullable<bool> Original_zaversheno,
  3032. int idpotrebnost) {
  3033. this.Adapter.UpdateCommand.Parameters[0].Value = ((int)(idklient));
  3034. this.Adapter.UpdateCommand.Parameters[1].Value = ((int)(idrielter));
  3035. if ((minplosh.HasValue == true)) {
  3036. this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(minplosh.Value));
  3037. }
  3038. else {
  3039. this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
  3040. }
  3041. if ((maxplosh.HasValue == true)) {
  3042. this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(maxplosh.Value));
  3043. }
  3044. else {
  3045. this.Adapter.UpdateCommand.Parameters[3].Value = global::System.DBNull.Value;
  3046. }
  3047. if ((minetazh.HasValue == true)) {
  3048. this.Adapter.UpdateCommand.Parameters[4].Value = ((int)(minetazh.Value));
  3049. }
  3050. else {
  3051. this.Adapter.UpdateCommand.Parameters[4].Value = global::System.DBNull.Value;
  3052. }
  3053. if ((maxetazh.HasValue == true)) {
  3054. this.Adapter.UpdateCommand.Parameters[5].Value = ((int)(maxetazh.Value));
  3055. }
  3056. else {
  3057. this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value;
  3058. }
  3059. if ((minkomnat.HasValue == true)) {
  3060. this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(minkomnat.Value));
  3061. }
  3062. else {
  3063. this.Adapter.UpdateCommand.Parameters[6].Value = global::System.DBNull.Value;
  3064. }
  3065. if ((maxkomnat.HasValue == true)) {
  3066. this.Adapter.UpdateCommand.Parameters[7].Value = ((int)(maxkomnat.Value));
  3067. }
  3068. else {
  3069. this.Adapter.UpdateCommand.Parameters[7].Value = global::System.DBNull.Value;
  3070. }
  3071. if ((mincena.HasValue == true)) {
  3072. this.Adapter.UpdateCommand.Parameters[8].Value = ((decimal)(mincena.Value));
  3073. }
  3074. else {
  3075. this.Adapter.UpdateCommand.Parameters[8].Value = global::System.DBNull.Value;
  3076. }
  3077. if ((maxcena.HasValue == true)) {
  3078. this.Adapter.UpdateCommand.Parameters[9].Value = ((decimal)(maxcena.Value));
  3079. }
  3080. else {
  3081. this.Adapter.UpdateCommand.Parameters[9].Value = global::System.DBNull.Value;
  3082. }
  3083. if ((zaversheno.HasValue == true)) {
  3084. this.Adapter.UpdateCommand.Parameters[10].Value = ((bool)(zaversheno.Value));
  3085. }
  3086. else {
  3087. this.Adapter.UpdateCommand.Parameters[10].Value = global::System.DBNull.Value;
  3088. }
  3089. this.Adapter.UpdateCommand.Parameters[11].Value = ((int)(Original_idpotrebnost));
  3090. this.Adapter.UpdateCommand.Parameters[12].Value = ((int)(Original_idklient));
  3091. this.Adapter.UpdateCommand.Parameters[13].Value = ((int)(Original_idrielter));
  3092. if ((Original_minplosh.HasValue == true)) {
  3093. this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(0));
  3094. this.Adapter.UpdateCommand.Parameters[15].Value = ((int)(Original_minplosh.Value));
  3095. }
  3096. else {
  3097. this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(1));
  3098. this.Adapter.UpdateCommand.Parameters[15].Value = global::System.DBNull.Value;
  3099. }
  3100. if ((Original_maxplosh.HasValue == true)) {
  3101. this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(0));
  3102. this.Adapter.UpdateCommand.Parameters[17].Value = ((int)(Original_maxplosh.Value));
  3103. }
  3104. else {
  3105. this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(1));
  3106. this.Adapter.UpdateCommand.Parameters[17].Value = global::System.DBNull.Value;
  3107. }
  3108. if ((Original_minetazh.HasValue == true)) {
  3109. this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(0));
  3110. this.Adapter.UpdateCommand.Parameters[19].Value = ((int)(Original_minetazh.Value));
  3111. }
  3112. else {
  3113. this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(1));
  3114. this.Adapter.UpdateCommand.Parameters[19].Value = global::System.DBNull.Value;
  3115. }
  3116. if ((Original_maxetazh.HasValue == true)) {
  3117. this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(0));
  3118. this.Adapter.UpdateCommand.Parameters[21].Value = ((int)(Original_maxetazh.Value));
  3119. }
  3120. else {
  3121. this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(1));
  3122. this.Adapter.UpdateCommand.Parameters[21].Value = global::System.DBNull.Value;
  3123. }
  3124. if ((Original_minkomnat.HasValue == true)) {
  3125. this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(0));
  3126. this.Adapter.UpdateCommand.Parameters[23].Value = ((int)(Original_minkomnat.Value));
  3127. }
  3128. else {
  3129. this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(1));
  3130. this.Adapter.UpdateCommand.Parameters[23].Value = global::System.DBNull.Value;
  3131. }
  3132. if ((Original_maxkomnat.HasValue == true)) {
  3133. this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(0));
  3134. this.Adapter.UpdateCommand.Parameters[25].Value = ((int)(Original_maxkomnat.Value));
  3135. }
  3136. else {
  3137. this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(1));
  3138. this.Adapter.UpdateCommand.Parameters[25].Value = global::System.DBNull.Value;
  3139. }
  3140. if ((Original_mincena.HasValue == true)) {
  3141. this.Adapter.UpdateCommand.Parameters[26].Value = ((object)(0));
  3142. this.Adapter.UpdateCommand.Parameters[27].Value = ((decimal)(Original_mincena.Value));
  3143. }
  3144. else {
  3145. this.Adapter.UpdateCommand.Parameters[26].Value = ((object)(1));
  3146. this.Adapter.UpdateCommand.Parameters[27].Value = global::System.DBNull.Value;
  3147. }
  3148. if ((Original_maxcena.HasValue == true)) {
  3149. this.Adapter.UpdateCommand.Parameters[28].Value = ((object)(0));
  3150. this.Adapter.UpdateCommand.Parameters[29].Value = ((decimal)(Original_maxcena.Value));
  3151. }
  3152. else {
  3153. this.Adapter.UpdateCommand.Parameters[28].Value = ((object)(1));
  3154. this.Adapter.UpdateCommand.Parameters[29].Value = global::System.DBNull.Value;
  3155. }
  3156. if ((Original_zaversheno.HasValue == true)) {
  3157. this.Adapter.UpdateCommand.Parameters[30].Value = ((object)(0));
  3158. this.Adapter.UpdateCommand.Parameters[31].Value = ((bool)(Original_zaversheno.Value));
  3159. }
  3160. else {
  3161. this.Adapter.UpdateCommand.Parameters[30].Value = ((object)(1));
  3162. this.Adapter.UpdateCommand.Parameters[31].Value = global::System.DBNull.Value;
  3163. }
  3164. this.Adapter.UpdateCommand.Parameters[32].Value = ((int)(idpotrebnost));
  3165. global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
  3166. if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
  3167. != global::System.Data.ConnectionState.Open)) {
  3168. this.Adapter.UpdateCommand.Connection.Open();
  3169. }
  3170. try {
  3171. int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
  3172. return returnValue;
  3173. }
  3174. finally {
  3175. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  3176. this.Adapter.UpdateCommand.Connection.Close();
  3177. }
  3178. }
  3179. }
  3180. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3181. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3182. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3183. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  3184. public virtual int Update(
  3185. int idklient,
  3186. int idrielter,
  3187. global::System.Nullable<int> minplosh,
  3188. global::System.Nullable<int> maxplosh,
  3189. global::System.Nullable<int> minetazh,
  3190. global::System.Nullable<int> maxetazh,
  3191. global::System.Nullable<int> minkomnat,
  3192. global::System.Nullable<int> maxkomnat,
  3193. global::System.Nullable<decimal> mincena,
  3194. global::System.Nullable<decimal> maxcena,
  3195. global::System.Nullable<bool> zaversheno,
  3196. int Original_idpotrebnost,
  3197. int Original_idklient,
  3198. int Original_idrielter,
  3199. global::System.Nullable<int> Original_minplosh,
  3200. global::System.Nullable<int> Original_maxplosh,
  3201. global::System.Nullable<int> Original_minetazh,
  3202. global::System.Nullable<int> Original_maxetazh,
  3203. global::System.Nullable<int> Original_minkomnat,
  3204. global::System.Nullable<int> Original_maxkomnat,
  3205. global::System.Nullable<decimal> Original_mincena,
  3206. global::System.Nullable<decimal> Original_maxcena,
  3207. global::System.Nullable<bool> Original_zaversheno) {
  3208. return this.Update(idklient, idrielter, minplosh, maxplosh, minetazh, maxetazh, minkomnat, maxkomnat, mincena, maxcena, zaversheno, Original_idpotrebnost, Original_idklient, Original_idrielter, Original_minplosh, Original_maxplosh, Original_minetazh, Original_maxetazh, Original_minkomnat, Original_maxkomnat, Original_mincena, Original_maxcena, Original_zaversheno, Original_idpotrebnost);
  3209. }
  3210. }
  3211. /// <summary>
  3212. ///Represents the connection and commands used to retrieve and save data.
  3213. ///</summary>
  3214. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  3215. [global::System.ComponentModel.ToolboxItem(true)]
  3216. [global::System.ComponentModel.DataObjectAttribute(true)]
  3217. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
  3218. ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  3219. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3220. public partial class predlozhenieTableAdapter : global::System.ComponentModel.Component {
  3221. private global::System.Data.SqlClient.SqlDataAdapter _adapter;
  3222. private global::System.Data.SqlClient.SqlConnection _connection;
  3223. private global::System.Data.SqlClient.SqlTransaction _transaction;
  3224. private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
  3225. private bool _clearBeforeFill;
  3226. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3227. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3228. public predlozhenieTableAdapter() {
  3229. this.ClearBeforeFill = true;
  3230. }
  3231. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3232. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3233. protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
  3234. get {
  3235. if ((this._adapter == null)) {
  3236. this.InitAdapter();
  3237. }
  3238. return this._adapter;
  3239. }
  3240. }
  3241. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3242. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3243. internal global::System.Data.SqlClient.SqlConnection Connection {
  3244. get {
  3245. if ((this._connection == null)) {
  3246. this.InitConnection();
  3247. }
  3248. return this._connection;
  3249. }
  3250. set {
  3251. this._connection = value;
  3252. if ((this.Adapter.InsertCommand != null)) {
  3253. this.Adapter.InsertCommand.Connection = value;
  3254. }
  3255. if ((this.Adapter.DeleteCommand != null)) {
  3256. this.Adapter.DeleteCommand.Connection = value;
  3257. }
  3258. if ((this.Adapter.UpdateCommand != null)) {
  3259. this.Adapter.UpdateCommand.Connection = value;
  3260. }
  3261. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  3262. if ((this.CommandCollection[i] != null)) {
  3263. ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
  3264. }
  3265. }
  3266. }
  3267. }
  3268. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3269. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3270. internal global::System.Data.SqlClient.SqlTransaction Transaction {
  3271. get {
  3272. return this._transaction;
  3273. }
  3274. set {
  3275. this._transaction = value;
  3276. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  3277. this.CommandCollection[i].Transaction = this._transaction;
  3278. }
  3279. if (((this.Adapter != null)
  3280. && (this.Adapter.DeleteCommand != null))) {
  3281. this.Adapter.DeleteCommand.Transaction = this._transaction;
  3282. }
  3283. if (((this.Adapter != null)
  3284. && (this.Adapter.InsertCommand != null))) {
  3285. this.Adapter.InsertCommand.Transaction = this._transaction;
  3286. }
  3287. if (((this.Adapter != null)
  3288. && (this.Adapter.UpdateCommand != null))) {
  3289. this.Adapter.UpdateCommand.Transaction = this._transaction;
  3290. }
  3291. }
  3292. }
  3293. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3294. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3295. protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
  3296. get {
  3297. if ((this._commandCollection == null)) {
  3298. this.InitCommandCollection();
  3299. }
  3300. return this._commandCollection;
  3301. }
  3302. }
  3303. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3304. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3305. public bool ClearBeforeFill {
  3306. get {
  3307. return this._clearBeforeFill;
  3308. }
  3309. set {
  3310. this._clearBeforeFill = value;
  3311. }
  3312. }
  3313. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3314. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3315. private void InitAdapter() {
  3316. this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
  3317. global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
  3318. tableMapping.SourceTable = "Table";
  3319. tableMapping.DataSetTable = "predlozhenie";
  3320. tableMapping.ColumnMappings.Add("idpredlozhenie", "idpredlozhenie");
  3321. tableMapping.ColumnMappings.Add("idklient", "idklient");
  3322. tableMapping.ColumnMappings.Add("idrielter", "idrielter");
  3323. tableMapping.ColumnMappings.Add("adres", "adres");
  3324. tableMapping.ColumnMappings.Add("plosh", "plosh");
  3325. tableMapping.ColumnMappings.Add("etazh", "etazh");
  3326. tableMapping.ColumnMappings.Add("komnat", "komnat");
  3327. tableMapping.ColumnMappings.Add("cena", "cena");
  3328. tableMapping.ColumnMappings.Add("zaversheno", "zaversheno");
  3329. this._adapter.TableMappings.Add(tableMapping);
  3330. this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
  3331. this._adapter.DeleteCommand.Connection = this.Connection;
  3332. this._adapter.DeleteCommand.CommandText = @"DELETE FROM [dbo].[predlozhenie] WHERE (([idpredlozhenie] = @Original_idpredlozhenie) AND ([idklient] = @Original_idklient) AND ([idrielter] = @Original_idrielter) AND ((@IsNull_adres = 1 AND [adres] IS NULL) OR ([adres] = @Original_adres)) AND ((@IsNull_plosh = 1 AND [plosh] IS NULL) OR ([plosh] = @Original_plosh)) AND ((@IsNull_etazh = 1 AND [etazh] IS NULL) OR ([etazh] = @Original_etazh)) AND ((@IsNull_komnat = 1 AND [komnat] IS NULL) OR ([komnat] = @Original_komnat)) AND ((@IsNull_cena = 1 AND [cena] IS NULL) OR ([cena] = @Original_cena)) AND ((@IsNull_zaversheno = 1 AND [zaversheno] IS NULL) OR ([zaversheno] = @Original_zaversheno)))";
  3333. this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
  3334. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpredlozhenie", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpredlozhenie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3335. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3336. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3337. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_adres", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "adres", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3338. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_adres", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "adres", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3339. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_plosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "plosh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3340. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_plosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "plosh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3341. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_etazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "etazh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3342. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_etazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "etazh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3343. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_komnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "komnat", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3344. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_komnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "komnat", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3345. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_cena", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cena", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3346. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3347. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_zaversheno", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3348. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3349. this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
  3350. this._adapter.InsertCommand.Connection = this.Connection;
  3351. this._adapter.InsertCommand.CommandText = @"INSERT INTO [dbo].[predlozhenie] ([idklient], [idrielter], [adres], [plosh], [etazh], [komnat], [cena], [zaversheno]) VALUES (@idklient, @idrielter, @adres, @plosh, @etazh, @komnat, @cena, @zaversheno);
  3352. SELECT idpredlozhenie, idklient, idrielter, adres, plosh, etazh, komnat, cena, zaversheno FROM predlozhenie WHERE (idpredlozhenie = SCOPE_IDENTITY())";
  3353. this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
  3354. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3355. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3356. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@adres", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "adres", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3357. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@plosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "plosh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3358. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@etazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "etazh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3359. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@komnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "komnat", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3360. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3361. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3362. this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
  3363. this._adapter.UpdateCommand.Connection = this.Connection;
  3364. this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[predlozhenie] SET [idklient] = @idklient, [idrielter] = @idrielter, [adres] = @adres, [plosh] = @plosh, [etazh] = @etazh, [komnat] = @komnat, [cena] = @cena, [zaversheno] = @zaversheno WHERE (([idpredlozhenie] = @Original_idpredlozhenie) AND ([idklient] = @Original_idklient) AND ([idrielter] = @Original_idrielter) AND ((@IsNull_adres = 1 AND [adres] IS NULL) OR ([adres] = @Original_adres)) AND ((@IsNull_plosh = 1 AND [plosh] IS NULL) OR ([plosh] = @Original_plosh)) AND ((@IsNull_etazh = 1 AND [etazh] IS NULL) OR ([etazh] = @Original_etazh)) AND ((@IsNull_komnat = 1 AND [komnat] IS NULL) OR ([komnat] = @Original_komnat)) AND ((@IsNull_cena = 1 AND [cena] IS NULL) OR ([cena] = @Original_cena)) AND ((@IsNull_zaversheno = 1 AND [zaversheno] IS NULL) OR ([zaversheno] = @Original_zaversheno)));
  3365. SELECT idpredlozhenie, idklient, idrielter, adres, plosh, etazh, komnat, cena, zaversheno FROM predlozhenie WHERE (idpredlozhenie = @idpredlozhenie)";
  3366. this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
  3367. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3368. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3369. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@adres", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "adres", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3370. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@plosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "plosh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3371. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@etazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "etazh", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3372. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@komnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "komnat", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3373. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cena", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3374. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3375. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpredlozhenie", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpredlozhenie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3376. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idklient", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idklient", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3377. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idrielter", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idrielter", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3378. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_adres", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "adres", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3379. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_adres", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "adres", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3380. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_plosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "plosh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3381. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_plosh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "plosh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3382. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_etazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "etazh", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3383. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_etazh", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "etazh", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3384. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_komnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "komnat", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3385. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_komnat", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "komnat", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3386. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_cena", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cena", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3387. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_cena", global::System.Data.SqlDbType.Money, 0, global::System.Data.ParameterDirection.Input, 0, 0, "cena", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3388. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_zaversheno", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3389. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_zaversheno", global::System.Data.SqlDbType.Bit, 0, global::System.Data.ParameterDirection.Input, 0, 0, "zaversheno", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3390. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idpredlozhenie", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idpredlozhenie", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3391. }
  3392. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3393. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3394. private void InitConnection() {
  3395. this._connection = new global::System.Data.SqlClient.SqlConnection();
  3396. this._connection.ConnectionString = global::СУБД_Агентство.Properties.Settings.Default.DBAgentstvoConnectionString;
  3397. }
  3398. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3399. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3400. private void InitCommandCollection() {
  3401. this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
  3402. this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
  3403. this._commandCollection[0].Connection = this.Connection;
  3404. this._commandCollection[0].CommandText = "SELECT idpredlozhenie, idklient, idrielter, adres, plosh, etazh, komnat, cena, za" +
  3405. "versheno FROM dbo.predlozhenie";
  3406. this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
  3407. }
  3408. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3409. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3410. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3411. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
  3412. public virtual int Fill(DBAgentstvoDataSet.predlozhenieDataTable dataTable) {
  3413. this.Adapter.SelectCommand = this.CommandCollection[0];
  3414. if ((this.ClearBeforeFill == true)) {
  3415. dataTable.Clear();
  3416. }
  3417. int returnValue = this.Adapter.Fill(dataTable);
  3418. return returnValue;
  3419. }
  3420. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3421. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3422. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3423. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
  3424. public virtual DBAgentstvoDataSet.predlozhenieDataTable GetData() {
  3425. this.Adapter.SelectCommand = this.CommandCollection[0];
  3426. DBAgentstvoDataSet.predlozhenieDataTable dataTable = new DBAgentstvoDataSet.predlozhenieDataTable();
  3427. this.Adapter.Fill(dataTable);
  3428. return dataTable;
  3429. }
  3430. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3431. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3432. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3433. public virtual int Update(DBAgentstvoDataSet.predlozhenieDataTable dataTable) {
  3434. return this.Adapter.Update(dataTable);
  3435. }
  3436. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3437. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3438. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3439. public virtual int Update(DBAgentstvoDataSet dataSet) {
  3440. return this.Adapter.Update(dataSet, "predlozhenie");
  3441. }
  3442. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3443. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3444. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3445. public virtual int Update(global::System.Data.DataRow dataRow) {
  3446. return this.Adapter.Update(new global::System.Data.DataRow[] {
  3447. dataRow});
  3448. }
  3449. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3450. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3451. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3452. public virtual int Update(global::System.Data.DataRow[] dataRows) {
  3453. return this.Adapter.Update(dataRows);
  3454. }
  3455. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3456. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3457. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3458. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
  3459. public virtual int Delete(int Original_idpredlozhenie, int Original_idklient, int Original_idrielter, string Original_adres, global::System.Nullable<int> Original_plosh, global::System.Nullable<int> Original_etazh, global::System.Nullable<int> Original_komnat, global::System.Nullable<decimal> Original_cena, global::System.Nullable<bool> Original_zaversheno) {
  3460. this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_idpredlozhenie));
  3461. this.Adapter.DeleteCommand.Parameters[1].Value = ((int)(Original_idklient));
  3462. this.Adapter.DeleteCommand.Parameters[2].Value = ((int)(Original_idrielter));
  3463. if ((Original_adres == null)) {
  3464. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
  3465. this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
  3466. }
  3467. else {
  3468. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
  3469. this.Adapter.DeleteCommand.Parameters[4].Value = ((string)(Original_adres));
  3470. }
  3471. if ((Original_plosh.HasValue == true)) {
  3472. this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(0));
  3473. this.Adapter.DeleteCommand.Parameters[6].Value = ((int)(Original_plosh.Value));
  3474. }
  3475. else {
  3476. this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(1));
  3477. this.Adapter.DeleteCommand.Parameters[6].Value = global::System.DBNull.Value;
  3478. }
  3479. if ((Original_etazh.HasValue == true)) {
  3480. this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(0));
  3481. this.Adapter.DeleteCommand.Parameters[8].Value = ((int)(Original_etazh.Value));
  3482. }
  3483. else {
  3484. this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(1));
  3485. this.Adapter.DeleteCommand.Parameters[8].Value = global::System.DBNull.Value;
  3486. }
  3487. if ((Original_komnat.HasValue == true)) {
  3488. this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(0));
  3489. this.Adapter.DeleteCommand.Parameters[10].Value = ((int)(Original_komnat.Value));
  3490. }
  3491. else {
  3492. this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(1));
  3493. this.Adapter.DeleteCommand.Parameters[10].Value = global::System.DBNull.Value;
  3494. }
  3495. if ((Original_cena.HasValue == true)) {
  3496. this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(0));
  3497. this.Adapter.DeleteCommand.Parameters[12].Value = ((decimal)(Original_cena.Value));
  3498. }
  3499. else {
  3500. this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(1));
  3501. this.Adapter.DeleteCommand.Parameters[12].Value = global::System.DBNull.Value;
  3502. }
  3503. if ((Original_zaversheno.HasValue == true)) {
  3504. this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(0));
  3505. this.Adapter.DeleteCommand.Parameters[14].Value = ((bool)(Original_zaversheno.Value));
  3506. }
  3507. else {
  3508. this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(1));
  3509. this.Adapter.DeleteCommand.Parameters[14].Value = global::System.DBNull.Value;
  3510. }
  3511. global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
  3512. if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
  3513. != global::System.Data.ConnectionState.Open)) {
  3514. this.Adapter.DeleteCommand.Connection.Open();
  3515. }
  3516. try {
  3517. int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
  3518. return returnValue;
  3519. }
  3520. finally {
  3521. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  3522. this.Adapter.DeleteCommand.Connection.Close();
  3523. }
  3524. }
  3525. }
  3526. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3527. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3528. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3529. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
  3530. public virtual int Insert(int idklient, int idrielter, string adres, global::System.Nullable<int> plosh, global::System.Nullable<int> etazh, global::System.Nullable<int> komnat, global::System.Nullable<decimal> cena, global::System.Nullable<bool> zaversheno) {
  3531. this.Adapter.InsertCommand.Parameters[0].Value = ((int)(idklient));
  3532. this.Adapter.InsertCommand.Parameters[1].Value = ((int)(idrielter));
  3533. if ((adres == null)) {
  3534. this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
  3535. }
  3536. else {
  3537. this.Adapter.InsertCommand.Parameters[2].Value = ((string)(adres));
  3538. }
  3539. if ((plosh.HasValue == true)) {
  3540. this.Adapter.InsertCommand.Parameters[3].Value = ((int)(plosh.Value));
  3541. }
  3542. else {
  3543. this.Adapter.InsertCommand.Parameters[3].Value = global::System.DBNull.Value;
  3544. }
  3545. if ((etazh.HasValue == true)) {
  3546. this.Adapter.InsertCommand.Parameters[4].Value = ((int)(etazh.Value));
  3547. }
  3548. else {
  3549. this.Adapter.InsertCommand.Parameters[4].Value = global::System.DBNull.Value;
  3550. }
  3551. if ((komnat.HasValue == true)) {
  3552. this.Adapter.InsertCommand.Parameters[5].Value = ((int)(komnat.Value));
  3553. }
  3554. else {
  3555. this.Adapter.InsertCommand.Parameters[5].Value = global::System.DBNull.Value;
  3556. }
  3557. if ((cena.HasValue == true)) {
  3558. this.Adapter.InsertCommand.Parameters[6].Value = ((decimal)(cena.Value));
  3559. }
  3560. else {
  3561. this.Adapter.InsertCommand.Parameters[6].Value = global::System.DBNull.Value;
  3562. }
  3563. if ((zaversheno.HasValue == true)) {
  3564. this.Adapter.InsertCommand.Parameters[7].Value = ((bool)(zaversheno.Value));
  3565. }
  3566. else {
  3567. this.Adapter.InsertCommand.Parameters[7].Value = global::System.DBNull.Value;
  3568. }
  3569. global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
  3570. if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
  3571. != global::System.Data.ConnectionState.Open)) {
  3572. this.Adapter.InsertCommand.Connection.Open();
  3573. }
  3574. try {
  3575. int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
  3576. return returnValue;
  3577. }
  3578. finally {
  3579. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  3580. this.Adapter.InsertCommand.Connection.Close();
  3581. }
  3582. }
  3583. }
  3584. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3585. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3586. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3587. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  3588. public virtual int Update(
  3589. int idklient,
  3590. int idrielter,
  3591. string adres,
  3592. global::System.Nullable<int> plosh,
  3593. global::System.Nullable<int> etazh,
  3594. global::System.Nullable<int> komnat,
  3595. global::System.Nullable<decimal> cena,
  3596. global::System.Nullable<bool> zaversheno,
  3597. int Original_idpredlozhenie,
  3598. int Original_idklient,
  3599. int Original_idrielter,
  3600. string Original_adres,
  3601. global::System.Nullable<int> Original_plosh,
  3602. global::System.Nullable<int> Original_etazh,
  3603. global::System.Nullable<int> Original_komnat,
  3604. global::System.Nullable<decimal> Original_cena,
  3605. global::System.Nullable<bool> Original_zaversheno,
  3606. int idpredlozhenie) {
  3607. this.Adapter.UpdateCommand.Parameters[0].Value = ((int)(idklient));
  3608. this.Adapter.UpdateCommand.Parameters[1].Value = ((int)(idrielter));
  3609. if ((adres == null)) {
  3610. this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
  3611. }
  3612. else {
  3613. this.Adapter.UpdateCommand.Parameters[2].Value = ((string)(adres));
  3614. }
  3615. if ((plosh.HasValue == true)) {
  3616. this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(plosh.Value));
  3617. }
  3618. else {
  3619. this.Adapter.UpdateCommand.Parameters[3].Value = global::System.DBNull.Value;
  3620. }
  3621. if ((etazh.HasValue == true)) {
  3622. this.Adapter.UpdateCommand.Parameters[4].Value = ((int)(etazh.Value));
  3623. }
  3624. else {
  3625. this.Adapter.UpdateCommand.Parameters[4].Value = global::System.DBNull.Value;
  3626. }
  3627. if ((komnat.HasValue == true)) {
  3628. this.Adapter.UpdateCommand.Parameters[5].Value = ((int)(komnat.Value));
  3629. }
  3630. else {
  3631. this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value;
  3632. }
  3633. if ((cena.HasValue == true)) {
  3634. this.Adapter.UpdateCommand.Parameters[6].Value = ((decimal)(cena.Value));
  3635. }
  3636. else {
  3637. this.Adapter.UpdateCommand.Parameters[6].Value = global::System.DBNull.Value;
  3638. }
  3639. if ((zaversheno.HasValue == true)) {
  3640. this.Adapter.UpdateCommand.Parameters[7].Value = ((bool)(zaversheno.Value));
  3641. }
  3642. else {
  3643. this.Adapter.UpdateCommand.Parameters[7].Value = global::System.DBNull.Value;
  3644. }
  3645. this.Adapter.UpdateCommand.Parameters[8].Value = ((int)(Original_idpredlozhenie));
  3646. this.Adapter.UpdateCommand.Parameters[9].Value = ((int)(Original_idklient));
  3647. this.Adapter.UpdateCommand.Parameters[10].Value = ((int)(Original_idrielter));
  3648. if ((Original_adres == null)) {
  3649. this.Adapter.UpdateCommand.Parameters[11].Value = ((object)(1));
  3650. this.Adapter.UpdateCommand.Parameters[12].Value = global::System.DBNull.Value;
  3651. }
  3652. else {
  3653. this.Adapter.UpdateCommand.Parameters[11].Value = ((object)(0));
  3654. this.Adapter.UpdateCommand.Parameters[12].Value = ((string)(Original_adres));
  3655. }
  3656. if ((Original_plosh.HasValue == true)) {
  3657. this.Adapter.UpdateCommand.Parameters[13].Value = ((object)(0));
  3658. this.Adapter.UpdateCommand.Parameters[14].Value = ((int)(Original_plosh.Value));
  3659. }
  3660. else {
  3661. this.Adapter.UpdateCommand.Parameters[13].Value = ((object)(1));
  3662. this.Adapter.UpdateCommand.Parameters[14].Value = global::System.DBNull.Value;
  3663. }
  3664. if ((Original_etazh.HasValue == true)) {
  3665. this.Adapter.UpdateCommand.Parameters[15].Value = ((object)(0));
  3666. this.Adapter.UpdateCommand.Parameters[16].Value = ((int)(Original_etazh.Value));
  3667. }
  3668. else {
  3669. this.Adapter.UpdateCommand.Parameters[15].Value = ((object)(1));
  3670. this.Adapter.UpdateCommand.Parameters[16].Value = global::System.DBNull.Value;
  3671. }
  3672. if ((Original_komnat.HasValue == true)) {
  3673. this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(0));
  3674. this.Adapter.UpdateCommand.Parameters[18].Value = ((int)(Original_komnat.Value));
  3675. }
  3676. else {
  3677. this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(1));
  3678. this.Adapter.UpdateCommand.Parameters[18].Value = global::System.DBNull.Value;
  3679. }
  3680. if ((Original_cena.HasValue == true)) {
  3681. this.Adapter.UpdateCommand.Parameters[19].Value = ((object)(0));
  3682. this.Adapter.UpdateCommand.Parameters[20].Value = ((decimal)(Original_cena.Value));
  3683. }
  3684. else {
  3685. this.Adapter.UpdateCommand.Parameters[19].Value = ((object)(1));
  3686. this.Adapter.UpdateCommand.Parameters[20].Value = global::System.DBNull.Value;
  3687. }
  3688. if ((Original_zaversheno.HasValue == true)) {
  3689. this.Adapter.UpdateCommand.Parameters[21].Value = ((object)(0));
  3690. this.Adapter.UpdateCommand.Parameters[22].Value = ((bool)(Original_zaversheno.Value));
  3691. }
  3692. else {
  3693. this.Adapter.UpdateCommand.Parameters[21].Value = ((object)(1));
  3694. this.Adapter.UpdateCommand.Parameters[22].Value = global::System.DBNull.Value;
  3695. }
  3696. this.Adapter.UpdateCommand.Parameters[23].Value = ((int)(idpredlozhenie));
  3697. global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
  3698. if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
  3699. != global::System.Data.ConnectionState.Open)) {
  3700. this.Adapter.UpdateCommand.Connection.Open();
  3701. }
  3702. try {
  3703. int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
  3704. return returnValue;
  3705. }
  3706. finally {
  3707. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  3708. this.Adapter.UpdateCommand.Connection.Close();
  3709. }
  3710. }
  3711. }
  3712. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3713. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3714. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3715. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  3716. public virtual int Update(
  3717. int idklient,
  3718. int idrielter,
  3719. string adres,
  3720. global::System.Nullable<int> plosh,
  3721. global::System.Nullable<int> etazh,
  3722. global::System.Nullable<int> komnat,
  3723. global::System.Nullable<decimal> cena,
  3724. global::System.Nullable<bool> zaversheno,
  3725. int Original_idpredlozhenie,
  3726. int Original_idklient,
  3727. int Original_idrielter,
  3728. string Original_adres,
  3729. global::System.Nullable<int> Original_plosh,
  3730. global::System.Nullable<int> Original_etazh,
  3731. global::System.Nullable<int> Original_komnat,
  3732. global::System.Nullable<decimal> Original_cena,
  3733. global::System.Nullable<bool> Original_zaversheno) {
  3734. return this.Update(idklient, idrielter, adres, plosh, etazh, komnat, cena, zaversheno, Original_idpredlozhenie, Original_idklient, Original_idrielter, Original_adres, Original_plosh, Original_etazh, Original_komnat, Original_cena, Original_zaversheno, Original_idpredlozhenie);
  3735. }
  3736. }
  3737. /// <summary>
  3738. ///Represents the connection and commands used to retrieve and save data.
  3739. ///</summary>
  3740. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  3741. [global::System.ComponentModel.ToolboxItem(true)]
  3742. [global::System.ComponentModel.DataObjectAttribute(true)]
  3743. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
  3744. ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  3745. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3746. public partial class SdelkaTableAdapter : global::System.ComponentModel.Component {
  3747. private global::System.Data.SqlClient.SqlDataAdapter _adapter;
  3748. private global::System.Data.SqlClient.SqlConnection _connection;
  3749. private global::System.Data.SqlClient.SqlTransaction _transaction;
  3750. private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
  3751. private bool _clearBeforeFill;
  3752. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3753. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3754. public SdelkaTableAdapter() {
  3755. this.ClearBeforeFill = true;
  3756. }
  3757. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3758. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3759. protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
  3760. get {
  3761. if ((this._adapter == null)) {
  3762. this.InitAdapter();
  3763. }
  3764. return this._adapter;
  3765. }
  3766. }
  3767. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3768. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3769. internal global::System.Data.SqlClient.SqlConnection Connection {
  3770. get {
  3771. if ((this._connection == null)) {
  3772. this.InitConnection();
  3773. }
  3774. return this._connection;
  3775. }
  3776. set {
  3777. this._connection = value;
  3778. if ((this.Adapter.InsertCommand != null)) {
  3779. this.Adapter.InsertCommand.Connection = value;
  3780. }
  3781. if ((this.Adapter.DeleteCommand != null)) {
  3782. this.Adapter.DeleteCommand.Connection = value;
  3783. }
  3784. if ((this.Adapter.UpdateCommand != null)) {
  3785. this.Adapter.UpdateCommand.Connection = value;
  3786. }
  3787. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  3788. if ((this.CommandCollection[i] != null)) {
  3789. ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
  3790. }
  3791. }
  3792. }
  3793. }
  3794. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3795. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3796. internal global::System.Data.SqlClient.SqlTransaction Transaction {
  3797. get {
  3798. return this._transaction;
  3799. }
  3800. set {
  3801. this._transaction = value;
  3802. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  3803. this.CommandCollection[i].Transaction = this._transaction;
  3804. }
  3805. if (((this.Adapter != null)
  3806. && (this.Adapter.DeleteCommand != null))) {
  3807. this.Adapter.DeleteCommand.Transaction = this._transaction;
  3808. }
  3809. if (((this.Adapter != null)
  3810. && (this.Adapter.InsertCommand != null))) {
  3811. this.Adapter.InsertCommand.Transaction = this._transaction;
  3812. }
  3813. if (((this.Adapter != null)
  3814. && (this.Adapter.UpdateCommand != null))) {
  3815. this.Adapter.UpdateCommand.Transaction = this._transaction;
  3816. }
  3817. }
  3818. }
  3819. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3820. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3821. protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
  3822. get {
  3823. if ((this._commandCollection == null)) {
  3824. this.InitCommandCollection();
  3825. }
  3826. return this._commandCollection;
  3827. }
  3828. }
  3829. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3830. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3831. public bool ClearBeforeFill {
  3832. get {
  3833. return this._clearBeforeFill;
  3834. }
  3835. set {
  3836. this._clearBeforeFill = value;
  3837. }
  3838. }
  3839. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3840. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3841. private void InitAdapter() {
  3842. this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
  3843. global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
  3844. tableMapping.SourceTable = "Table";
  3845. tableMapping.DataSetTable = "Sdelka";
  3846. tableMapping.ColumnMappings.Add("idsdelka", "idsdelka");
  3847. tableMapping.ColumnMappings.Add("idpotrebnost", "idpotrebnost");
  3848. tableMapping.ColumnMappings.Add("idpredlozhenie", "idpredlozhenie");
  3849. tableMapping.ColumnMappings.Add("datesdelka", "datesdelka");
  3850. this._adapter.TableMappings.Add(tableMapping);
  3851. this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
  3852. this._adapter.DeleteCommand.Connection = this.Connection;
  3853. this._adapter.DeleteCommand.CommandText = @"DELETE FROM [dbo].[Sdelka] WHERE (([idsdelka] = @Original_idsdelka) AND ([idpotrebnost] = @Original_idpotrebnost) AND ([idpredlozhenie] = @Original_idpredlozhenie) AND ((@IsNull_datesdelka = 1 AND [datesdelka] IS NULL) OR ([datesdelka] = @Original_datesdelka)))";
  3854. this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
  3855. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idsdelka", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idsdelka", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3856. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpotrebnost", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpotrebnost", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3857. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpredlozhenie", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpredlozhenie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3858. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_datesdelka", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "datesdelka", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3859. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_datesdelka", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "datesdelka", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3860. this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
  3861. this._adapter.InsertCommand.Connection = this.Connection;
  3862. this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[Sdelka] ([idpotrebnost], [idpredlozhenie], [datesdelka]) VALUE" +
  3863. "S (@idpotrebnost, @idpredlozhenie, @datesdelka);\r\nSELECT idsdelka, idpotrebnost," +
  3864. " idpredlozhenie, datesdelka FROM Sdelka WHERE (idsdelka = SCOPE_IDENTITY())";
  3865. this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
  3866. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idpotrebnost", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpotrebnost", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3867. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idpredlozhenie", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpredlozhenie", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3868. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@datesdelka", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "datesdelka", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3869. this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
  3870. this._adapter.UpdateCommand.Connection = this.Connection;
  3871. this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Sdelka] SET [idpotrebnost] = @idpotrebnost, [idpredlozhenie] = @idpredlozhenie, [datesdelka] = @datesdelka WHERE (([idsdelka] = @Original_idsdelka) AND ([idpotrebnost] = @Original_idpotrebnost) AND ([idpredlozhenie] = @Original_idpredlozhenie) AND ((@IsNull_datesdelka = 1 AND [datesdelka] IS NULL) OR ([datesdelka] = @Original_datesdelka)));
  3872. SELECT idsdelka, idpotrebnost, idpredlozhenie, datesdelka FROM Sdelka WHERE (idsdelka = @idsdelka)";
  3873. this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
  3874. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idpotrebnost", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpotrebnost", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3875. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idpredlozhenie", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpredlozhenie", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3876. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@datesdelka", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "datesdelka", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3877. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idsdelka", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idsdelka", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3878. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpotrebnost", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpotrebnost", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3879. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idpredlozhenie", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idpredlozhenie", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3880. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_datesdelka", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "datesdelka", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  3881. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_datesdelka", global::System.Data.SqlDbType.Date, 0, global::System.Data.ParameterDirection.Input, 0, 0, "datesdelka", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  3882. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idsdelka", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idsdelka", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  3883. }
  3884. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3885. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3886. private void InitConnection() {
  3887. this._connection = new global::System.Data.SqlClient.SqlConnection();
  3888. this._connection.ConnectionString = global::СУБД_Агентство.Properties.Settings.Default.DBAgentstvoConnectionString;
  3889. }
  3890. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3891. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3892. private void InitCommandCollection() {
  3893. this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
  3894. this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
  3895. this._commandCollection[0].Connection = this.Connection;
  3896. this._commandCollection[0].CommandText = "SELECT idsdelka, idpotrebnost, idpredlozhenie, datesdelka FROM dbo.Sdelka";
  3897. this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
  3898. }
  3899. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3900. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3901. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3902. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
  3903. public virtual int Fill(DBAgentstvoDataSet.SdelkaDataTable dataTable) {
  3904. this.Adapter.SelectCommand = this.CommandCollection[0];
  3905. if ((this.ClearBeforeFill == true)) {
  3906. dataTable.Clear();
  3907. }
  3908. int returnValue = this.Adapter.Fill(dataTable);
  3909. return returnValue;
  3910. }
  3911. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3912. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3913. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3914. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
  3915. public virtual DBAgentstvoDataSet.SdelkaDataTable GetData() {
  3916. this.Adapter.SelectCommand = this.CommandCollection[0];
  3917. DBAgentstvoDataSet.SdelkaDataTable dataTable = new DBAgentstvoDataSet.SdelkaDataTable();
  3918. this.Adapter.Fill(dataTable);
  3919. return dataTable;
  3920. }
  3921. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3922. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3923. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3924. public virtual int Update(DBAgentstvoDataSet.SdelkaDataTable dataTable) {
  3925. return this.Adapter.Update(dataTable);
  3926. }
  3927. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3928. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3929. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3930. public virtual int Update(DBAgentstvoDataSet dataSet) {
  3931. return this.Adapter.Update(dataSet, "Sdelka");
  3932. }
  3933. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3934. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3935. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3936. public virtual int Update(global::System.Data.DataRow dataRow) {
  3937. return this.Adapter.Update(new global::System.Data.DataRow[] {
  3938. dataRow});
  3939. }
  3940. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3941. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3942. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3943. public virtual int Update(global::System.Data.DataRow[] dataRows) {
  3944. return this.Adapter.Update(dataRows);
  3945. }
  3946. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3947. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3948. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3949. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
  3950. public virtual int Delete(int Original_idsdelka, int Original_idpotrebnost, int Original_idpredlozhenie, global::System.Nullable<global::System.DateTime> Original_datesdelka) {
  3951. this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_idsdelka));
  3952. this.Adapter.DeleteCommand.Parameters[1].Value = ((int)(Original_idpotrebnost));
  3953. this.Adapter.DeleteCommand.Parameters[2].Value = ((int)(Original_idpredlozhenie));
  3954. if ((Original_datesdelka.HasValue == true)) {
  3955. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
  3956. this.Adapter.DeleteCommand.Parameters[4].Value = ((System.DateTime)(Original_datesdelka.Value));
  3957. }
  3958. else {
  3959. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
  3960. this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
  3961. }
  3962. global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
  3963. if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
  3964. != global::System.Data.ConnectionState.Open)) {
  3965. this.Adapter.DeleteCommand.Connection.Open();
  3966. }
  3967. try {
  3968. int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
  3969. return returnValue;
  3970. }
  3971. finally {
  3972. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  3973. this.Adapter.DeleteCommand.Connection.Close();
  3974. }
  3975. }
  3976. }
  3977. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  3978. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  3979. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  3980. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
  3981. public virtual int Insert(int idpotrebnost, int idpredlozhenie, global::System.Nullable<global::System.DateTime> datesdelka) {
  3982. this.Adapter.InsertCommand.Parameters[0].Value = ((int)(idpotrebnost));
  3983. this.Adapter.InsertCommand.Parameters[1].Value = ((int)(idpredlozhenie));
  3984. if ((datesdelka.HasValue == true)) {
  3985. this.Adapter.InsertCommand.Parameters[2].Value = ((System.DateTime)(datesdelka.Value));
  3986. }
  3987. else {
  3988. this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
  3989. }
  3990. global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
  3991. if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
  3992. != global::System.Data.ConnectionState.Open)) {
  3993. this.Adapter.InsertCommand.Connection.Open();
  3994. }
  3995. try {
  3996. int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
  3997. return returnValue;
  3998. }
  3999. finally {
  4000. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  4001. this.Adapter.InsertCommand.Connection.Close();
  4002. }
  4003. }
  4004. }
  4005. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4006. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4007. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4008. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  4009. public virtual int Update(int idpotrebnost, int idpredlozhenie, global::System.Nullable<global::System.DateTime> datesdelka, int Original_idsdelka, int Original_idpotrebnost, int Original_idpredlozhenie, global::System.Nullable<global::System.DateTime> Original_datesdelka, int idsdelka) {
  4010. this.Adapter.UpdateCommand.Parameters[0].Value = ((int)(idpotrebnost));
  4011. this.Adapter.UpdateCommand.Parameters[1].Value = ((int)(idpredlozhenie));
  4012. if ((datesdelka.HasValue == true)) {
  4013. this.Adapter.UpdateCommand.Parameters[2].Value = ((System.DateTime)(datesdelka.Value));
  4014. }
  4015. else {
  4016. this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
  4017. }
  4018. this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_idsdelka));
  4019. this.Adapter.UpdateCommand.Parameters[4].Value = ((int)(Original_idpotrebnost));
  4020. this.Adapter.UpdateCommand.Parameters[5].Value = ((int)(Original_idpredlozhenie));
  4021. if ((Original_datesdelka.HasValue == true)) {
  4022. this.Adapter.UpdateCommand.Parameters[6].Value = ((object)(0));
  4023. this.Adapter.UpdateCommand.Parameters[7].Value = ((System.DateTime)(Original_datesdelka.Value));
  4024. }
  4025. else {
  4026. this.Adapter.UpdateCommand.Parameters[6].Value = ((object)(1));
  4027. this.Adapter.UpdateCommand.Parameters[7].Value = global::System.DBNull.Value;
  4028. }
  4029. this.Adapter.UpdateCommand.Parameters[8].Value = ((int)(idsdelka));
  4030. global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
  4031. if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
  4032. != global::System.Data.ConnectionState.Open)) {
  4033. this.Adapter.UpdateCommand.Connection.Open();
  4034. }
  4035. try {
  4036. int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
  4037. return returnValue;
  4038. }
  4039. finally {
  4040. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  4041. this.Adapter.UpdateCommand.Connection.Close();
  4042. }
  4043. }
  4044. }
  4045. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4046. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4047. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4048. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  4049. public virtual int Update(int idpotrebnost, int idpredlozhenie, global::System.Nullable<global::System.DateTime> datesdelka, int Original_idsdelka, int Original_idpotrebnost, int Original_idpredlozhenie, global::System.Nullable<global::System.DateTime> Original_datesdelka) {
  4050. return this.Update(idpotrebnost, idpredlozhenie, datesdelka, Original_idsdelka, Original_idpotrebnost, Original_idpredlozhenie, Original_datesdelka, Original_idsdelka);
  4051. }
  4052. }
  4053. /// <summary>
  4054. ///Represents the connection and commands used to retrieve and save data.
  4055. ///</summary>
  4056. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  4057. [global::System.ComponentModel.ToolboxItem(true)]
  4058. [global::System.ComponentModel.DataObjectAttribute(true)]
  4059. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
  4060. ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  4061. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4062. public partial class UsersTableAdapter : global::System.ComponentModel.Component {
  4063. private global::System.Data.SqlClient.SqlDataAdapter _adapter;
  4064. private global::System.Data.SqlClient.SqlConnection _connection;
  4065. private global::System.Data.SqlClient.SqlTransaction _transaction;
  4066. private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
  4067. private bool _clearBeforeFill;
  4068. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4069. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4070. public UsersTableAdapter() {
  4071. this.ClearBeforeFill = true;
  4072. }
  4073. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4074. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4075. protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
  4076. get {
  4077. if ((this._adapter == null)) {
  4078. this.InitAdapter();
  4079. }
  4080. return this._adapter;
  4081. }
  4082. }
  4083. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4084. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4085. internal global::System.Data.SqlClient.SqlConnection Connection {
  4086. get {
  4087. if ((this._connection == null)) {
  4088. this.InitConnection();
  4089. }
  4090. return this._connection;
  4091. }
  4092. set {
  4093. this._connection = value;
  4094. if ((this.Adapter.InsertCommand != null)) {
  4095. this.Adapter.InsertCommand.Connection = value;
  4096. }
  4097. if ((this.Adapter.DeleteCommand != null)) {
  4098. this.Adapter.DeleteCommand.Connection = value;
  4099. }
  4100. if ((this.Adapter.UpdateCommand != null)) {
  4101. this.Adapter.UpdateCommand.Connection = value;
  4102. }
  4103. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  4104. if ((this.CommandCollection[i] != null)) {
  4105. ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
  4106. }
  4107. }
  4108. }
  4109. }
  4110. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4111. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4112. internal global::System.Data.SqlClient.SqlTransaction Transaction {
  4113. get {
  4114. return this._transaction;
  4115. }
  4116. set {
  4117. this._transaction = value;
  4118. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  4119. this.CommandCollection[i].Transaction = this._transaction;
  4120. }
  4121. if (((this.Adapter != null)
  4122. && (this.Adapter.DeleteCommand != null))) {
  4123. this.Adapter.DeleteCommand.Transaction = this._transaction;
  4124. }
  4125. if (((this.Adapter != null)
  4126. && (this.Adapter.InsertCommand != null))) {
  4127. this.Adapter.InsertCommand.Transaction = this._transaction;
  4128. }
  4129. if (((this.Adapter != null)
  4130. && (this.Adapter.UpdateCommand != null))) {
  4131. this.Adapter.UpdateCommand.Transaction = this._transaction;
  4132. }
  4133. }
  4134. }
  4135. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4136. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4137. protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
  4138. get {
  4139. if ((this._commandCollection == null)) {
  4140. this.InitCommandCollection();
  4141. }
  4142. return this._commandCollection;
  4143. }
  4144. }
  4145. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4146. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4147. public bool ClearBeforeFill {
  4148. get {
  4149. return this._clearBeforeFill;
  4150. }
  4151. set {
  4152. this._clearBeforeFill = value;
  4153. }
  4154. }
  4155. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4156. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4157. private void InitAdapter() {
  4158. this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
  4159. global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
  4160. tableMapping.SourceTable = "Table";
  4161. tableMapping.DataSetTable = "Users";
  4162. tableMapping.ColumnMappings.Add("idusers", "idusers");
  4163. tableMapping.ColumnMappings.Add("fam", "fam");
  4164. tableMapping.ColumnMappings.Add("name", "name");
  4165. tableMapping.ColumnMappings.Add("login", "login");
  4166. tableMapping.ColumnMappings.Add("password", "password");
  4167. tableMapping.ColumnMappings.Add("type", "type");
  4168. tableMapping.ColumnMappings.Add("photo", "photo");
  4169. this._adapter.TableMappings.Add(tableMapping);
  4170. this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
  4171. this._adapter.DeleteCommand.Connection = this.Connection;
  4172. this._adapter.DeleteCommand.CommandText = @"DELETE FROM [dbo].[Users] WHERE (([idusers] = @Original_idusers) AND ((@IsNull_fam = 1 AND [fam] IS NULL) OR ([fam] = @Original_fam)) AND ((@IsNull_name = 1 AND [name] IS NULL) OR ([name] = @Original_name)) AND ([login] = @Original_login) AND ([password] = @Original_password) AND ([type] = @Original_type))";
  4173. this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
  4174. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idusers", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idusers", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4175. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_fam", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "fam", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  4176. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_fam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "fam", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4177. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_name", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "name", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  4178. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_name", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "name", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4179. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_login", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "login", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4180. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_password", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "password", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4181. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_type", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "type", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4182. this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
  4183. this._adapter.InsertCommand.Connection = this.Connection;
  4184. this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[Users] ([fam], [name], [login], [password], [type], [photo]) V" +
  4185. "ALUES (@fam, @name, @login, @password, @type, @photo);\r\nSELECT idusers, fam, nam" +
  4186. "e, login, password, type, photo FROM Users WHERE (idusers = SCOPE_IDENTITY())";
  4187. this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
  4188. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@fam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "fam", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4189. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@name", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "name", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4190. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@login", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "login", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4191. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@password", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "password", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4192. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@type", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "type", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4193. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@photo", global::System.Data.SqlDbType.VarBinary, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4194. this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
  4195. this._adapter.UpdateCommand.Connection = this.Connection;
  4196. this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Users] SET [fam] = @fam, [name] = @name, [login] = @login, [password] = @password, [type] = @type, [photo] = @photo WHERE (([idusers] = @Original_idusers) AND ((@IsNull_fam = 1 AND [fam] IS NULL) OR ([fam] = @Original_fam)) AND ((@IsNull_name = 1 AND [name] IS NULL) OR ([name] = @Original_name)) AND ([login] = @Original_login) AND ([password] = @Original_password) AND ([type] = @Original_type));
  4197. SELECT idusers, fam, name, login, password, type, photo FROM Users WHERE (idusers = @idusers)";
  4198. this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
  4199. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@fam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "fam", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4200. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@name", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "name", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4201. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@login", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "login", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4202. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@password", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "password", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4203. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@type", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "type", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4204. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@photo", global::System.Data.SqlDbType.VarBinary, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4205. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idusers", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idusers", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4206. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_fam", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "fam", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  4207. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_fam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "fam", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4208. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_name", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "name", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  4209. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_name", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "name", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4210. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_login", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "login", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4211. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_password", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "password", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4212. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_type", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "type", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  4213. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idusers", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idusers", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  4214. }
  4215. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4216. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4217. private void InitConnection() {
  4218. this._connection = new global::System.Data.SqlClient.SqlConnection();
  4219. this._connection.ConnectionString = global::СУБД_Агентство.Properties.Settings.Default.DBAgentstvoConnectionString;
  4220. }
  4221. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4222. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4223. private void InitCommandCollection() {
  4224. this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
  4225. this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
  4226. this._commandCollection[0].Connection = this.Connection;
  4227. this._commandCollection[0].CommandText = "SELECT idusers, fam, name, login, password, type, photo FROM dbo.Users";
  4228. this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
  4229. }
  4230. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4231. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4232. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4233. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
  4234. public virtual int Fill(DBAgentstvoDataSet.UsersDataTable dataTable) {
  4235. this.Adapter.SelectCommand = this.CommandCollection[0];
  4236. if ((this.ClearBeforeFill == true)) {
  4237. dataTable.Clear();
  4238. }
  4239. int returnValue = this.Adapter.Fill(dataTable);
  4240. return returnValue;
  4241. }
  4242. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4243. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4244. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4245. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
  4246. public virtual DBAgentstvoDataSet.UsersDataTable GetData() {
  4247. this.Adapter.SelectCommand = this.CommandCollection[0];
  4248. DBAgentstvoDataSet.UsersDataTable dataTable = new DBAgentstvoDataSet.UsersDataTable();
  4249. this.Adapter.Fill(dataTable);
  4250. return dataTable;
  4251. }
  4252. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4253. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4254. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4255. public virtual int Update(DBAgentstvoDataSet.UsersDataTable dataTable) {
  4256. return this.Adapter.Update(dataTable);
  4257. }
  4258. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4259. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4260. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4261. public virtual int Update(DBAgentstvoDataSet dataSet) {
  4262. return this.Adapter.Update(dataSet, "Users");
  4263. }
  4264. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4265. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4266. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4267. public virtual int Update(global::System.Data.DataRow dataRow) {
  4268. return this.Adapter.Update(new global::System.Data.DataRow[] {
  4269. dataRow});
  4270. }
  4271. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4272. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4273. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4274. public virtual int Update(global::System.Data.DataRow[] dataRows) {
  4275. return this.Adapter.Update(dataRows);
  4276. }
  4277. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4278. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4279. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4280. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
  4281. public virtual int Delete(int Original_idusers, string Original_fam, string Original_name, string Original_login, string Original_password, string Original_type) {
  4282. this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_idusers));
  4283. if ((Original_fam == null)) {
  4284. this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(1));
  4285. this.Adapter.DeleteCommand.Parameters[2].Value = global::System.DBNull.Value;
  4286. }
  4287. else {
  4288. this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(0));
  4289. this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_fam));
  4290. }
  4291. if ((Original_name == null)) {
  4292. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
  4293. this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
  4294. }
  4295. else {
  4296. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
  4297. this.Adapter.DeleteCommand.Parameters[4].Value = ((string)(Original_name));
  4298. }
  4299. if ((Original_login == null)) {
  4300. throw new global::System.ArgumentNullException("Original_login");
  4301. }
  4302. else {
  4303. this.Adapter.DeleteCommand.Parameters[5].Value = ((string)(Original_login));
  4304. }
  4305. if ((Original_password == null)) {
  4306. throw new global::System.ArgumentNullException("Original_password");
  4307. }
  4308. else {
  4309. this.Adapter.DeleteCommand.Parameters[6].Value = ((string)(Original_password));
  4310. }
  4311. if ((Original_type == null)) {
  4312. throw new global::System.ArgumentNullException("Original_type");
  4313. }
  4314. else {
  4315. this.Adapter.DeleteCommand.Parameters[7].Value = ((string)(Original_type));
  4316. }
  4317. global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
  4318. if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
  4319. != global::System.Data.ConnectionState.Open)) {
  4320. this.Adapter.DeleteCommand.Connection.Open();
  4321. }
  4322. try {
  4323. int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
  4324. return returnValue;
  4325. }
  4326. finally {
  4327. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  4328. this.Adapter.DeleteCommand.Connection.Close();
  4329. }
  4330. }
  4331. }
  4332. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4333. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4334. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4335. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
  4336. public virtual int Insert(string fam, string name, string login, string password, string type, byte[] photo) {
  4337. if ((fam == null)) {
  4338. this.Adapter.InsertCommand.Parameters[0].Value = global::System.DBNull.Value;
  4339. }
  4340. else {
  4341. this.Adapter.InsertCommand.Parameters[0].Value = ((string)(fam));
  4342. }
  4343. if ((name == null)) {
  4344. this.Adapter.InsertCommand.Parameters[1].Value = global::System.DBNull.Value;
  4345. }
  4346. else {
  4347. this.Adapter.InsertCommand.Parameters[1].Value = ((string)(name));
  4348. }
  4349. if ((login == null)) {
  4350. throw new global::System.ArgumentNullException("login");
  4351. }
  4352. else {
  4353. this.Adapter.InsertCommand.Parameters[2].Value = ((string)(login));
  4354. }
  4355. if ((password == null)) {
  4356. throw new global::System.ArgumentNullException("password");
  4357. }
  4358. else {
  4359. this.Adapter.InsertCommand.Parameters[3].Value = ((string)(password));
  4360. }
  4361. if ((type == null)) {
  4362. throw new global::System.ArgumentNullException("type");
  4363. }
  4364. else {
  4365. this.Adapter.InsertCommand.Parameters[4].Value = ((string)(type));
  4366. }
  4367. if ((photo == null)) {
  4368. this.Adapter.InsertCommand.Parameters[5].Value = global::System.DBNull.Value;
  4369. }
  4370. else {
  4371. this.Adapter.InsertCommand.Parameters[5].Value = ((byte[])(photo));
  4372. }
  4373. global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
  4374. if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
  4375. != global::System.Data.ConnectionState.Open)) {
  4376. this.Adapter.InsertCommand.Connection.Open();
  4377. }
  4378. try {
  4379. int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
  4380. return returnValue;
  4381. }
  4382. finally {
  4383. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  4384. this.Adapter.InsertCommand.Connection.Close();
  4385. }
  4386. }
  4387. }
  4388. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4389. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4390. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4391. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  4392. public virtual int Update(string fam, string name, string login, string password, string type, byte[] photo, int Original_idusers, string Original_fam, string Original_name, string Original_login, string Original_password, string Original_type, int idusers) {
  4393. if ((fam == null)) {
  4394. this.Adapter.UpdateCommand.Parameters[0].Value = global::System.DBNull.Value;
  4395. }
  4396. else {
  4397. this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(fam));
  4398. }
  4399. if ((name == null)) {
  4400. this.Adapter.UpdateCommand.Parameters[1].Value = global::System.DBNull.Value;
  4401. }
  4402. else {
  4403. this.Adapter.UpdateCommand.Parameters[1].Value = ((string)(name));
  4404. }
  4405. if ((login == null)) {
  4406. throw new global::System.ArgumentNullException("login");
  4407. }
  4408. else {
  4409. this.Adapter.UpdateCommand.Parameters[2].Value = ((string)(login));
  4410. }
  4411. if ((password == null)) {
  4412. throw new global::System.ArgumentNullException("password");
  4413. }
  4414. else {
  4415. this.Adapter.UpdateCommand.Parameters[3].Value = ((string)(password));
  4416. }
  4417. if ((type == null)) {
  4418. throw new global::System.ArgumentNullException("type");
  4419. }
  4420. else {
  4421. this.Adapter.UpdateCommand.Parameters[4].Value = ((string)(type));
  4422. }
  4423. if ((photo == null)) {
  4424. this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value;
  4425. }
  4426. else {
  4427. this.Adapter.UpdateCommand.Parameters[5].Value = ((byte[])(photo));
  4428. }
  4429. this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(Original_idusers));
  4430. if ((Original_fam == null)) {
  4431. this.Adapter.UpdateCommand.Parameters[7].Value = ((object)(1));
  4432. this.Adapter.UpdateCommand.Parameters[8].Value = global::System.DBNull.Value;
  4433. }
  4434. else {
  4435. this.Adapter.UpdateCommand.Parameters[7].Value = ((object)(0));
  4436. this.Adapter.UpdateCommand.Parameters[8].Value = ((string)(Original_fam));
  4437. }
  4438. if ((Original_name == null)) {
  4439. this.Adapter.UpdateCommand.Parameters[9].Value = ((object)(1));
  4440. this.Adapter.UpdateCommand.Parameters[10].Value = global::System.DBNull.Value;
  4441. }
  4442. else {
  4443. this.Adapter.UpdateCommand.Parameters[9].Value = ((object)(0));
  4444. this.Adapter.UpdateCommand.Parameters[10].Value = ((string)(Original_name));
  4445. }
  4446. if ((Original_login == null)) {
  4447. throw new global::System.ArgumentNullException("Original_login");
  4448. }
  4449. else {
  4450. this.Adapter.UpdateCommand.Parameters[11].Value = ((string)(Original_login));
  4451. }
  4452. if ((Original_password == null)) {
  4453. throw new global::System.ArgumentNullException("Original_password");
  4454. }
  4455. else {
  4456. this.Adapter.UpdateCommand.Parameters[12].Value = ((string)(Original_password));
  4457. }
  4458. if ((Original_type == null)) {
  4459. throw new global::System.ArgumentNullException("Original_type");
  4460. }
  4461. else {
  4462. this.Adapter.UpdateCommand.Parameters[13].Value = ((string)(Original_type));
  4463. }
  4464. this.Adapter.UpdateCommand.Parameters[14].Value = ((int)(idusers));
  4465. global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
  4466. if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
  4467. != global::System.Data.ConnectionState.Open)) {
  4468. this.Adapter.UpdateCommand.Connection.Open();
  4469. }
  4470. try {
  4471. int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
  4472. return returnValue;
  4473. }
  4474. finally {
  4475. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  4476. this.Adapter.UpdateCommand.Connection.Close();
  4477. }
  4478. }
  4479. }
  4480. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4481. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4482. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  4483. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  4484. public virtual int Update(string fam, string name, string login, string password, string type, byte[] photo, int Original_idusers, string Original_fam, string Original_name, string Original_login, string Original_password, string Original_type) {
  4485. return this.Update(fam, name, login, password, type, photo, Original_idusers, Original_fam, Original_name, Original_login, Original_password, Original_type, Original_idusers);
  4486. }
  4487. }
  4488. /// <summary>
  4489. ///TableAdapterManager is used to coordinate TableAdapters in the dataset to enable Hierarchical Update scenarios
  4490. ///</summary>
  4491. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  4492. [global::System.ComponentModel.ToolboxItem(true)]
  4493. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerDesigner, Microsoft.VSD" +
  4494. "esigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  4495. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapterManager")]
  4496. public partial class TableAdapterManager : global::System.ComponentModel.Component {
  4497. private UpdateOrderOption _updateOrder;
  4498. private PotrebnostTableAdapter _potrebnostTableAdapter;
  4499. private predlozhenieTableAdapter _predlozhenieTableAdapter;
  4500. private SdelkaTableAdapter _sdelkaTableAdapter;
  4501. private UsersTableAdapter _usersTableAdapter;
  4502. private bool _backupDataSetBeforeUpdate;
  4503. private global::System.Data.IDbConnection _connection;
  4504. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4505. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4506. public UpdateOrderOption UpdateOrder {
  4507. get {
  4508. return this._updateOrder;
  4509. }
  4510. set {
  4511. this._updateOrder = value;
  4512. }
  4513. }
  4514. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4515. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4516. [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
  4517. "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
  4518. "a", "System.Drawing.Design.UITypeEditor")]
  4519. public PotrebnostTableAdapter PotrebnostTableAdapter {
  4520. get {
  4521. return this._potrebnostTableAdapter;
  4522. }
  4523. set {
  4524. this._potrebnostTableAdapter = value;
  4525. }
  4526. }
  4527. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4528. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4529. [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
  4530. "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
  4531. "a", "System.Drawing.Design.UITypeEditor")]
  4532. public predlozhenieTableAdapter predlozhenieTableAdapter {
  4533. get {
  4534. return this._predlozhenieTableAdapter;
  4535. }
  4536. set {
  4537. this._predlozhenieTableAdapter = value;
  4538. }
  4539. }
  4540. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4541. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4542. [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
  4543. "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
  4544. "a", "System.Drawing.Design.UITypeEditor")]
  4545. public SdelkaTableAdapter SdelkaTableAdapter {
  4546. get {
  4547. return this._sdelkaTableAdapter;
  4548. }
  4549. set {
  4550. this._sdelkaTableAdapter = value;
  4551. }
  4552. }
  4553. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4554. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4555. [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
  4556. "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
  4557. "a", "System.Drawing.Design.UITypeEditor")]
  4558. public UsersTableAdapter UsersTableAdapter {
  4559. get {
  4560. return this._usersTableAdapter;
  4561. }
  4562. set {
  4563. this._usersTableAdapter = value;
  4564. }
  4565. }
  4566. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4567. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4568. public bool BackupDataSetBeforeUpdate {
  4569. get {
  4570. return this._backupDataSetBeforeUpdate;
  4571. }
  4572. set {
  4573. this._backupDataSetBeforeUpdate = value;
  4574. }
  4575. }
  4576. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4577. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4578. [global::System.ComponentModel.Browsable(false)]
  4579. public global::System.Data.IDbConnection Connection {
  4580. get {
  4581. if ((this._connection != null)) {
  4582. return this._connection;
  4583. }
  4584. if (((this._potrebnostTableAdapter != null)
  4585. && (this._potrebnostTableAdapter.Connection != null))) {
  4586. return this._potrebnostTableAdapter.Connection;
  4587. }
  4588. if (((this._predlozhenieTableAdapter != null)
  4589. && (this._predlozhenieTableAdapter.Connection != null))) {
  4590. return this._predlozhenieTableAdapter.Connection;
  4591. }
  4592. if (((this._sdelkaTableAdapter != null)
  4593. && (this._sdelkaTableAdapter.Connection != null))) {
  4594. return this._sdelkaTableAdapter.Connection;
  4595. }
  4596. if (((this._usersTableAdapter != null)
  4597. && (this._usersTableAdapter.Connection != null))) {
  4598. return this._usersTableAdapter.Connection;
  4599. }
  4600. return null;
  4601. }
  4602. set {
  4603. this._connection = value;
  4604. }
  4605. }
  4606. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4607. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4608. [global::System.ComponentModel.Browsable(false)]
  4609. public int TableAdapterInstanceCount {
  4610. get {
  4611. int count = 0;
  4612. if ((this._potrebnostTableAdapter != null)) {
  4613. count = (count + 1);
  4614. }
  4615. if ((this._predlozhenieTableAdapter != null)) {
  4616. count = (count + 1);
  4617. }
  4618. if ((this._sdelkaTableAdapter != null)) {
  4619. count = (count + 1);
  4620. }
  4621. if ((this._usersTableAdapter != null)) {
  4622. count = (count + 1);
  4623. }
  4624. return count;
  4625. }
  4626. }
  4627. /// <summary>
  4628. ///Update rows in top-down order.
  4629. ///</summary>
  4630. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4631. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4632. private int UpdateUpdatedRows(DBAgentstvoDataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  4633. int result = 0;
  4634. if ((this._usersTableAdapter != null)) {
  4635. global::System.Data.DataRow[] updatedRows = dataSet.Users.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
  4636. updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
  4637. if (((updatedRows != null)
  4638. && (0 < updatedRows.Length))) {
  4639. result = (result + this._usersTableAdapter.Update(updatedRows));
  4640. allChangedRows.AddRange(updatedRows);
  4641. }
  4642. }
  4643. if ((this._potrebnostTableAdapter != null)) {
  4644. global::System.Data.DataRow[] updatedRows = dataSet.Potrebnost.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
  4645. updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
  4646. if (((updatedRows != null)
  4647. && (0 < updatedRows.Length))) {
  4648. result = (result + this._potrebnostTableAdapter.Update(updatedRows));
  4649. allChangedRows.AddRange(updatedRows);
  4650. }
  4651. }
  4652. if ((this._predlozhenieTableAdapter != null)) {
  4653. global::System.Data.DataRow[] updatedRows = dataSet.predlozhenie.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
  4654. updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
  4655. if (((updatedRows != null)
  4656. && (0 < updatedRows.Length))) {
  4657. result = (result + this._predlozhenieTableAdapter.Update(updatedRows));
  4658. allChangedRows.AddRange(updatedRows);
  4659. }
  4660. }
  4661. if ((this._sdelkaTableAdapter != null)) {
  4662. global::System.Data.DataRow[] updatedRows = dataSet.Sdelka.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
  4663. updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
  4664. if (((updatedRows != null)
  4665. && (0 < updatedRows.Length))) {
  4666. result = (result + this._sdelkaTableAdapter.Update(updatedRows));
  4667. allChangedRows.AddRange(updatedRows);
  4668. }
  4669. }
  4670. return result;
  4671. }
  4672. /// <summary>
  4673. ///Insert rows in top-down order.
  4674. ///</summary>
  4675. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4676. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4677. private int UpdateInsertedRows(DBAgentstvoDataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  4678. int result = 0;
  4679. if ((this._usersTableAdapter != null)) {
  4680. global::System.Data.DataRow[] addedRows = dataSet.Users.Select(null, null, global::System.Data.DataViewRowState.Added);
  4681. if (((addedRows != null)
  4682. && (0 < addedRows.Length))) {
  4683. result = (result + this._usersTableAdapter.Update(addedRows));
  4684. allAddedRows.AddRange(addedRows);
  4685. }
  4686. }
  4687. if ((this._potrebnostTableAdapter != null)) {
  4688. global::System.Data.DataRow[] addedRows = dataSet.Potrebnost.Select(null, null, global::System.Data.DataViewRowState.Added);
  4689. if (((addedRows != null)
  4690. && (0 < addedRows.Length))) {
  4691. result = (result + this._potrebnostTableAdapter.Update(addedRows));
  4692. allAddedRows.AddRange(addedRows);
  4693. }
  4694. }
  4695. if ((this._predlozhenieTableAdapter != null)) {
  4696. global::System.Data.DataRow[] addedRows = dataSet.predlozhenie.Select(null, null, global::System.Data.DataViewRowState.Added);
  4697. if (((addedRows != null)
  4698. && (0 < addedRows.Length))) {
  4699. result = (result + this._predlozhenieTableAdapter.Update(addedRows));
  4700. allAddedRows.AddRange(addedRows);
  4701. }
  4702. }
  4703. if ((this._sdelkaTableAdapter != null)) {
  4704. global::System.Data.DataRow[] addedRows = dataSet.Sdelka.Select(null, null, global::System.Data.DataViewRowState.Added);
  4705. if (((addedRows != null)
  4706. && (0 < addedRows.Length))) {
  4707. result = (result + this._sdelkaTableAdapter.Update(addedRows));
  4708. allAddedRows.AddRange(addedRows);
  4709. }
  4710. }
  4711. return result;
  4712. }
  4713. /// <summary>
  4714. ///Delete rows in bottom-up order.
  4715. ///</summary>
  4716. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4717. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4718. private int UpdateDeletedRows(DBAgentstvoDataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows) {
  4719. int result = 0;
  4720. if ((this._sdelkaTableAdapter != null)) {
  4721. global::System.Data.DataRow[] deletedRows = dataSet.Sdelka.Select(null, null, global::System.Data.DataViewRowState.Deleted);
  4722. if (((deletedRows != null)
  4723. && (0 < deletedRows.Length))) {
  4724. result = (result + this._sdelkaTableAdapter.Update(deletedRows));
  4725. allChangedRows.AddRange(deletedRows);
  4726. }
  4727. }
  4728. if ((this._predlozhenieTableAdapter != null)) {
  4729. global::System.Data.DataRow[] deletedRows = dataSet.predlozhenie.Select(null, null, global::System.Data.DataViewRowState.Deleted);
  4730. if (((deletedRows != null)
  4731. && (0 < deletedRows.Length))) {
  4732. result = (result + this._predlozhenieTableAdapter.Update(deletedRows));
  4733. allChangedRows.AddRange(deletedRows);
  4734. }
  4735. }
  4736. if ((this._potrebnostTableAdapter != null)) {
  4737. global::System.Data.DataRow[] deletedRows = dataSet.Potrebnost.Select(null, null, global::System.Data.DataViewRowState.Deleted);
  4738. if (((deletedRows != null)
  4739. && (0 < deletedRows.Length))) {
  4740. result = (result + this._potrebnostTableAdapter.Update(deletedRows));
  4741. allChangedRows.AddRange(deletedRows);
  4742. }
  4743. }
  4744. if ((this._usersTableAdapter != null)) {
  4745. global::System.Data.DataRow[] deletedRows = dataSet.Users.Select(null, null, global::System.Data.DataViewRowState.Deleted);
  4746. if (((deletedRows != null)
  4747. && (0 < deletedRows.Length))) {
  4748. result = (result + this._usersTableAdapter.Update(deletedRows));
  4749. allChangedRows.AddRange(deletedRows);
  4750. }
  4751. }
  4752. return result;
  4753. }
  4754. /// <summary>
  4755. ///Remove inserted rows that become updated rows after calling TableAdapter.Update(inserted rows) first
  4756. ///</summary>
  4757. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4758. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4759. private global::System.Data.DataRow[] GetRealUpdatedRows(global::System.Data.DataRow[] updatedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  4760. if (((updatedRows == null)
  4761. || (updatedRows.Length < 1))) {
  4762. return updatedRows;
  4763. }
  4764. if (((allAddedRows == null)
  4765. || (allAddedRows.Count < 1))) {
  4766. return updatedRows;
  4767. }
  4768. global::System.Collections.Generic.List<global::System.Data.DataRow> realUpdatedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  4769. for (int i = 0; (i < updatedRows.Length); i = (i + 1)) {
  4770. global::System.Data.DataRow row = updatedRows[i];
  4771. if ((allAddedRows.Contains(row) == false)) {
  4772. realUpdatedRows.Add(row);
  4773. }
  4774. }
  4775. return realUpdatedRows.ToArray();
  4776. }
  4777. /// <summary>
  4778. ///Update all changes to the dataset.
  4779. ///</summary>
  4780. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4781. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4782. public virtual int UpdateAll(DBAgentstvoDataSet dataSet) {
  4783. if ((dataSet == null)) {
  4784. throw new global::System.ArgumentNullException("dataSet");
  4785. }
  4786. if ((dataSet.HasChanges() == false)) {
  4787. return 0;
  4788. }
  4789. if (((this._potrebnostTableAdapter != null)
  4790. && (this.MatchTableAdapterConnection(this._potrebnostTableAdapter.Connection) == false))) {
  4791. throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" +
  4792. "tring.");
  4793. }
  4794. if (((this._predlozhenieTableAdapter != null)
  4795. && (this.MatchTableAdapterConnection(this._predlozhenieTableAdapter.Connection) == false))) {
  4796. throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" +
  4797. "tring.");
  4798. }
  4799. if (((this._sdelkaTableAdapter != null)
  4800. && (this.MatchTableAdapterConnection(this._sdelkaTableAdapter.Connection) == false))) {
  4801. throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" +
  4802. "tring.");
  4803. }
  4804. if (((this._usersTableAdapter != null)
  4805. && (this.MatchTableAdapterConnection(this._usersTableAdapter.Connection) == false))) {
  4806. throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" +
  4807. "tring.");
  4808. }
  4809. global::System.Data.IDbConnection workConnection = this.Connection;
  4810. if ((workConnection == null)) {
  4811. throw new global::System.ApplicationException("TableAdapterManager contains no connection information. Set each TableAdapterMana" +
  4812. "ger TableAdapter property to a valid TableAdapter instance.");
  4813. }
  4814. bool workConnOpened = false;
  4815. if (((workConnection.State & global::System.Data.ConnectionState.Broken)
  4816. == global::System.Data.ConnectionState.Broken)) {
  4817. workConnection.Close();
  4818. }
  4819. if ((workConnection.State == global::System.Data.ConnectionState.Closed)) {
  4820. workConnection.Open();
  4821. workConnOpened = true;
  4822. }
  4823. global::System.Data.IDbTransaction workTransaction = workConnection.BeginTransaction();
  4824. if ((workTransaction == null)) {
  4825. throw new global::System.ApplicationException("The transaction cannot begin. The current data connection does not support transa" +
  4826. "ctions or the current state is not allowing the transaction to begin.");
  4827. }
  4828. global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  4829. global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  4830. global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter> adaptersWithAcceptChangesDuringUpdate = new global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter>();
  4831. global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection> revertConnections = new global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection>();
  4832. int result = 0;
  4833. global::System.Data.DataSet backupDataSet = null;
  4834. if (this.BackupDataSetBeforeUpdate) {
  4835. backupDataSet = new global::System.Data.DataSet();
  4836. backupDataSet.Merge(dataSet);
  4837. }
  4838. try {
  4839. // ---- Prepare for update -----------
  4840. //
  4841. if ((this._potrebnostTableAdapter != null)) {
  4842. revertConnections.Add(this._potrebnostTableAdapter, this._potrebnostTableAdapter.Connection);
  4843. this._potrebnostTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
  4844. this._potrebnostTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
  4845. if (this._potrebnostTableAdapter.Adapter.AcceptChangesDuringUpdate) {
  4846. this._potrebnostTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
  4847. adaptersWithAcceptChangesDuringUpdate.Add(this._potrebnostTableAdapter.Adapter);
  4848. }
  4849. }
  4850. if ((this._predlozhenieTableAdapter != null)) {
  4851. revertConnections.Add(this._predlozhenieTableAdapter, this._predlozhenieTableAdapter.Connection);
  4852. this._predlozhenieTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
  4853. this._predlozhenieTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
  4854. if (this._predlozhenieTableAdapter.Adapter.AcceptChangesDuringUpdate) {
  4855. this._predlozhenieTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
  4856. adaptersWithAcceptChangesDuringUpdate.Add(this._predlozhenieTableAdapter.Adapter);
  4857. }
  4858. }
  4859. if ((this._sdelkaTableAdapter != null)) {
  4860. revertConnections.Add(this._sdelkaTableAdapter, this._sdelkaTableAdapter.Connection);
  4861. this._sdelkaTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
  4862. this._sdelkaTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
  4863. if (this._sdelkaTableAdapter.Adapter.AcceptChangesDuringUpdate) {
  4864. this._sdelkaTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
  4865. adaptersWithAcceptChangesDuringUpdate.Add(this._sdelkaTableAdapter.Adapter);
  4866. }
  4867. }
  4868. if ((this._usersTableAdapter != null)) {
  4869. revertConnections.Add(this._usersTableAdapter, this._usersTableAdapter.Connection);
  4870. this._usersTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
  4871. this._usersTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
  4872. if (this._usersTableAdapter.Adapter.AcceptChangesDuringUpdate) {
  4873. this._usersTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
  4874. adaptersWithAcceptChangesDuringUpdate.Add(this._usersTableAdapter.Adapter);
  4875. }
  4876. }
  4877. //
  4878. //---- Perform updates -----------
  4879. //
  4880. if ((this.UpdateOrder == UpdateOrderOption.UpdateInsertDelete)) {
  4881. result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
  4882. result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
  4883. }
  4884. else {
  4885. result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
  4886. result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
  4887. }
  4888. result = (result + this.UpdateDeletedRows(dataSet, allChangedRows));
  4889. //
  4890. //---- Commit updates -----------
  4891. //
  4892. workTransaction.Commit();
  4893. if ((0 < allAddedRows.Count)) {
  4894. global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
  4895. allAddedRows.CopyTo(rows);
  4896. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  4897. global::System.Data.DataRow row = rows[i];
  4898. row.AcceptChanges();
  4899. }
  4900. }
  4901. if ((0 < allChangedRows.Count)) {
  4902. global::System.Data.DataRow[] rows = new System.Data.DataRow[allChangedRows.Count];
  4903. allChangedRows.CopyTo(rows);
  4904. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  4905. global::System.Data.DataRow row = rows[i];
  4906. row.AcceptChanges();
  4907. }
  4908. }
  4909. }
  4910. catch (global::System.Exception ex) {
  4911. workTransaction.Rollback();
  4912. // ---- Restore the dataset -----------
  4913. if (this.BackupDataSetBeforeUpdate) {
  4914. global::System.Diagnostics.Debug.Assert((backupDataSet != null));
  4915. dataSet.Clear();
  4916. dataSet.Merge(backupDataSet);
  4917. }
  4918. else {
  4919. if ((0 < allAddedRows.Count)) {
  4920. global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
  4921. allAddedRows.CopyTo(rows);
  4922. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  4923. global::System.Data.DataRow row = rows[i];
  4924. row.AcceptChanges();
  4925. row.SetAdded();
  4926. }
  4927. }
  4928. }
  4929. throw ex;
  4930. }
  4931. finally {
  4932. if (workConnOpened) {
  4933. workConnection.Close();
  4934. }
  4935. if ((this._potrebnostTableAdapter != null)) {
  4936. this._potrebnostTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._potrebnostTableAdapter]));
  4937. this._potrebnostTableAdapter.Transaction = null;
  4938. }
  4939. if ((this._predlozhenieTableAdapter != null)) {
  4940. this._predlozhenieTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._predlozhenieTableAdapter]));
  4941. this._predlozhenieTableAdapter.Transaction = null;
  4942. }
  4943. if ((this._sdelkaTableAdapter != null)) {
  4944. this._sdelkaTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._sdelkaTableAdapter]));
  4945. this._sdelkaTableAdapter.Transaction = null;
  4946. }
  4947. if ((this._usersTableAdapter != null)) {
  4948. this._usersTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._usersTableAdapter]));
  4949. this._usersTableAdapter.Transaction = null;
  4950. }
  4951. if ((0 < adaptersWithAcceptChangesDuringUpdate.Count)) {
  4952. global::System.Data.Common.DataAdapter[] adapters = new System.Data.Common.DataAdapter[adaptersWithAcceptChangesDuringUpdate.Count];
  4953. adaptersWithAcceptChangesDuringUpdate.CopyTo(adapters);
  4954. for (int i = 0; (i < adapters.Length); i = (i + 1)) {
  4955. global::System.Data.Common.DataAdapter adapter = adapters[i];
  4956. adapter.AcceptChangesDuringUpdate = true;
  4957. }
  4958. }
  4959. }
  4960. return result;
  4961. }
  4962. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4963. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4964. protected virtual void SortSelfReferenceRows(global::System.Data.DataRow[] rows, global::System.Data.DataRelation relation, bool childFirst) {
  4965. global::System.Array.Sort<global::System.Data.DataRow>(rows, new SelfReferenceComparer(relation, childFirst));
  4966. }
  4967. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4968. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4969. protected virtual bool MatchTableAdapterConnection(global::System.Data.IDbConnection inputConnection) {
  4970. if ((this._connection != null)) {
  4971. return true;
  4972. }
  4973. if (((this.Connection == null)
  4974. || (inputConnection == null))) {
  4975. return true;
  4976. }
  4977. if (string.Equals(this.Connection.ConnectionString, inputConnection.ConnectionString, global::System.StringComparison.Ordinal)) {
  4978. return true;
  4979. }
  4980. return false;
  4981. }
  4982. /// <summary>
  4983. ///Update Order Option
  4984. ///</summary>
  4985. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4986. public enum UpdateOrderOption {
  4987. InsertUpdateDelete = 0,
  4988. UpdateInsertDelete = 1,
  4989. }
  4990. /// <summary>
  4991. ///Used to sort self-referenced table's rows
  4992. ///</summary>
  4993. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4994. private class SelfReferenceComparer : object, global::System.Collections.Generic.IComparer<global::System.Data.DataRow> {
  4995. private global::System.Data.DataRelation _relation;
  4996. private int _childFirst;
  4997. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  4998. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  4999. internal SelfReferenceComparer(global::System.Data.DataRelation relation, bool childFirst) {
  5000. this._relation = relation;
  5001. if (childFirst) {
  5002. this._childFirst = -1;
  5003. }
  5004. else {
  5005. this._childFirst = 1;
  5006. }
  5007. }
  5008. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  5009. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  5010. private global::System.Data.DataRow GetRoot(global::System.Data.DataRow row, out int distance) {
  5011. global::System.Diagnostics.Debug.Assert((row != null));
  5012. global::System.Data.DataRow root = row;
  5013. distance = 0;
  5014. 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>();
  5015. traversedRows[row] = row;
  5016. global::System.Data.DataRow parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
  5017. for (
  5018. ; ((parent != null)
  5019. && (traversedRows.ContainsKey(parent) == false));
  5020. ) {
  5021. distance = (distance + 1);
  5022. root = parent;
  5023. traversedRows[parent] = parent;
  5024. parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
  5025. }
  5026. if ((distance == 0)) {
  5027. traversedRows.Clear();
  5028. traversedRows[row] = row;
  5029. parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
  5030. for (
  5031. ; ((parent != null)
  5032. && (traversedRows.ContainsKey(parent) == false));
  5033. ) {
  5034. distance = (distance + 1);
  5035. root = parent;
  5036. traversedRows[parent] = parent;
  5037. parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
  5038. }
  5039. }
  5040. return root;
  5041. }
  5042. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  5043. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
  5044. public int Compare(global::System.Data.DataRow row1, global::System.Data.DataRow row2) {
  5045. if (object.ReferenceEquals(row1, row2)) {
  5046. return 0;
  5047. }
  5048. if ((row1 == null)) {
  5049. return -1;
  5050. }
  5051. if ((row2 == null)) {
  5052. return 1;
  5053. }
  5054. int distance1 = 0;
  5055. global::System.Data.DataRow root1 = this.GetRoot(row1, out distance1);
  5056. int distance2 = 0;
  5057. global::System.Data.DataRow root2 = this.GetRoot(row2, out distance2);
  5058. if (object.ReferenceEquals(root1, root2)) {
  5059. return (this._childFirst * distance1.CompareTo(distance2));
  5060. }
  5061. else {
  5062. global::System.Diagnostics.Debug.Assert(((root1.Table != null)
  5063. && (root2.Table != null)));
  5064. if ((root1.Table.Rows.IndexOf(root1) < root2.Table.Rows.IndexOf(root2))) {
  5065. return -1;
  5066. }
  5067. else {
  5068. return 1;
  5069. }
  5070. }
  5071. }
  5072. }
  5073. }
  5074. }
  5075. #pragma warning restore 1591