Exemple #1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromOedisccalcupdatecriteria(ref DataRow row, Oedisccalcupdatecriteria entity)
 {
     row.SetField("orderno", entity.orderno);
     row.SetField("ordersuf", entity.ordersuf);
     row.SetField("totalsale", entity.totalsale);
     row.SetField("marginamt", entity.marginamt);
     row.SetField("expressedasfl", entity.expressedasfl);
     row.SetField("lotpricefl", entity.lotpricefl);
 }
Exemple #2
0
        public static Oedisccalcupdatecriteria BuildOedisccalcupdatecriteriaFromRow(DataRow row)
        {
            Oedisccalcupdatecriteria entity = new Oedisccalcupdatecriteria();

            entity.orderno       = row.IsNull("orderno") ? 0 : row.Field <int>("orderno");
            entity.ordersuf      = row.IsNull("ordersuf") ? 0 : row.Field <int>("ordersuf");
            entity.totalsale     = row.IsNull("totalsale") ? decimal.Zero : row.Field <decimal>("totalsale");
            entity.marginamt     = row.IsNull("marginamt") ? decimal.Zero : row.Field <decimal>("marginamt");
            entity.expressedasfl = row.Field <bool>("expressedasfl");
            entity.lotpricefl    = row.Field <bool>("lotpricefl");
            return(entity);
        }