/// <summary> /// Update a database row from a class /// </summary> public static void UpdateRowFromOetenderingupdatecriteria(ref DataRow row, Oetenderingupdatecriteria entity) { row.SetField("jrnlno", entity.jrnlno); row.SetField("orderno", entity.orderno); row.SetField("ordersuf", entity.ordersuf); row.SetField("dwnpmtamt", entity.dwnpmtamt); row.SetField("crdivno", entity.crdivno); row.SetField("codfl", entity.codfl); row.SetField("chgdue", entity.chgdue); row.SetField("bankno", entity.bankno); row.SetField("maint", entity.maint); row.SetField("holdforauth", entity.holdforauth); row.SetField("nonrefundfl", entity.nonrefundfl); row.SetField("userfield", entity.userfield); }
public static Oetenderingupdatecriteria BuildOetenderingupdatecriteriaFromRow(DataRow row) { Oetenderingupdatecriteria entity = new Oetenderingupdatecriteria(); entity.jrnlno = row.IsNull("jrnlno") ? 0 : row.Field <int>("jrnlno"); entity.orderno = row.IsNull("orderno") ? 0 : row.Field <int>("orderno"); entity.ordersuf = row.IsNull("ordersuf") ? 0 : row.Field <int>("ordersuf"); entity.dwnpmtamt = row.IsNull("dwnpmtamt") ? decimal.Zero : row.Field <decimal>("dwnpmtamt"); entity.crdivno = row.IsNull("crdivno") ? 0 : row.Field <int>("crdivno"); entity.codfl = row.Field <bool>("codfl"); entity.chgdue = row.IsNull("chgdue") ? decimal.Zero : row.Field <decimal>("chgdue"); entity.bankno = row.IsNull("bankno") ? 0 : row.Field <int>("bankno"); entity.maint = row.Field <bool>("maint"); entity.holdforauth = row.Field <bool>("holdforauth"); entity.nonrefundfl = row.Field <bool>("nonrefundfl"); entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield"); return(entity); }