コード例 #1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromKitcreatedetailsttresults(ref DataRow row, Kitcreatedetailsttresults entity)
 {
     row.SetField("specnstype", entity.specnstype);
     row.SetField("shipprod", entity.shipprod);
     row.SetField("proddesc", entity.proddesc);
     row.SetField("comptype", entity.comptype);
     row.SetField("groupoptname", entity.groupoptname);
     row.SetField("lastprod", entity.lastprod);
     row.SetField("refer", entity.refer);
     row.SetField("wlpicktype", entity.wlpicktype);
     row.SetField("reqfl", entity.reqfl);
     row.SetField("pricefl", entity.pricefl);
     row.SetField("instructions", entity.instructions);
     row.SetField("variablefl", entity.variablefl);
     row.SetField("printfl", entity.printfl);
     row.SetField("subfl", entity.subfl);
     row.SetField("bofl", entity.bofl);
     row.SetField("qtyneeded", entity.qtyneeded);
     row.SetField("unit", entity.unit);
     row.SetField("pdprodcost", entity.pdprodcost);
     row.SetField("prodcost", entity.prodcost);
     row.SetField("speccostty", entity.speccostty);
     row.SetField("totalneeded", entity.totalneeded);
     row.SetField("unitstock", entity.unitstock);
     row.SetField("pdprice", entity.pdprice);
     row.SetField("price", entity.price);
     row.SetField("specpricety", entity.specpricety);
     row.SetField("totship", entity.totship);
     row.SetField("pdtitle", entity.pdtitle);
     row.SetField("pdrecno", entity.pdrecno);
     row.SetField("ovship", entity.ovship);
     row.SetField("qtyreserved", entity.qtyreserved);
     row.SetField("tietitle", entity.tietitle);
     row.SetField("tiedata", entity.tiedata);
     row.SetField("delayresrvfl", entity.delayresrvfl);
     row.SetField("addfl", entity.addfl);
     row.SetField("activeflasked", entity.activeflasked);
     row.SetField("activeflanswer", entity.activeflanswer);
     row.SetField("xrefcatflasked", entity.xrefcatflasked);
     row.SetField("xrefcatflanswer", entity.xrefcatflanswer);
     row.SetField("promptedxreflookup", entity.promptedxreflookup);
     row.SetField("xreflookupoutprod", entity.xreflookupoutprod);
     row.SetField("xreflookupouttype", entity.xreflookupouttype);
     row.SetField("createcatflasked", entity.createcatflasked);
     row.SetField("createcatflanswer", entity.createcatflanswer);
     row.SetField("btnsubslabel", entity.btnsubslabel);
     row.SetField("btnnonstocklabel", entity.btnnonstocklabel);
     row.SetField("btnsubshidden", entity.btnsubshidden);
     row.SetField("btncrossrefhidden", entity.btncrossrefhidden);
     row.SetField("qtyreservedhidden", entity.qtyreservedhidden);
     row.SetField("delayresrvflhidden", entity.delayresrvflhidden);
     row.SetField("pdrecnohidden", entity.pdrecnohidden);
     row.SetField("specpricetyhidden", entity.specpricetyhidden);
     row.SetField("pdprodcosthidden", entity.pdprodcosthidden);
     row.SetField("pdtitlehidden", entity.pdtitlehidden);
     row.SetField("pdpricehidden", entity.pdpricehidden);
     row.SetField("pricehidden", entity.pricehidden);
     row.SetField("prodcosthidden", entity.prodcosthidden);
     row.SetField("speccosttyhidden", entity.speccosttyhidden);
     row.SetField("wlpicktypehidden", entity.wlpicktypehidden);
     row.SetField("btnlookupprodhidden", entity.btnlookupprodhidden);
     row.SetField("btnlookupunithidden", entity.btnlookupunithidden);
     row.SetField("lastprodhidden", entity.lastprodhidden);
     row.SetField("btnnonstockhidden", entity.btnnonstockhidden);
     row.SetField("btncrossrefenabled", entity.btncrossrefenabled);
     row.SetField("btnsubsenabled", entity.btnsubsenabled);
     row.SetField("printflenabled", entity.printflenabled);
     row.SetField("instructionsenabled", entity.instructionsenabled);
     row.SetField("referenabled", entity.referenabled);
     row.SetField("btnreferenceenabled", entity.btnreferenceenabled);
     row.SetField("priceflenabled", entity.priceflenabled);
     row.SetField("qtyreservedenabled", entity.qtyreservedenabled);
     row.SetField("totshipenabled", entity.totshipenabled);
     row.SetField("ovshipenabled", entity.ovshipenabled);
     row.SetField("wlpicktypeenabled", entity.wlpicktypeenabled);
     row.SetField("btnupdateenabled", entity.btnupdateenabled);
     row.SetField("btncancelenabled", entity.btncancelenabled);
     row.SetField("proddescenabled", entity.proddescenabled);
     row.SetField("shipprodenabled", entity.shipprodenabled);
     row.SetField("qtyneededenabled", entity.qtyneededenabled);
     row.SetField("unitenabled", entity.unitenabled);
     row.SetField("btnlookupprodenabled", entity.btnlookupprodenabled);
     row.SetField("btnlookupunitenabled", entity.btnlookupunitenabled);
     row.SetField("specnstypeenabled", entity.specnstypeenabled);
     row.SetField("variableflenabled", entity.variableflenabled);
     row.SetField("subflenabled", entity.subflenabled);
     row.SetField("boflenabled", entity.boflenabled);
     row.SetField("btnnonstockenabled", entity.btnnonstockenabled);
     row.SetField("countryoforiginenabled", entity.countryoforiginenabled);
     row.SetField("tariffcdenabled", entity.tariffcdenabled);
     row.SetField("sourcingenabled", entity.sourcingenabled);
     row.SetField("entrystart", entity.entrystart);
     row.SetField("qtyrsvupdtfl", entity.qtyrsvupdtfl);
     row.SetField("addty", entity.addty);
     row.SetField("arpprodline", entity.arpprodline);
     row.SetField("arpvendno", entity.arpvendno);
     row.SetField("arpwhse", entity.arpwhse);
     row.SetField("brseqno", entity.brseqno);
     row.SetField("cataddfl", entity.cataddfl);
     row.SetField("compboty", entity.compboty);
     row.SetField("descrip", entity.descrip);
     row.SetField("fromoeelk", entity.fromoeelk);
     row.SetField("groupname", entity.groupname);
     row.SetField("grpqty", entity.grpqty);
     row.SetField("lineno", entity.lineno);
     row.SetField("nsokfl", entity.nsokfl);
     row.SetField("oeelkrecid", entity.oeelkrecid);
     row.SetField("oeelkrowid", entity.oeelkrowid.ToByteArray());
     row.SetField("orderno", entity.orderno);
     row.SetField("ordersuf", entity.ordersuf);
     row.SetField("ordtype", entity.ordtype);
     row.SetField("ourproc", entity.ourproc);
     row.SetField("ovshipfl", entity.ovshipfl);
     row.SetField("pricetype", entity.pricetype);
     row.SetField("prodcat", entity.prodcat);
     row.SetField("qtyavail", entity.qtyavail);
     row.SetField("qtyreservd", entity.qtyreservd);
     row.SetField("qtyship", entity.qtyship);
     row.SetField("returnfl", entity.returnfl);
     row.SetField("seqbef", entity.seqbef);
     row.SetField("seqno", entity.seqno);
     row.SetField("serlottype", entity.serlottype);
     row.SetField("totneeded", entity.totneeded);
     row.SetField("unitconv", entity.unitconv);
     row.SetField("user1", entity.user1);
     row.SetField("user2", entity.user2);
     row.SetField("user3", entity.user3);
     row.SetField("user4", entity.user4);
     row.SetField("user5", entity.user5);
     row.SetField("user6", entity.user6);
     row.SetField("user7", entity.user7);
     row.SetField("user8", entity.user8);
     row.SetField("user9", entity.user9);
     row.SetField("whse", entity.whse);
     row.SetField("countryoforigin", entity.countryoforigin);
     row.SetField("tariffcd", entity.tariffcd);
     row.SetField("xreffl", entity.xreffl);
     row.SetField("newprodname", entity.newprodname);
     row.SetField("costoverfl", entity.costoverfl);
     row.SetField("cfgcompfl", entity.cfgcompfl);
     row.SetField("prodname", entity.prodname);
     row.SetField("prodnotes", entity.prodnotes);
     row.SetField("specnstypedesc", entity.specnstypedesc);
     row.SetField("serlottypedesc", entity.serlottypedesc);
     row.SetField("wmfl", entity.wmfl);
     row.SetField("wmqtyship", entity.wmqtyship);
     row.SetField("conv-oeelk", entity.convOeelk);
     row.SetField("seqno-oeelk", entity.seqnoOeelk);
     row.SetField("groupoptname-oeelk", entity.groupoptnameOeelk);
     row.SetField("pdrecno-oeelk", entity.pdrecnoOeelk);
     row.SetField("price-oeelk", entity.priceOeelk);
     row.SetField("prodcost-oeelk", entity.prodcostOeelk);
     row.SetField("icspecrecno-oeelk", entity.icspecrecnoOeelk);
     row.SetField("userfield", entity.userfield);
 }
コード例 #2
0
        public static Kitcreatedetailsttresults BuildKitcreatedetailsttresultsFromRow(DataRow row)
        {
            Kitcreatedetailsttresults entity = new Kitcreatedetailsttresults();

            entity.specnstype             = row.IsNull("specnstype") ? string.Empty : row.Field <string>("specnstype");
            entity.shipprod               = row.IsNull("shipprod") ? string.Empty : row.Field <string>("shipprod");
            entity.proddesc               = row.IsNull("proddesc") ? string.Empty : row.Field <string>("proddesc");
            entity.comptype               = row.IsNull("comptype") ? string.Empty : row.Field <string>("comptype");
            entity.groupoptname           = row.IsNull("groupoptname") ? string.Empty : row.Field <string>("groupoptname");
            entity.lastprod               = row.IsNull("lastprod") ? string.Empty : row.Field <string>("lastprod");
            entity.refer                  = row.IsNull("refer") ? string.Empty : row.Field <string>("refer");
            entity.wlpicktype             = row.IsNull("wlpicktype") ? string.Empty : row.Field <string>("wlpicktype");
            entity.reqfl                  = row.Field <bool>("reqfl");
            entity.pricefl                = row.Field <bool>("pricefl");
            entity.instructions           = row.IsNull("instructions") ? string.Empty : row.Field <string>("instructions");
            entity.variablefl             = row.Field <bool>("variablefl");
            entity.printfl                = row.Field <bool>("printfl");
            entity.subfl                  = row.Field <bool>("subfl");
            entity.bofl                   = row.Field <bool>("bofl");
            entity.qtyneeded              = row.IsNull("qtyneeded") ? decimal.Zero : row.Field <decimal>("qtyneeded");
            entity.unit                   = row.IsNull("unit") ? string.Empty : row.Field <string>("unit");
            entity.pdprodcost             = row.IsNull("pdprodcost") ? string.Empty : row.Field <string>("pdprodcost");
            entity.prodcost               = row.IsNull("prodcost") ? decimal.Zero : row.Field <decimal>("prodcost");
            entity.speccostty             = row.IsNull("speccostty") ? string.Empty : row.Field <string>("speccostty");
            entity.totalneeded            = row.IsNull("totalneeded") ? decimal.Zero : row.Field <decimal>("totalneeded");
            entity.unitstock              = row.IsNull("unitstock") ? string.Empty : row.Field <string>("unitstock");
            entity.pdprice                = row.IsNull("pdprice") ? string.Empty : row.Field <string>("pdprice");
            entity.price                  = row.IsNull("price") ? decimal.Zero : row.Field <decimal>("price");
            entity.specpricety            = row.IsNull("specpricety") ? string.Empty : row.Field <string>("specpricety");
            entity.totship                = row.IsNull("totship") ? decimal.Zero : row.Field <decimal>("totship");
            entity.pdtitle                = row.IsNull("pdtitle") ? string.Empty : row.Field <string>("pdtitle");
            entity.pdrecno                = row.IsNull("pdrecno") ? 0 : row.Field <int>("pdrecno");
            entity.ovship                 = row.Field <bool>("ovship");
            entity.qtyreserved            = row.IsNull("qtyreserved") ? decimal.Zero : row.Field <decimal>("qtyreserved");
            entity.tietitle               = row.IsNull("tietitle") ? string.Empty : row.Field <string>("tietitle");
            entity.tiedata                = row.IsNull("tiedata") ? string.Empty : row.Field <string>("tiedata");
            entity.delayresrvfl           = row.Field <bool>("delayresrvfl");
            entity.addfl                  = row.Field <bool>("addfl");
            entity.activeflasked          = row.Field <bool>("activeflasked");
            entity.activeflanswer         = row.Field <bool>("activeflanswer");
            entity.xrefcatflasked         = row.Field <bool>("xrefcatflasked");
            entity.xrefcatflanswer        = row.Field <bool>("xrefcatflanswer");
            entity.promptedxreflookup     = row.Field <bool>("promptedxreflookup");
            entity.xreflookupoutprod      = row.IsNull("xreflookupoutprod") ? string.Empty : row.Field <string>("xreflookupoutprod");
            entity.xreflookupouttype      = row.IsNull("xreflookupouttype") ? string.Empty : row.Field <string>("xreflookupouttype");
            entity.createcatflasked       = row.Field <bool>("createcatflasked");
            entity.createcatflanswer      = row.Field <bool>("createcatflanswer");
            entity.btnsubslabel           = row.IsNull("btnsubslabel") ? string.Empty : row.Field <string>("btnsubslabel");
            entity.btnnonstocklabel       = row.IsNull("btnnonstocklabel") ? string.Empty : row.Field <string>("btnnonstocklabel");
            entity.btnsubshidden          = row.Field <bool>("btnsubshidden");
            entity.btncrossrefhidden      = row.Field <bool>("btncrossrefhidden");
            entity.qtyreservedhidden      = row.Field <bool>("qtyreservedhidden");
            entity.delayresrvflhidden     = row.Field <bool>("delayresrvflhidden");
            entity.pdrecnohidden          = row.Field <bool>("pdrecnohidden");
            entity.specpricetyhidden      = row.Field <bool>("specpricetyhidden");
            entity.pdprodcosthidden       = row.Field <bool>("pdprodcosthidden");
            entity.pdtitlehidden          = row.Field <bool>("pdtitlehidden");
            entity.pdpricehidden          = row.Field <bool>("pdpricehidden");
            entity.pricehidden            = row.Field <bool>("pricehidden");
            entity.prodcosthidden         = row.Field <bool>("prodcosthidden");
            entity.speccosttyhidden       = row.Field <bool>("speccosttyhidden");
            entity.wlpicktypehidden       = row.Field <bool>("wlpicktypehidden");
            entity.btnlookupprodhidden    = row.Field <bool>("btnlookupprodhidden");
            entity.btnlookupunithidden    = row.Field <bool>("btnlookupunithidden");
            entity.lastprodhidden         = row.Field <bool>("lastprodhidden");
            entity.btnnonstockhidden      = row.Field <bool>("btnnonstockhidden");
            entity.btncrossrefenabled     = row.Field <bool>("btncrossrefenabled");
            entity.btnsubsenabled         = row.Field <bool>("btnsubsenabled");
            entity.printflenabled         = row.Field <bool>("printflenabled");
            entity.instructionsenabled    = row.Field <bool>("instructionsenabled");
            entity.referenabled           = row.Field <bool>("referenabled");
            entity.btnreferenceenabled    = row.Field <bool>("btnreferenceenabled");
            entity.priceflenabled         = row.Field <bool>("priceflenabled");
            entity.qtyreservedenabled     = row.Field <bool>("qtyreservedenabled");
            entity.totshipenabled         = row.Field <bool>("totshipenabled");
            entity.ovshipenabled          = row.Field <bool>("ovshipenabled");
            entity.wlpicktypeenabled      = row.Field <bool>("wlpicktypeenabled");
            entity.btnupdateenabled       = row.Field <bool>("btnupdateenabled");
            entity.btncancelenabled       = row.Field <bool>("btncancelenabled");
            entity.proddescenabled        = row.Field <bool>("proddescenabled");
            entity.shipprodenabled        = row.Field <bool>("shipprodenabled");
            entity.qtyneededenabled       = row.Field <bool>("qtyneededenabled");
            entity.unitenabled            = row.Field <bool>("unitenabled");
            entity.btnlookupprodenabled   = row.Field <bool>("btnlookupprodenabled");
            entity.btnlookupunitenabled   = row.Field <bool>("btnlookupunitenabled");
            entity.specnstypeenabled      = row.Field <bool>("specnstypeenabled");
            entity.variableflenabled      = row.Field <bool>("variableflenabled");
            entity.subflenabled           = row.Field <bool>("subflenabled");
            entity.boflenabled            = row.Field <bool>("boflenabled");
            entity.btnnonstockenabled     = row.Field <bool>("btnnonstockenabled");
            entity.countryoforiginenabled = row.Field <bool>("countryoforiginenabled");
            entity.tariffcdenabled        = row.Field <bool>("tariffcdenabled");
            entity.sourcingenabled        = row.Field <bool>("sourcingenabled");
            entity.entrystart             = row.IsNull("entrystart") ? string.Empty : row.Field <string>("entrystart");
            entity.qtyrsvupdtfl           = row.Field <bool>("qtyrsvupdtfl");
            entity.addty                  = row.IsNull("addty") ? string.Empty : row.Field <string>("addty");
            entity.arpprodline            = row.IsNull("arpprodline") ? string.Empty : row.Field <string>("arpprodline");
            entity.arpvendno              = row.IsNull("arpvendno") ? decimal.Zero : row.Field <decimal>("arpvendno");
            entity.arpwhse                = row.IsNull("arpwhse") ? string.Empty : row.Field <string>("arpwhse");
            entity.brseqno                = row.IsNull("brseqno") ? 0 : row.Field <int>("brseqno");
            entity.cataddfl               = row.Field <bool>("cataddfl");
            entity.compboty               = row.IsNull("compboty") ? string.Empty : row.Field <string>("compboty");
            entity.descrip                = row.IsNull("descrip") ? string.Empty : row.Field <string>("descrip");
            entity.fromoeelk              = row.Field <bool>("fromoeelk");
            entity.groupname              = row.IsNull("groupname") ? string.Empty : row.Field <string>("groupname");
            entity.grpqty                 = row.IsNull("grpqty") ? 0 : row.Field <int>("grpqty");
            entity.lineno                 = row.IsNull("lineno") ? 0 : row.Field <int>("lineno");
            entity.nsokfl                 = row.Field <bool>("nsokfl");
            entity.oeelkrecid             = row.IsNull("oeelkrecid") ? 0 : row.Field <long>("oeelkrecid");
            entity.oeelkrowid             = row.Field <byte[]>("oeelkrowid").ToStringEncoded();
            entity.orderno                = row.IsNull("orderno") ? 0 : row.Field <int>("orderno");
            entity.ordersuf               = row.IsNull("ordersuf") ? 0 : row.Field <int>("ordersuf");
            entity.ordtype                = row.IsNull("ordtype") ? string.Empty : row.Field <string>("ordtype");
            entity.ourproc                = row.IsNull("ourproc") ? string.Empty : row.Field <string>("ourproc");
            entity.ovshipfl               = row.Field <bool>("ovshipfl");
            entity.pricetype              = row.IsNull("pricetype") ? string.Empty : row.Field <string>("pricetype");
            entity.prodcat                = row.IsNull("prodcat") ? string.Empty : row.Field <string>("prodcat");
            entity.qtyavail               = row.IsNull("qtyavail") ? decimal.Zero : row.Field <decimal>("qtyavail");
            entity.qtyreservd             = row.IsNull("qtyreservd") ? decimal.Zero : row.Field <decimal>("qtyreservd");
            entity.qtyship                = row.IsNull("qtyship") ? decimal.Zero : row.Field <decimal>("qtyship");
            entity.returnfl               = row.Field <bool>("returnfl");
            entity.seqbef                 = row.IsNull("seqbef") ? 0 : row.Field <int>("seqbef");
            entity.seqno                  = row.IsNull("seqno") ? 0 : row.Field <int>("seqno");
            entity.serlottype             = row.IsNull("serlottype") ? string.Empty : row.Field <string>("serlottype");
            entity.totneeded              = row.IsNull("totneeded") ? decimal.Zero : row.Field <decimal>("totneeded");
            entity.unitconv               = row.IsNull("unitconv") ? decimal.Zero : row.Field <decimal>("unitconv");
            entity.user1                  = row.IsNull("user1") ? string.Empty : row.Field <string>("user1");
            entity.user2                  = row.IsNull("user2") ? string.Empty : row.Field <string>("user2");
            entity.user3                  = row.IsNull("user3") ? string.Empty : row.Field <string>("user3");
            entity.user4                  = row.IsNull("user4") ? string.Empty : row.Field <string>("user4");
            entity.user5                  = row.IsNull("user5") ? string.Empty : row.Field <string>("user5");
            entity.user6                  = row.Field <decimal?>("user6");
            entity.user7                  = row.Field <decimal?>("user7");
            entity.user8                  = row.Field <DateTime?>("user8");
            entity.user9                  = row.Field <DateTime?>("user9");
            entity.whse                   = row.IsNull("whse") ? string.Empty : row.Field <string>("whse");
            entity.countryoforigin        = row.IsNull("countryoforigin") ? string.Empty : row.Field <string>("countryoforigin");
            entity.tariffcd               = row.IsNull("tariffcd") ? string.Empty : row.Field <string>("tariffcd");
            entity.xreffl                 = row.Field <bool>("xreffl");
            entity.newprodname            = row.IsNull("newprodname") ? string.Empty : row.Field <string>("newprodname");
            entity.costoverfl             = row.Field <bool>("costoverfl");
            entity.cfgcompfl              = row.Field <bool>("cfgcompfl");
            entity.prodname               = row.IsNull("prodname") ? string.Empty : row.Field <string>("prodname");
            entity.prodnotes              = row.IsNull("prodnotes") ? string.Empty : row.Field <string>("prodnotes");
            entity.specnstypedesc         = row.IsNull("specnstypedesc") ? string.Empty : row.Field <string>("specnstypedesc");
            entity.serlottypedesc         = row.IsNull("serlottypedesc") ? string.Empty : row.Field <string>("serlottypedesc");
            entity.wmfl                   = row.Field <bool>("wmfl");
            entity.wmqtyship              = row.IsNull("wmqtyship") ? decimal.Zero : row.Field <decimal>("wmqtyship");
            entity.convOeelk              = row.IsNull("conv-oeelk") ? 0 : row.Field <int>("conv-oeelk");
            entity.seqnoOeelk             = row.IsNull("seqno-oeelk") ? 0 : row.Field <int>("seqno-oeelk");
            entity.groupoptnameOeelk      = row.IsNull("groupoptname-oeelk") ? string.Empty : row.Field <string>("groupoptname-oeelk");
            entity.pdrecnoOeelk           = row.IsNull("pdrecno-oeelk") ? 0 : row.Field <int>("pdrecno-oeelk");
            entity.priceOeelk             = row.IsNull("price-oeelk") ? decimal.Zero : row.Field <decimal>("price-oeelk");
            entity.prodcostOeelk          = row.IsNull("prodcost-oeelk") ? decimal.Zero : row.Field <decimal>("prodcost-oeelk");
            entity.icspecrecnoOeelk       = row.IsNull("icspecrecno-oeelk") ? 0 : row.Field <int>("icspecrecno-oeelk");
            entity.userfield              = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }