Esempio n. 1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromWtitbuildwttracklistresults(ref DataRow row, Wtitbuildwttracklistresults entity)
 {
     row.SetField("cono", entity.cono);
     row.SetField("orderty", entity.orderty);
     row.SetField("orderno", entity.orderno);
     row.SetField("ordersuf", entity.ordersuf);
     row.SetField("trackerno", entity.trackerno);
     row.SetField("pkgno", entity.pkgno);
     row.SetField("rowid-oeehp", entity.rowidOeehp.ToByteArray());
     row.SetField("wtno", entity.wtno);
     row.SetField("wtsuf", entity.wtsuf);
     row.SetField("notesfl", entity.notesfl);
     row.SetField("transtype", entity.transtype);
     row.SetField("stagename", entity.stagename);
     row.SetField("stagecd", entity.stagecd);
     row.SetField("shipfmwhse", entity.shipfmwhse);
     row.SetField("shipfmwhsename", entity.shipfmwhsename);
     row.SetField("shiptowhse", entity.shiptowhse);
     row.SetField("shiptowhsename", entity.shiptowhsename);
     row.SetField("shiptonm", entity.shiptonm);
     row.SetField("enterdt", entity.enterdt);
     row.SetField("orderdt", entity.orderdt);
     row.SetField("duedt", entity.duedt);
     row.SetField("reqshipdt", entity.reqshipdt);
     row.SetField("shipdt", entity.shipdt);
     row.SetField("receiptdt", entity.receiptdt);
     row.SetField("totlineamt", entity.totlineamt);
     row.SetField("cono2", entity.cono2);
     row.SetField("rowid-wteh", entity.rowidWteh.ToByteArray());
 }
Esempio n. 2
0
        public static Wtitbuildwttracklistresults BuildWtitbuildwttracklistresultsFromRow(DataRow row)
        {
            Wtitbuildwttracklistresults entity = new Wtitbuildwttracklistresults();

            entity.cono           = row.IsNull("cono") ? 0 : row.Field <int>("cono");
            entity.orderty        = row.IsNull("orderty") ? string.Empty : row.Field <string>("orderty");
            entity.orderno        = row.IsNull("orderno") ? 0 : row.Field <int>("orderno");
            entity.ordersuf       = row.IsNull("ordersuf") ? 0 : row.Field <int>("ordersuf");
            entity.trackerno      = row.IsNull("trackerno") ? string.Empty : row.Field <string>("trackerno");
            entity.pkgno          = row.IsNull("pkgno") ? 0 : row.Field <int>("pkgno");
            entity.rowidOeehp     = row.Field <byte[]>("rowid-oeehp").ToStringEncoded();
            entity.wtno           = row.IsNull("wtno") ? 0 : row.Field <int>("wtno");
            entity.wtsuf          = row.IsNull("wtsuf") ? 0 : row.Field <int>("wtsuf");
            entity.notesfl        = row.IsNull("notesfl") ? string.Empty : row.Field <string>("notesfl");
            entity.transtype      = row.IsNull("transtype") ? string.Empty : row.Field <string>("transtype");
            entity.stagename      = row.IsNull("stagename") ? string.Empty : row.Field <string>("stagename");
            entity.stagecd        = row.IsNull("stagecd") ? 0 : row.Field <int>("stagecd");
            entity.shipfmwhse     = row.IsNull("shipfmwhse") ? string.Empty : row.Field <string>("shipfmwhse");
            entity.shipfmwhsename = row.IsNull("shipfmwhsename") ? string.Empty : row.Field <string>("shipfmwhsename");
            entity.shiptowhse     = row.IsNull("shiptowhse") ? string.Empty : row.Field <string>("shiptowhse");
            entity.shiptowhsename = row.IsNull("shiptowhsename") ? string.Empty : row.Field <string>("shiptowhsename");
            entity.shiptonm       = row.IsNull("shiptonm") ? string.Empty : row.Field <string>("shiptonm");
            entity.enterdt        = row.Field <DateTime?>("enterdt");
            entity.orderdt        = row.Field <DateTime?>("orderdt");
            entity.duedt          = row.Field <DateTime?>("duedt");
            entity.reqshipdt      = row.Field <DateTime?>("reqshipdt");
            entity.shipdt         = row.Field <DateTime?>("shipdt");
            entity.receiptdt      = row.Field <DateTime?>("receiptdt");
            entity.totlineamt     = row.IsNull("totlineamt") ? decimal.Zero : row.Field <decimal>("totlineamt");
            entity.cono2          = row.IsNull("cono2") ? 0 : row.Field <int>("cono2");
            entity.rowidWteh      = row.Field <byte[]>("rowid-wteh").ToStringEncoded();
            return(entity);
        }