/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromOelinelinetietypecrit(ref DataRow row, Oelinelinetietypecrit entity) { row.SetField("runmode", entity.runmode); row.SetField("product", entity.product); row.SetField("ourproc", entity.ourproc); row.SetField("specnstype", entity.specnstype); row.SetField("whse", entity.whse); row.SetField("transtype", entity.transtype); row.SetField("returnfl", entity.returnfl); row.SetField("returnty", entity.returnty); row.SetField("botype", entity.botype); row.SetField("userfield", entity.userfield); }
public static Oelinelinetietypecrit BuildOelinelinetietypecritFromRow(DataRow row) { Oelinelinetietypecrit entity = new Oelinelinetietypecrit(); entity.runmode = row.IsNull("runmode") ? string.Empty : row.Field <string>("runmode"); entity.product = row.IsNull("product") ? string.Empty : row.Field <string>("product"); entity.ourproc = row.IsNull("ourproc") ? string.Empty : row.Field <string>("ourproc"); entity.specnstype = row.IsNull("specnstype") ? string.Empty : row.Field <string>("specnstype"); entity.whse = row.IsNull("whse") ? string.Empty : row.Field <string>("whse"); entity.transtype = row.IsNull("transtype") ? string.Empty : row.Field <string>("transtype"); entity.returnfl = row.Field <bool>("returnfl"); entity.returnty = row.IsNull("returnty") ? string.Empty : row.Field <string>("returnty"); entity.botype = row.IsNull("botype") ? string.Empty : row.Field <string>("botype"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }