/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromKpworkorderlist(ref DataRow row, Kpworkorderlist entity) { row.SetField("wono", entity.wono); row.SetField("wosuf", entity.wosuf); row.SetField("wono-c", entity.wonoC); row.SetField("userfield", entity.userfield); }
public static Kpworkorderlist BuildKpworkorderlistFromRow(DataRow row) { Kpworkorderlist entity = new Kpworkorderlist(); entity.wono = row.IsNull("wono") ? 0 : row.Field <int>("wono"); entity.wosuf = row.IsNull("wosuf") ? 0 : row.Field <int>("wosuf"); entity.wonoC = row.IsNull("wono-c") ? string.Empty : row.Field <string>("wono-c"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }