Exemplo n.º 1
0
        public List <UserAccountRecordInfo> ReadUserAccountRecordList(int currentPage, int pageSize, ref int count, int userID, int accountType)
        {
            List <UserAccountRecordInfo> userAccountRecordList = new List <UserAccountRecordInfo>();
            ShopMssqlPagerClass          class2 = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "UserAccountRecord";
            class2.Fields      = "[ID],[Money],[Point],[Date],[IP],[Note],[UserID],[UserName]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Asc;
            class2.MssqlCondition.Add("[UserID]", userID, ConditionType.Equal);
            if (accountType == 1)
            {
                class2.MssqlCondition.Add("[Money]!=0");
            }
            else
            {
                class2.MssqlCondition.Add("[Point]!=0");
            }
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareUserAccountRecordModel(reader, userAccountRecordList);
            }
            return(userAccountRecordList);
        }
Exemplo n.º 2
0
        public List <ProductInfo> SearchProductList(int currentPage, int pageSize, ProductSearchInfo productSearch, ref int count)
        {
            List <ProductInfo>  productList = new List <ProductInfo>();
            ShopMssqlPagerClass class2      = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "Product";
            class2.Fields      = "[ID],[Name],[Spelling],[Color],[FontStyle],[ProductNumber],[ClassID],[BrandID],[MarketPrice],[Weight],[SendPoint],[Photo],[Keywords],[Summary],[IsSpecial],[IsNew],[IsHot],[IsSale],[IsTop],[Accessory],[RelationProduct],[RelationArticle],[ViewCount],[AllowComment],[CommentCount],[SumPoint],[PerPoint],[PhotoCount],[CollectCount],[TotalStorageCount],[OrderCount],[SendCount],[ImportActualStorageCount],[ImportVirtualStorageCount],[LowerCount],[UpperCount],[AttributeClassID],[StandardType],[AddDate],[CompanyID],[Sort],[Editor],[Introduction]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            if (string.IsNullOrEmpty(productSearch.OrderField))
            {
                class2.OrderField = "[ID]";
            }
            else
            {
                class2.OrderField = productSearch.OrderField;
            }
            if (productSearch.ProductOrderType != string.Empty)
            {
                string productOrderType = productSearch.ProductOrderType;
                if (productOrderType != null)
                {
                    if (!(productOrderType == "CommentCount"))
                    {
                        if (productOrderType == "PerPoint")
                        {
                            class2.OrderField = "[PerPoint],[ID]";
                        }
                        else if (productOrderType == "CollectCount")
                        {
                            class2.OrderField = "[CollectCount],[ID]";
                        }
                        else if (productOrderType == "ViewCount")
                        {
                            class2.OrderField = "[ViewCount],[ID]";
                        }
                    }
                    else
                    {
                        class2.OrderField = "[CommentCount],[ID]";
                    }
                }
            }
            class2.OrderType = productSearch.OrderType;
            this.PrepareCondition(class2.MssqlCondition, productSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareProductModel(reader, productList);
            }
            return(productList);
        }
Exemplo n.º 3
0
        public DataTable StatisticsProductSale(int currentPage, int pageSize, ProductSearchInfo productSearch, ref int count, DateTime startDate, DateTime endDate)
        {
            ShopMssqlPagerClass class2;
            List <ProductInfo>  list = new List <ProductInfo>();
            string         str       = string.Empty;
            MssqlCondition condition = new MssqlCondition();

            condition.Add("[AddDate]", startDate, ConditionType.MoreOrEqual);
            condition.Add("[AddDate]", endDate, ConditionType.Less);
            str = condition.ToString();
            if (str != string.Empty)
            {
                str = " AND" + str;
            }
            class2           = new ShopMssqlPagerClass();
            class2.TableName = "(SELECT ID,Name,ClassID,BrandID,IsSale, ISNULL(SellCount, 0) AS SellCount, ISNULL(SellMoney,0) AS SellMoney FROM " + ShopMssqlHelper.TablePrefix + "Product ";
            class2.TableName = class2.TableName + "LEFT OUTER JOIN (SELECT ProductID, SUM(BuyCount) AS SellCount, SUM(ProductPrice * BuyCount) AS SellMoney FROM ( ";
            string tableName = class2.TableName;

            class2.TableName   = tableName + "SELECT " + ShopMssqlHelper.TablePrefix + "OrderDetail.ProductID," + ShopMssqlHelper.TablePrefix + "OrderDetail.ProductPrice, " + ShopMssqlHelper.TablePrefix + "OrderDetail.BuyCount FROM " + ShopMssqlHelper.TablePrefix + "OrderDetail ";
            tableName          = class2.TableName;
            class2.TableName   = tableName + " INNER JOIN [" + ShopMssqlHelper.TablePrefix + "Order] ON " + ShopMssqlHelper.TablePrefix + "OrderDetail.OrderID = [" + ShopMssqlHelper.TablePrefix + "Order].ID WHERE ([" + ShopMssqlHelper.TablePrefix + "Order].OrderStatus = 6 " + str + ")) AS TEMP1 GROUP BY ProductID) AS TEMP2 ON " + ShopMssqlHelper.TablePrefix + "Product.ID = TEMP2.ProductID) As PageTable";
            class2.Fields      = "[ID],[Name],[ClassID],[SellCount],[SellMoney]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            if (productSearch.ProductOrderType != string.Empty)
            {
                string productOrderType = productSearch.ProductOrderType;
                if (productOrderType != null)
                {
                    if (!(productOrderType == "SellCount"))
                    {
                        if (productOrderType == "SellMoney")
                        {
                            class2.OrderField = "[SellMoney],[ID]";
                        }
                    }
                    else
                    {
                        class2.OrderField = "[SellCount],[ID]";
                    }
                }
            }
            class2.OrderType = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, productSearch);
            class2.Count = count;
            count        = class2.Count;
            return(class2.ExecuteDataTable());
        }
Exemplo n.º 4
0
        public DataTable StatisticsSaleDetail(int currentPage, int pageSize, OrderSearchInfo orderSearch, ProductSearchInfo productSearch, ref int count)
        {
            ShopMssqlPagerClass class2 = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "View_SaleDetail";
            class2.Fields      = "[Name],[ClassID],[BrandID],[BuyCount],[Money],[OrderNumber],[AddDate],[UserName]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[AddDate],[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, orderSearch, productSearch);
            class2.Count = count;
            count        = class2.Count;
            return(class2.ExecuteDataTable());
        }
Exemplo n.º 5
0
        public DataTable StatisticsUserActive(int currentPage, int pageSize, UserSearchInfo userSearch, ref int count, string orderField)
        {
            List <UserInfo>     list   = new List <UserInfo>();
            ShopMssqlPagerClass class2 = new ShopMssqlPagerClass();
            {
                class2.TableName   = ShopMssqlHelper.TablePrefix + "View_UserActive";
                class2.Fields      = "[ID],[UserName],[Sex],[RegisterDate],[LoginTimes],[CommentCount],[ReplyCount],[MessageCount]";
                class2.CurrentPage = currentPage;
                class2.PageSize    = pageSize;
            }
            string str = orderField;

            if (str != null)
            {
                if (!(str == "LoginTimes"))
                {
                    if (str == "CommentCount")
                    {
                        class2.OrderField = "[CommentCount],[ID]";
                        goto Label_00C1;
                    }
                    if (str == "ReplyCount")
                    {
                        class2.OrderField = "[ReplyCount],[ID]";
                        goto Label_00C1;
                    }
                    if (str == "MessageCount")
                    {
                        class2.OrderField = "[MessageCount],[ID]";
                        goto Label_00C1;
                    }
                }
                else
                {
                    class2.OrderField = "[LoginTimes],[ID]";
                    goto Label_00C1;
                }
            }
            class2.OrderField = "[LoginTimes],[ID]";
Label_00C1:
            class2.OrderType = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, userSearch);
            class2.Count = count;
            count        = class2.Count;
            return(class2.ExecuteDataTable());
        }
Exemplo n.º 6
0
 public List<AdInfo> ReadAdList(int classID, int currentPage, int pageSize, ref int count)
 {
     List<AdInfo> adList = new List<AdInfo>();
     ShopMssqlPagerClass class2 = new ShopMssqlPagerClass();
     class2.TableName = ShopMssqlHelper.TablePrefix + "Ad";
     class2.Fields = "[ID],[Title],[Introduction],[AdClass],[Display],[Width],[Height],[Url],[StartDate],[EndDate],[Remark],[ClickCount],[IsEnabled]";
     class2.CurrentPage = currentPage;
     class2.PageSize = pageSize;
     class2.OrderField = "[ID]";
     class2.OrderType = OrderType.Desc;
     class2.MssqlCondition.Add("[AdClass]", classID, ConditionType.Equal);
     count = class2.Count;
     using (SqlDataReader reader = class2.ExecuteReader())
     {
         this.PrepareAdModel(reader, adList);
     }
     return adList;
 }
Exemplo n.º 7
0
        public List <VoteInfo> ReadVoteList(int currentPage, int pageSize, ref int count)
        {
            List <VoteInfo>     voteList = new List <VoteInfo>();
            ShopMssqlPagerClass class2   = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "Vote";
            class2.Fields      = "[ID],[Title],[ItemCount],[VoteType],[Note]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.Count       = count;
            count = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareVoteModel(reader, voteList);
            }
            return(voteList);
        }
Exemplo n.º 8
0
 public List<UserApplyInfo> SearchUserApplyList(int currentPage, int pageSize, UserApplySearchInfo userApplySearch, ref int count)
 {
     List<UserApplyInfo> userApplyList = new List<UserApplyInfo>();
     ShopMssqlPagerClass class2 = new ShopMssqlPagerClass();
     class2.TableName = ShopMssqlHelper.TablePrefix + "UserApply";
     class2.Fields = "[ID],[Number],[Money],[UserNote],[Status],[ApplyDate],[ApplyIP],[AdminNote],[UpdateDate],[UpdateAdminID],[UpdateAdminName],[UserID],[UserName]";
     class2.CurrentPage = currentPage;
     class2.PageSize = pageSize;
     class2.OrderField = "[ID]";
     class2.OrderType = OrderType.Desc;
     this.PrepareCondition(class2.MssqlCondition, userApplySearch);
     class2.Count = count;
     count = class2.Count;
     using (SqlDataReader reader = class2.ExecuteReader())
     {
         this.PrepareUserApplyModel(reader, userApplyList);
     }
     return userApplyList;
 }
Exemplo n.º 9
0
        public List <GiftPackInfo> ReadGiftPackList(int currentPage, int pageSize, ref int count)
        {
            List <GiftPackInfo> giftPackList = new List <GiftPackInfo>();
            ShopMssqlPagerClass class2       = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "GiftPack";
            class2.Fields      = "[ID],[Name],[Photo],[StartDate],[EndDate],[Price],[GiftGroup]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.Count       = count;
            count = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareGiftPackModel(reader, giftPackList);
            }
            return(giftPackList);
        }
Exemplo n.º 10
0
        public List <AdminInfo> ReadAdminList(int currentPage, int pageSize, ref int count)
        {
            List <AdminInfo>    adminList = new List <AdminInfo>();
            ShopMssqlPagerClass class2    = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "Admin";
            class2.Fields      = "[ID],[Name],[Email],[GroupID],[Password],[LastLoginIP],[LastLoginDate],[LoginTimes],[NoteBook],[IsCreate]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.Count       = count;
            count = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareAdminModel(reader, adminList);
            }
            return(adminList);
        }
Exemplo n.º 11
0
        public List <FlashInfo> ReadFlashList(int currentPage, int pageSize, ref int count)
        {
            List <FlashInfo>    flashList = new List <FlashInfo>();
            ShopMssqlPagerClass class2    = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "Flash";
            class2.Fields      = "[ID],[Title],[Introduce],[Width],[Height],[PhotoCount]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.Count       = count;
            count = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareFlashModel(reader, flashList);
            }
            return(flashList);
        }
Exemplo n.º 12
0
 public List<GiftInfo> SearchGiftList(int currentPage, int pageSize, GiftSearchInfo giftSearch, ref int count)
 {
     List<GiftInfo> giftList = new List<GiftInfo>();
     ShopMssqlPagerClass class2 = new ShopMssqlPagerClass();
     class2.TableName = ShopMssqlHelper.TablePrefix + "Gift";
     class2.Fields = "[ID],[Name],[Photo],[Description]";
     class2.CurrentPage = currentPage;
     class2.PageSize = pageSize;
     class2.OrderField = "[ID]";
     class2.OrderType = OrderType.Desc;
     this.PrepareCondition(class2.MssqlCondition, giftSearch);
     class2.Count = count;
     count = class2.Count;
     using (SqlDataReader reader = class2.ExecuteReader())
     {
         this.PrepareGiftModel(reader, giftList);
     }
     return giftList;
 }
Exemplo n.º 13
0
        public List <FavorableActivityInfo> ReadFavorableActivityList(int currentPage, int pageSize, ref int count)
        {
            List <FavorableActivityInfo> favorableActivityList = new List <FavorableActivityInfo>();
            ShopMssqlPagerClass          class2 = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "FavorableActivity";
            class2.Fields      = "[ID],[Name],[Photo],[Content],[StartDate],[EndDate],[UserGrade],[OrderProductMoney],[RegionID],[ShippingWay],[ReduceWay],[ReduceMoney],[ReduceDiscount],[GiftID]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.Count       = count;
            count = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareFavorableActivityModel(reader, favorableActivityList);
            }
            return(favorableActivityList);
        }
Exemplo n.º 14
0
        public List <ThemeActivityInfo> ReadThemeActivityList(int currentPage, int pageSize, ref int count)
        {
            List <ThemeActivityInfo> themeActivityList = new List <ThemeActivityInfo>();
            ShopMssqlPagerClass      class2            = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "ThemeActivity";
            class2.Fields      = "[ID],[Name],[Photo],[Description],[Css],[ProductGroup],[Style]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.Count       = count;
            count = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareThemeActivityModel(reader, themeActivityList);
            }
            return(themeActivityList);
        }
Exemplo n.º 15
0
        public List <CourseInfo> ReadList(int currentPage, int pageSize, ref int count)
        {
            List <CourseInfo>   TempList = new List <CourseInfo>();
            ShopMssqlPagerClass class2   = new ShopMssqlPagerClass();

            class2.TableName   = "[" + ShopMssqlHelper.TablePrefix + "Course]";
            class2.Fields      = "*";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[CourseId]";
            class2.OrderType   = OrderType.Desc;
            class2.Count       = count;
            count = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareModel(reader, TempList);
            }
            return(TempList);
        }
Exemplo n.º 16
0
        public List <EmailSendRecordInfo> SearchEmailSendRecordList(int currentPage, int pageSize, EmailSendRecordSearchInfo emailSendRecordSearch, ref int count)
        {
            List <EmailSendRecordInfo> emailSendRecordList = new List <EmailSendRecordInfo>();
            ShopMssqlPagerClass        class2 = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "EmailSendRecord";
            class2.Fields      = "[ID],[Title],[Content],[IsSystem],[EmailList],[OpenEmailList],[IsStatisticsOpendEmail],[SendStatus],[Note],[AddDate],[SendDate]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, emailSendRecordSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareEmailSendRecordModel(reader, emailSendRecordList);
            }
            return(emailSendRecordList);
        }
Exemplo n.º 17
0
        public List <PostKPISettingInfo> SearchPostKPISettingList(PostKPISettingInfo info, int currentPage, int pageSize, ref int count)
        {
            List <PostKPISettingInfo> postKPISettingList = new List <PostKPISettingInfo>();
            ShopMssqlPagerClass       class2             = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "PostKPISetting";
            class2.Fields      = "*";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[Id]";
            class2.OrderType   = OrderType.Asc;
            this.PrepareCondition(class2.MssqlCondition, info);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader dr = class2.ExecuteReader())
            {
                this.PrepareModel(dr, postKPISettingList);
            }
            return(postKPISettingList);
        }
Exemplo n.º 18
0
        public List <CouponInfo> SearchCouponList(int currentPage, int pageSize, CouponSearchInfo couponSearch, ref int count)
        {
            List <CouponInfo>   couponList = new List <CouponInfo>();
            ShopMssqlPagerClass class2     = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "Coupon";
            class2.Fields      = "[ID],[Name],[Money],[UseMinAmount],[UseStartDate],[UseEndDate]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, couponSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareCouponModel(reader, couponList);
            }
            return(couponList);
        }
Exemplo n.º 19
0
        public List <PostPassInfo> ReadPostPassList(PostPassInfo postpassSearch, int currentPage, int pageSize, ref int count)
        {
            List <PostPassInfo> TempList = new List <PostPassInfo>();
            ShopMssqlPagerClass class2   = new ShopMssqlPagerClass();

            class2.TableName   = "[" + ShopMssqlHelper.TablePrefix + "PassPost]";
            class2.Fields      = "*";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[CreateDate]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, postpassSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader dr = class2.ExecuteReader())
            {
                this.PrepareModel(dr, TempList);
            }
            return(TempList);
        }
Exemplo n.º 20
0
        public List <WorkingPostInfo> SearchWorkingPostList(WorkingPostSearchInfo workingPostSearch, int currentPage, int pageSize, ref int count)
        {
            List <WorkingPostInfo> workingPostList = new List <WorkingPostInfo>();
            ShopMssqlPagerClass    class2          = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "WorkingPost";
            class2.Fields      = "*";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[Id]";
            class2.OrderType   = OrderType.Asc;
            this.PrepareCondition(class2.MssqlCondition, workingPostSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader dr = class2.ExecuteReader())
            {
                this.PrepareModel(dr, workingPostList);
            }
            return(workingPostList);
        }
Exemplo n.º 21
0
        public List <ProductReplyInfo> ReadProductReplyList(int currentPage, int pageSize, ref int count, int userID)
        {
            List <ProductReplyInfo> productReplyList = new List <ProductReplyInfo>();
            ShopMssqlPagerClass     class2           = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "ProductReply";
            class2.Fields      = "[ID],[ProductID],[CommentID],[Content],[UserIP],[PostDate],[UserID],[UserName]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.MssqlCondition.Add("[UserID]", userID, ConditionType.Equal);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareProductReplyModel(reader, productReplyList);
            }
            return(productReplyList);
        }
Exemplo n.º 22
0
        public List <UserInfo> SearchUserList(int currentPage, int pageSize, UserSearchInfo userSearch, ref int count)
        {
            List <UserInfo>     userList = new List <UserInfo>();
            ShopMssqlPagerClass class2   = new ShopMssqlPagerClass();

            class2.TableName   = "[" + ShopMssqlHelper.TablePrefix + "User]";
            class2.Fields      = "[ID],[UserName],[UserPassword],[Email],[Sex],[Introduce],[Photo],[MSN],[QQ],[Tel],[Mobile],[RegionID],[Address],[Birthday],[RegisterIP],[RegisterDate],[LastLoginIP],[LastLoginDate],[LoginTimes],[SafeCode],[FindDate],[Status],[OpenID],[GroupID],[RealName],[CompanyID],[WorkingPostID],[StudyPostID],[WorkingPostName],[Department],[IDCard],[PostStartDate],[EntryDate]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, userSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareUserModel(reader, userList);
            }
            return(userList);
        }
Exemplo n.º 23
0
        public List <ProductCommentInfo> SearchProductCommentList(int currentPage, int pageSize, ProductCommentSearchInfo productCommentSearch, ref int count)
        {
            List <ProductCommentInfo> productCommentList = new List <ProductCommentInfo>();
            ShopMssqlPagerClass       class2             = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "ProductComment";
            class2.Fields      = "[ID],[ProductID],[Title],[Content],[UserIP],[PostDate],[Support],[Against],[Status],[Rank],[ReplyCount],[AdminReplyContent],[AdminReplyDate],[UserID],[UserName]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, productCommentSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareProductCommentModel(reader, productCommentList);
            }
            return(productCommentList);
        }
Exemplo n.º 24
0
        /// <summary>
        /// 查询公司变化记录 带分页
        /// </summary>
        /// <param name="currentPage"></param>
        /// <param name="pageSize"></param>
        /// <param name="RecordSearch"></param>
        /// <param name="count"></param>
        /// <returns></returns>
        public List <CompanyRuleInfo> CompanyRuleList(int currentPage, int pageSize, CompanyRuleInfo RuleSearch, ref int count)
        {
            List <CompanyRuleInfo> RuleList = new List <CompanyRuleInfo>();
            ShopMssqlPagerClass    class2   = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "CompanyRule";
            class2.Fields      = "*";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[Id]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, RuleSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareModel(reader, RuleList);
            }
            return(RuleList);
        }
Exemplo n.º 25
0
        /// <summary>
        /// 查询公司变化记录 带分页
        /// </summary>
        /// <param name="currentPage"></param>
        /// <param name="pageSize"></param>
        /// <param name="RecordSearch"></param>
        /// <param name="count"></param>
        /// <returns></returns>
        public List <ProRecordInfo> UserRecordList(int currentPage, int pageSize, ProRecordInfo RecordSearch, ref int count)
        {
            List <ProRecordInfo> RecordList = new List <ProRecordInfo>();
            ShopMssqlPagerClass  class2     = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "ProRecord";
            class2.Fields      = "[Id],[UserID],[ChangeNum],[Reason],[CreateDate]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[CreateDate]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, RecordSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareUserModel(reader, RecordList);
            }
            return(RecordList);
        }
Exemplo n.º 26
0
        public List <EvaluateNameInfo> SearchEvaluateNameList(EvaluateNameInfo evaluateName, int currentPage, int pageSize, ref int count)
        {
            List <EvaluateNameInfo> evaluateNameList = new List <EvaluateNameInfo>();
            ShopMssqlPagerClass     class2           = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "EvaluateName";
            class2.Fields      = "[Id],[EvaluateName],CONVERT(varchar(100), [StartDate], 23) as [StartDate],CONVERT(varchar(100), [EndDate], 23) as [EndDate],CONVERT(varchar(100), [Date], 23) as [Date],[CompanyId],[State]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, evaluateName);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader dr = class2.ExecuteReader())
            {
                this.PrepareModel(dr, evaluateNameList);
            }
            return(evaluateNameList);
        }
Exemplo n.º 27
0
        public List <UserMessageInfo> SearchUserMessageList(int currentPage, int pageSize, UserMessageSeachInfo userMessageSearch, ref int count)
        {
            List <UserMessageInfo> userMessageList = new List <UserMessageInfo>();
            ShopMssqlPagerClass    class2          = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "UserMessage";
            class2.Fields      = "[ID],[MessageClass],[Title],[Content],[UserIP],[PostDate],[IsHandler],[AdminReplyContent],[AdminReplyDate],[UserID],[UserName],[Mobile],[IsChecked]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, userMessageSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareUserMessageModel(reader, userMessageList);
            }
            return(userMessageList);
        }
Exemplo n.º 28
0
        public List <KPIInfo> SearchKPIList(KPISearchInfo kpiSearch, int currentPage, int pageSize, ref int count)
        {
            List <KPIInfo>      kpiList = new List <KPIInfo>();
            ShopMssqlPagerClass class2  = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "KPI";
            class2.Fields      = "*";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, kpiSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader dr = class2.ExecuteReader())
            {
                this.PrepareModel(dr, kpiList);
            }
            return(kpiList);
        }
Exemplo n.º 29
0
        public List <ReceiveMessageInfo> SearchReceiveMessageList(int currentPage, int pageSize, ReceiveMessageSearchInfo receiveMessageSearch, ref int count)
        {
            List <ReceiveMessageInfo> receiveMessageList = new List <ReceiveMessageInfo>();
            ShopMssqlPagerClass       class2             = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "ReceiveMessage";
            class2.Fields      = "[ID],[Title],[Content],[Date],[IsRead],[IsAdmin],[FromUserID],[FromUserName],[UserID],[UserName]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            this.PrepareCondition(class2.MssqlCondition, receiveMessageSearch);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareReceiveMessageModel(reader, receiveMessageList);
            }
            return(receiveMessageList);
        }
Exemplo n.º 30
0
        public List <AdRecordInfo> ReadAdRecordList(int currentPage, int pageSize, ref int count, int userID)
        {
            List <AdRecordInfo> adRecordList = new List <AdRecordInfo>();
            ShopMssqlPagerClass class2       = new ShopMssqlPagerClass();

            class2.TableName   = ShopMssqlHelper.TablePrefix + "AdRecord";
            class2.Fields      = "[ID],[AdID],[IP],[Date],[Page],[UserID],[UserName]";
            class2.CurrentPage = currentPage;
            class2.PageSize    = pageSize;
            class2.OrderField  = "[ID]";
            class2.OrderType   = OrderType.Desc;
            class2.MssqlCondition.Add("[UserID]", userID, ConditionType.Equal);
            class2.Count = count;
            count        = class2.Count;
            using (SqlDataReader reader = class2.ExecuteReader())
            {
                this.PrepareAdRecordModel(reader, adRecordList);
            }
            return(adRecordList);
        }