예제 #1
0
파일: ConstructDAO.cs 프로젝트: ishui/rms2
        public static EntityData GetLastVisualProgress(string ProgressType)
        {
            EntityData data2;

            try
            {
                VisualProgressStrategyBuilder builder = new VisualProgressStrategyBuilder();
                if (ProgressType != "")
                {
                    builder.AddStrategy(new Strategy(VisualProgressStrategyName.ProgressType, ProgressType.ToString()));
                }
                builder.AddOrder("SortID", false);
                string     queryString = builder.BuildMainQueryString();
                QueryAgent agent       = new QueryAgent();
                agent.SetTopNumber(1);
                EntityData data = agent.FillEntityData("VisualProgress", queryString);
                agent.Dispose();
                data2 = data;
            }
            catch (Exception exception)
            {
                throw exception;
            }
            return(data2);
        }
예제 #2
0
파일: ConstructDAO.cs 프로젝트: ishui/rms2
        public static EntityData GetVisualProgressByProgressType(int ProgressType)
        {
            EntityData data2;

            try
            {
                VisualProgressStrategyBuilder builder = new VisualProgressStrategyBuilder();
                builder.AddStrategy(new Strategy(VisualProgressStrategyName.ProgressType, ProgressType.ToString()));
                builder.AddOrder("SortID", true);
                string     queryString = builder.BuildMainQueryString();
                QueryAgent agent       = new QueryAgent();
                EntityData data        = agent.FillEntityData("VisualProgress", queryString);
                agent.Dispose();
                data2 = data;
            }
            catch (Exception exception)
            {
                throw exception;
            }
            return(data2);
        }