Пример #1
0
        public static Wtialinecriteria BuildWtialinecriteriaFromRow(DataRow row)
        {
            Wtialinecriteria entity = new Wtialinecriteria();

            entity.wtno      = row.IsNull("wtno") ? 0 : row.Field <int>("wtno");
            entity.wtsuf     = row.IsNull("wtsuf") ? 0 : row.Field <int>("wtsuf");
            entity.userfield = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }
Пример #2
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromWtialinecriteria(ref DataRow row, Wtialinecriteria entity)
 {
     row.SetField("wtno", entity.wtno);
     row.SetField("wtsuf", entity.wtsuf);
     row.SetField("userfield", entity.userfield);
 }