Example #1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromWtlineretrievecriteria(ref DataRow row, Wtlineretrievecriteria entity)
 {
     row.SetField("wtno", entity.wtno);
     row.SetField("wtsuf", entity.wtsuf);
     row.SetField("lineno", entity.lineno);
     row.SetField("maintmode", entity.maintmode);
     row.SetField("readonlyfl", entity.readonlyfl);
     row.SetField("userfield", entity.userfield);
 }
Example #2
0
        public static Wtlineretrievecriteria BuildWtlineretrievecriteriaFromRow(DataRow row)
        {
            Wtlineretrievecriteria entity = new Wtlineretrievecriteria();

            entity.wtno       = row.IsNull("wtno") ? 0 : row.Field <int>("wtno");
            entity.wtsuf      = row.IsNull("wtsuf") ? 0 : row.Field <int>("wtsuf");
            entity.lineno     = row.IsNull("lineno") ? 0 : row.Field <int>("lineno");
            entity.maintmode  = row.Field <bool>("maintmode");
            entity.readonlyfl = row.Field <bool>("readonlyfl");
            entity.userfield  = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }