/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromEtccdoclistcomcriteria(ref DataRow row, Etccdoclistcomcriteria entity) { row.SetField("transid", entity.transid); row.SetField("module", entity.module); row.SetField("proctype", entity.proctype); row.SetField("transtype", entity.transtype); row.SetField("transstat", entity.transstat); row.SetField("updstat", entity.updstat); row.SetField("createdtstart", entity.createdtstart); row.SetField("createdtend", entity.createdtend); row.SetField("hourfrom", entity.hourfrom); row.SetField("minutefrom", entity.minutefrom); row.SetField("typefrom", entity.typefrom); row.SetField("hourto", entity.hourto); row.SetField("minuteto", entity.minuteto); row.SetField("typeto", entity.typeto); row.SetField("recordcountlimit", entity.recordcountlimit); row.SetField("userfield", entity.userfield); }
public static Etccdoclistcomcriteria BuildEtccdoclistcomcriteriaFromRow(DataRow row) { Etccdoclistcomcriteria entity = new Etccdoclistcomcriteria(); entity.transid = row.IsNull("transid") ? 0 : row.Field <int>("transid"); entity.module = row.IsNull("module") ? string.Empty : row.Field <string>("module"); entity.proctype = row.IsNull("proctype") ? string.Empty : row.Field <string>("proctype"); entity.transtype = row.IsNull("transtype") ? string.Empty : row.Field <string>("transtype"); entity.transstat = row.IsNull("transstat") ? string.Empty : row.Field <string>("transstat"); entity.updstat = row.IsNull("updstat") ? string.Empty : row.Field <string>("updstat"); entity.createdtstart = row.Field <DateTime?>("createdtstart"); entity.createdtend = row.Field <DateTime?>("createdtend"); entity.hourfrom = row.IsNull("hourfrom") ? 0 : row.Field <int>("hourfrom"); entity.minutefrom = row.IsNull("minutefrom") ? 0 : row.Field <int>("minutefrom"); entity.typefrom = row.IsNull("typefrom") ? string.Empty : row.Field <string>("typefrom"); entity.hourto = row.IsNull("hourto") ? 0 : row.Field <int>("hourto"); entity.minuteto = row.IsNull("minuteto") ? 0 : row.Field <int>("minuteto"); entity.typeto = row.IsNull("typeto") ? string.Empty : row.Field <string>("typeto"); entity.recordcountlimit = row.IsNull("recordcountlimit") ? 0 : row.Field <int>("recordcountlimit"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }