Ejemplo n.º 1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromWavepickwaves(ref DataRow row, Wavepickwaves entity)
 {
     row.SetField("co_num", entity.coNum);
     row.SetField("wh_num", entity.whNum);
     row.SetField("emp_num", entity.empNum);
     row.SetField("batchid", entity.batchid);
     row.SetField("order", entity.order);
     row.SetField("order_suffix", entity.orderSuffix);
     row.SetField("drop_date_time", entity.dropDateTime);
     row.SetField("userfield", entity.userfield);
 }
Ejemplo n.º 2
0
        public static Wavepickwaves BuildWavepickwavesFromRow(DataRow row)
        {
            Wavepickwaves entity = new Wavepickwaves();

            entity.coNum        = row.IsNull("co_num") ? string.Empty : row.Field <string>("co_num");
            entity.whNum        = row.IsNull("wh_num") ? string.Empty : row.Field <string>("wh_num");
            entity.empNum       = row.IsNull("emp_num") ? string.Empty : row.Field <string>("emp_num");
            entity.batchid      = row.IsNull("batchid") ? 0 : row.Field <int>("batchid");
            entity.order        = row.IsNull("order") ? string.Empty : row.Field <string>("order");
            entity.orderSuffix  = row.IsNull("order_suffix") ? string.Empty : row.Field <string>("order_suffix");
            entity.dropDateTime = row.IsNull("drop_date_time") ? string.Empty : row.Field <string>("drop_date_time");
            entity.userfield    = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }