/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromVasectionresetcriteria(ref DataRow row, Vasectionresetcriteria entity) { row.SetField("updateall", entity.updateall); row.SetField("oper2", entity.oper2); row.SetField("workdate", entity.workdate); row.SetField("vano", entity.vano); row.SetField("vasuf", entity.vasuf); row.SetField("seqno", entity.seqno); row.SetField("userfield", entity.userfield); }
public static Vasectionresetcriteria BuildVasectionresetcriteriaFromRow(DataRow row) { Vasectionresetcriteria entity = new Vasectionresetcriteria(); entity.updateall = row.Field <bool>("updateall"); entity.oper2 = row.IsNull("oper2") ? string.Empty : row.Field <string>("oper2"); entity.workdate = row.Field <DateTime?>("workdate"); entity.vano = row.IsNull("vano") ? 0 : row.Field <int>("vano"); entity.vasuf = row.IsNull("vasuf") ? 0 : row.Field <int>("vasuf"); entity.seqno = row.IsNull("seqno") ? 0 : row.Field <int>("seqno"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }