Beispiel #1
0
        public GameWinNumber_Info QueryWinNumber(string issuseNumber)
        {
            var manager = new GDKLSF_GameWinNumberManager();
            var entity  = manager.QueryWinNumber(issuseNumber);

            if (entity == null)
            {
                return(new GameWinNumber_Info());
            }
            var info = new GameWinNumber_Info();

            ObjectConvert.ConverEntityToInfo <GDKLSF_GameWinNumber, GameWinNumber_Info>(entity, ref info);
            return(info);
        }
Beispiel #2
0
        public GameWinNumber_InfoCollection QueryGDKLSF_GameWinNumberDesc(DateTime startTime, DateTime endTime, int pageIndex, int pageSize)
        {
            GameWinNumber_InfoCollection collection = new GameWinNumber_InfoCollection();
            var totalCount = 0;
            var infoList   = new List <GameWinNumber_Info>();
            var entityList = new GDKLSF_GameWinNumberManager().QueryGDKLSF_GameWinNumberDesc(startTime, endTime, pageIndex, pageSize, out totalCount);

            ObjectConvert.ConvertEntityListToInfoList <List <GDKLSF_GameWinNumber>, GDKLSF_GameWinNumber, List <GameWinNumber_Info>, GameWinNumber_Info>(entityList, ref infoList,
                                                                                                                                                         () => { return(new GameWinNumber_Info()); },
                                                                                                                                                         (entity, info) =>
            {
                //处理info里面有,页entity里面没有的属性
                //info.WinNumber = entity.WinNumber;
            });
            collection.TotalCount = totalCount;
            collection.List.AddRange(infoList);
            return(collection);
        }
Beispiel #3
0
        public void Add_GameWinNumber(string issuseNumber, string winNumber)
        {
            new KJGameIssuseBusiness().IssusePrize(this.CurrentGameCode, issuseNumber, winNumber);
            var manager = new GDKLSF_GameWinNumberManager();
            var exist   = manager.QueryWinNumber(issuseNumber);

            if (exist != null)
            {
                return;
            }

            manager.AddGDKLSF_GameWinNumber(new GDKLSF_GameWinNumber
            {
                GameCode     = this.CurrentGameCode,
                IssuseNumber = issuseNumber,
                WinNumber    = winNumber,
                CreateTime   = DateTime.Now,
            });
        }
Beispiel #4
0
        /// <summary>
        /// 查询开奖数据
        /// </summary>
        public GameWinNumber_InfoCollection QueryGDKLSF_GameWinNumber(int pageIndex, int pageSize)
        {
            GameWinNumber_InfoCollection collection = new GameWinNumber_InfoCollection();
            var totalCount = 0;
            var infoList   = new List <GameWinNumber_Info>();
            var entityList = new GDKLSF_GameWinNumberManager().QueryGDKLSF_GameWinNumber(pageIndex, pageSize, out totalCount);

            ObjectConvert.ConvertEntityListToInfoList <List <GDKLSF_GameWinNumber>, GDKLSF_GameWinNumber, List <GameWinNumber_Info>, GameWinNumber_Info>(entityList, ref infoList,
                                                                                                                                                         () => { return(new GameWinNumber_Info()); },
                                                                                                                                                         (entity, info) =>
            {
                //处理info里面有,页entity里面没有的属性
                //info.WinNumber = entity.WinNumber;
            });
            collection.TotalCount = totalCount;
            collection.List.AddRange(infoList);
            return(collection);

            //string key = string.Format("QueryGDKLSF_GameWinNumber_{0}_{1}", pageIndex, pageSize);
            //return QueryNewWinNumber(key, () =>
            //{
            //    GameWinNumber_InfoCollection collection = new GameWinNumber_InfoCollection();
            //    var totalCount = 0;
            //    var infoList = new List<GameWinNumber_Info>();
            //    var entityList = new GDKLSF_GameWinNumberManager().QueryGDKLSF_GameWinNumber(pageIndex, pageSize, out totalCount);

            //   ObjectConvert.ConvertEntityListToInfoList<List<GDKLSF_GameWinNumber>, GDKLSF_GameWinNumber, List<GameWinNumber_Info>, GameWinNumber_Info>(entityList, ref infoList,
            //        () => { return new GameWinNumber_Info(); },
            //        (entity, info) =>
            //        {
            //            //处理info里面有,页entity里面没有的属性
            //            //info.WinNumber = entity.WinNumber;
            //        });
            //    collection.TotalCount = totalCount;
            //    collection.List.AddRange(infoList);
            //    return collection;
            //});
        }