Exemple #1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromLoadwteecriteria(ref DataRow row, Loadwteecriteria entity)
 {
     row.SetField("wtno", entity.wtno);
     row.SetField("wtsuf", entity.wtsuf);
     row.SetField("currentjrnlno", entity.currentjrnlno);
     row.SetField("shipfmwhse", entity.shipfmwhse);
     row.SetField("shiptowhse", entity.shiptowhse);
     row.SetField("tocono", entity.tocono);
     row.SetField("wtfl", entity.wtfl);
     row.SetField("dofl", entity.dofl);
     row.SetField("sort1", entity.sort1);
     row.SetField("sort2", entity.sort2);
     row.SetField("irecordcountlimit", entity.irecordcountlimit);
 }
Exemple #2
0
        public static Loadwteecriteria BuildLoadwteecriteriaFromRow(DataRow row)
        {
            Loadwteecriteria entity = new Loadwteecriteria();

            entity.wtno              = row.IsNull("wtno") ? 0 : row.Field <int>("wtno");
            entity.wtsuf             = row.IsNull("wtsuf") ? 0 : row.Field <int>("wtsuf");
            entity.currentjrnlno     = row.IsNull("currentjrnlno") ? 0 : row.Field <int>("currentjrnlno");
            entity.shipfmwhse        = row.IsNull("shipfmwhse") ? string.Empty : row.Field <string>("shipfmwhse");
            entity.shiptowhse        = row.IsNull("shiptowhse") ? string.Empty : row.Field <string>("shiptowhse");
            entity.tocono            = row.IsNull("tocono") ? 0 : row.Field <int>("tocono");
            entity.wtfl              = row.Field <bool>("wtfl");
            entity.dofl              = row.Field <bool>("dofl");
            entity.sort1             = row.IsNull("sort1") ? string.Empty : row.Field <string>("sort1");
            entity.sort2             = row.IsNull("sort2") ? string.Empty : row.Field <string>("sort2");
            entity.irecordcountlimit = row.IsNull("irecordcountlimit") ? 0 : row.Field <int>("irecordcountlimit");
            return(entity);
        }