/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromLoadwlcartonscriteria(ref DataRow row, Loadwlcartonscriteria entity) { row.SetField("whse", entity.whse); row.SetField("orderno", entity.orderno); row.SetField("ordersuf", entity.ordersuf); row.SetField("seqno", entity.seqno); row.SetField("ordertype", entity.ordertype); row.SetField("customparam", entity.customparam); }
public static Loadwlcartonscriteria BuildLoadwlcartonscriteriaFromRow(DataRow row) { Loadwlcartonscriteria entity = new Loadwlcartonscriteria(); entity.whse = row.IsNull("whse") ? string.Empty : row.Field <string>("whse"); entity.orderno = row.IsNull("orderno") ? 0 : row.Field <int>("orderno"); entity.ordersuf = row.IsNull("ordersuf") ? 0 : row.Field <int>("ordersuf"); entity.seqno = row.IsNull("seqno") ? 0 : row.Field <int>("seqno"); entity.ordertype = row.IsNull("ordertype") ? string.Empty : row.Field <string>("ordertype"); entity.customparam = row.IsNull("customparam") ? string.Empty : row.Field <string>("customparam"); return(entity); }