/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromIcswordunitcriteria(ref DataRow row, Icswordunitcriteria entity) { row.SetField("product", entity.product); row.SetField("unitbuy", entity.unitbuy); row.SetField("unitstnd", entity.unitstnd); row.SetField("unitwt", entity.unitwt); row.SetField("userfield", entity.userfield); }
public static Icswordunitcriteria BuildIcswordunitcriteriaFromRow(DataRow row) { Icswordunitcriteria entity = new Icswordunitcriteria(); entity.product = row.IsNull("product") ? string.Empty : row.Field <string>("product"); entity.unitbuy = row.IsNull("unitbuy") ? string.Empty : row.Field <string>("unitbuy"); entity.unitstnd = row.IsNull("unitstnd") ? string.Empty : row.Field <string>("unitstnd"); entity.unitwt = row.IsNull("unitwt") ? string.Empty : row.Field <string>("unitwt"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }