Esempio n. 1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromVaordercfg(ref DataRow row, Vaordercfg entity)
 {
     row.SetField("vano", entity.vano);
     row.SetField("vasuf", entity.vasuf);
     row.SetField("shipprod", entity.shipprod);
     row.SetField("redirecturl", entity.redirecturl);
     row.SetField("securitylvl", entity.securitylvl);
     row.SetField("userfield", entity.userfield);
 }
Esempio n. 2
0
        public static Vaordercfg BuildVaordercfgFromRow(DataRow row)
        {
            Vaordercfg entity = new Vaordercfg();

            entity.vano        = row.IsNull("vano") ? 0 : row.Field <int>("vano");
            entity.vasuf       = row.IsNull("vasuf") ? 0 : row.Field <int>("vasuf");
            entity.shipprod    = row.IsNull("shipprod") ? string.Empty : row.Field <string>("shipprod");
            entity.redirecturl = row.IsNull("redirecturl") ? string.Empty : row.Field <string>("redirecturl");
            entity.securitylvl = row.IsNull("securitylvl") ? 0 : row.Field <int>("securitylvl");
            entity.userfield   = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }