예제 #1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromPickalloccriteria(ref DataRow row, Pickalloccriteria entity)
 {
     row.SetField("co_num", entity.coNum);
     row.SetField("wh_num", entity.whNum);
     row.SetField("order", entity.order);
     row.SetField("order_suffix", entity.orderSuffix);
     row.SetField("line", entity.line);
     row.SetField("line_sequence", entity.lineSequence);
     row.SetField("abs_num", entity.absNum);
     row.SetField("avail_only", entity.availOnly);
     row.SetField("unavail_only", entity.unavailOnly);
     row.SetField("bin_num", entity.binNum);
     row.SetField("userfield", entity.userfield);
 }
예제 #2
0
        public static Pickalloccriteria BuildPickalloccriteriaFromRow(DataRow row)
        {
            Pickalloccriteria entity = new Pickalloccriteria();

            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.order        = row.IsNull("order") ? string.Empty : row.Field <string>("order");
            entity.orderSuffix  = row.IsNull("order_suffix") ? string.Empty : row.Field <string>("order_suffix");
            entity.line         = row.IsNull("line") ? 0 : row.Field <int>("line");
            entity.lineSequence = row.IsNull("line_sequence") ? 0 : row.Field <int>("line_sequence");
            entity.absNum       = row.IsNull("abs_num") ? string.Empty : row.Field <string>("abs_num");
            entity.availOnly    = row.Field <bool>("avail_only");
            entity.unavailOnly  = row.Field <bool>("unavail_only");
            entity.binNum       = row.IsNull("bin_num") ? string.Empty : row.Field <string>("bin_num");
            entity.userfield    = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }