/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromSaealistpcat(ref DataRow row, Saealistpcat entity) { row.SetField("listtype", entity.listtype); row.SetField("listvalue", entity.listvalue); row.SetField("namedesc", entity.namedesc); row.SetField("pcatuser", entity.pcatuser); row.SetField("userfield", entity.userfield); }
public static Saealistpcat BuildSaealistpcatFromRow(DataRow row) { Saealistpcat entity = new Saealistpcat(); entity.listtype = row.IsNull("listtype") ? string.Empty : row.Field <string>("listtype"); entity.listvalue = row.IsNull("listvalue") ? string.Empty : row.Field <string>("listvalue"); entity.namedesc = row.IsNull("namedesc") ? string.Empty : row.Field <string>("namedesc"); entity.pcatuser = row.IsNull("pcatuser") ? string.Empty : row.Field <string>("pcatuser"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }