Exemplo n.º 1
0
        protected string ReadUserEmail(string strUserGrade)
        {
            string str = string.Empty;
            Dictionary <decimal, decimal> moneyUsed = new Dictionary <decimal, decimal>();

            foreach (string str2 in strUserGrade.Split(new char[] { ',' }))
            {
                UserGradeInfo info = UserGradeBLL.ReadUserGradeCache(Convert.ToInt32(str2));
                moneyUsed.Add(info.MinMoney, info.MaxMoney);
            }
            List <string> list = UserBLL.ReadUserEmailByMoneyUsed(moneyUsed);

            foreach (string str2 in list)
            {
                if (str == string.Empty)
                {
                    str = str2;
                }
                else
                {
                    str = str + "," + str2;
                }
            }
            return(str);
        }
Exemplo n.º 2
0
        protected override void PageLoad()
        {
            base.PageLoad();
            int queryString = RequestHelper.GetQueryString <int>("ID");

            this.favorableActivity = FavorableActivityBLL.ReadFavorableActivity(queryString);
            if (this.favorableActivity.UserGrade != string.Empty)
            {
                foreach (string str in this.favorableActivity.UserGrade.Split(new char[] { ',' }))
                {
                    if (this.userGrade == string.Empty)
                    {
                        this.userGrade = UserGradeBLL.ReadUserGradeCache(Convert.ToInt32(str)).Name;
                    }
                    else
                    {
                        this.userGrade = this.userGrade + "," + UserGradeBLL.ReadUserGradeCache(Convert.ToInt32(str)).Name;
                    }
                }
            }
            if (this.favorableActivity.GiftID != string.Empty)
            {
                GiftSearchInfo gift = new GiftSearchInfo();
                gift.InGiftID = this.favorableActivity.GiftID;
                this.giftList = GiftBLL.SearchGiftList(gift);
            }
            base.Title = this.favorableActivity.Name;
        }
        /// <summary>
        /// 页面加载
        /// </summary>
        protected override void PageLoad()
        {
            base.PageLoad();
            int id = RequestHelper.GetQueryString <int>("ID");

            favorableActivity = FavorableActivityBLL.ReadFavorableActivity(id);
            if (favorableActivity.UserGrade != string.Empty)
            {
                foreach (string temp in favorableActivity.UserGrade.Split(','))
                {
                    if (userGrade == string.Empty)
                    {
                        userGrade = UserGradeBLL.ReadUserGradeCache(Convert.ToInt32(temp)).Name;
                    }
                    else
                    {
                        userGrade += "," + UserGradeBLL.ReadUserGradeCache(Convert.ToInt32(temp)).Name;
                    }
                }
            }
            if (favorableActivity.GiftID != string.Empty)
            {
                GiftSearchInfo giftSearch = new GiftSearchInfo();
                giftSearch.InGiftID = favorableActivity.GiftID;
                giftList            = GiftBLL.SearchGiftList(giftSearch);
            }

            Title = favorableActivity.Name;
        }
Exemplo n.º 4
0
        /// <summary>
        /// 页面加载
        /// </summary>
        protected override void PageLoad()
        {
            base.PageLoad();
            user          = UserBLL.ReadUserMore(base.UserID);
            userGradeName = UserGradeBLL.ReadUserGradeCache(base.GradeID).Name;

            int id = RequestHelper.GetQueryString <int>("ID");

            sendMessage = SendMessageBLL.ReadSendMessage(id, base.UserID);
        }
Exemplo n.º 5
0
        protected override void PageLoad()
        {
            base.PageLoad();
            this.user          = UserBLL.ReadUserMore(base.UserID);
            this.userGradeName = UserGradeBLL.ReadUserGradeCache(base.GradeID).Name;
            this.dt            = UserBLL.UserIndexStatistics(base.UserID);
            OrderSearchInfo order = new OrderSearchInfo();

            order.UserID = base.UserID;
            int count = -2147483648;

            this.orderList = OrderBLL.SearchOrderList(1, 10, order, ref count);
        }
Exemplo n.º 6
0
        /// <summary>
        /// 页面加载
        /// </summary>
        protected override void PageLoad()
        {
            base.PageLoad();
            user          = UserBLL.ReadUserMore(base.UserID);
            userGradeName = UserGradeBLL.ReadUserGradeCache(base.GradeID).Name;
            int id = RequestHelper.GetQueryString <int>("ID");

            receiveMessage = ReceiveMessageBLL.ReadReceiveMessage(id, base.UserID);
            if (receiveMessage.ID > 0 && receiveMessage.IsRead == (int)BoolType.False)
            {
                receiveMessage.IsRead = (int)BoolType.True;
                ReceiveMessageBLL.UpdateReceiveMessage(receiveMessage);
            }
        }
Exemplo n.º 7
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!this.Page.IsPostBack)
     {
         int queryString = RequestHelper.GetQueryString <int>("ID");
         if (queryString != -2147483648)
         {
             // base.CheckAdminPower("ReadUserGrade", PowerCheckType.Single);
             UserGradeInfo info = UserGradeBLL.ReadUserGradeCache(queryString);
             this.Name.Text     = info.Name;
             this.MinMoney.Text = info.MinMoney.ToString();
             this.MaxMoney.Text = info.MaxMoney.ToString();
             this.Discount.Text = info.Discount.ToString();
         }
     }
 }
Exemplo n.º 8
0
        protected override void PageLoad()
        {
            base.PageLoad();
            int queryString = RequestHelper.GetQueryString <int>("ID");

            this.product = ProductBLL.ReadProduct(queryString);
            if (this.product.IsSale == 0)
            {
                ScriptHelper.Alert("该产品未上市,不能查看");
            }
            ProductBLL.ChangeProductViewCount(queryString, 1);
            this.userGradeList      = UserGradeBLL.ReadUserGradeCacheList();
            this.memberPriceList    = MemberPriceBLL.ReadMemberPriceByProduct(queryString);
            this.currentMemberPrice = (this.product.MarketPrice * UserGradeBLL.ReadUserGradeCache(base.GradeID).Discount) / 100M;
            foreach (MemberPriceInfo info in this.memberPriceList)
            {
                if (info.GradeID == base.GradeID)
                {
                    this.currentMemberPrice = info.Price;
                    break;
                }
            }
            this.currentMemberPrice = Math.Round(this.currentMemberPrice, 2);
            ProductPhotoInfo item = new ProductPhotoInfo();

            item.Name  = this.product.Name;
            item.Photo = this.product.Photo;
            this.productPhotoList.Add(item);
            this.productPhotoList.AddRange(ProductPhotoBLL.ReadProductPhotoByProduct(queryString));
            this.strHistoryProduct = base.Server.UrlDecode(CookiesHelper.ReadCookieValue("HistoryProduct"));
            string strProductID = (this.product.RelationProduct + "," + this.product.Accessory + "," + this.strHistoryProduct).Replace(",,", ",");

            if (strProductID.StartsWith(","))
            {
                strProductID = strProductID.Substring(1);
            }
            if (strProductID.EndsWith(","))
            {
                strProductID = strProductID.Substring(0, strProductID.Length - 1);
            }
            ProductSearchInfo productSearch = new ProductSearchInfo();

            productSearch.InProductID = strProductID;
            this.tempProductList      = ProductBLL.SearchProductList(productSearch);
            if (strProductID != string.Empty)
            {
                this.tempMemberPriceList = MemberPriceBLL.ReadMemberPriceByProductGrade(strProductID, base.GradeID);
            }
            this.attributeRecordList = AttributeRecordBLL.ReadAttributeRecordByProduct(queryString);
            TagsSearchInfo tags = new TagsSearchInfo();

            tags.ProductID       = queryString;
            this.productTagsList = TagsBLL.SearchTagsList(tags);
            if (this.product.RelationArticle != string.Empty)
            {
                ArticleSearchInfo articleSearch = new ArticleSearchInfo();
                articleSearch.InArticleID = this.product.RelationArticle;
                this.productArticleList   = ArticleBLL.SearchArticleList(articleSearch);
            }
            this.standardRecordList = StandardRecordBLL.ReadStandardRecordByProduct(this.product.ID, this.product.StandardType);
            if ((this.standardRecordList.Count > 0) && (this.product.StandardType == 1))
            {
                string[] strArray = this.standardRecordList[0].StandardIDList.Split(new char[] { ',' });
                for (int i = 0; i < strArray.Length; i++)
                {
                    StandardInfo info6     = StandardBLL.ReadStandardCache(Convert.ToInt32(strArray[i]));
                    string[]     strArray2 = info6.ValueList.Split(new char[] { ',' });
                    string[]     strArray3 = info6.PhotoList.Split(new char[] { ',' });
                    string       str2      = string.Empty;
                    string       str3      = string.Empty;
                    for (int j = 0; j < strArray2.Length; j++)
                    {
                        foreach (StandardRecordInfo info7 in this.standardRecordList)
                        {
                            string[] strArray4 = info7.ValueList.Split(new char[] { ',' });
                            if (strArray2[j] == strArray4[i])
                            {
                                str2 = str2 + strArray2[j] + ",";
                                str3 = str3 + strArray3[j] + ",";
                                goto Label_043B;
                            }
                        }
                        Label_043B :;
                    }
                    if (str2 != string.Empty)
                    {
                        str2 = str2.Substring(0, str2.Length - 1);
                        str3 = str3.Substring(0, str3.Length - 1);
                    }
                    info6.ValueList = str2;
                    info6.PhotoList = str3;
                    this.standardList.Add(info6);
                }
                foreach (StandardRecordInfo info7 in this.standardRecordList)
                {
                    object standardRecordValueList = this.standardRecordValueList;
                    this.standardRecordValueList = string.Concat(new object[] { standardRecordValueList, info7.ProductID, ",", info7.ValueList, "|" });
                }
            }
            if (ShopConfig.ReadConfigInfo().ProductStorageType == 1)
            {
                this.leftStorageCount = this.product.TotalStorageCount - this.product.OrderCount;
            }
            else
            {
                this.leftStorageCount = this.product.ImportVirtualStorageCount;
            }
            base.Title       = this.product.Name;
            base.Keywords    = (this.product.Keywords == string.Empty) ? this.product.Name : this.product.Keywords;
            base.Description = (this.product.Summary == string.Empty) ? StringHelper.Substring(StringHelper.KillHTML(this.product.Introduction), 200) : this.product.Summary;
        }
Exemplo n.º 9
0
        /// <summary>
        /// 页面加载
        /// </summary>
        protected override void PageLoad()
        {
            base.PageLoad();
            user          = UserBLL.ReadUserMore(base.UserID);
            userGradeName = UserGradeBLL.ReadUserGradeCache(base.GradeID).Name;
            string action = RequestHelper.GetQueryString <string>("Action");

            switch (action)
            {
            case "Delete":
                string deleteID = RequestHelper.GetQueryString <string>("ID");
                UserFriendBLL.DeleteUserFriend(deleteID, base.UserID);
                ResponseHelper.Write("ok");
                ResponseHelper.End();
                break;

            default:
                break;
            }

            int currentPage = RequestHelper.GetQueryString <int>("Page");

            if (currentPage < 1)
            {
                currentPage = 1;
            }
            int pageSize = 25;
            int count    = 0;
            UserFriendSearchInfo userFriendSearch = new UserFriendSearchInfo();

            userFriendSearch.UserID      = base.UserID;
            userFriendList               = UserFriendBLL.SearchUserFriendList(currentPage, pageSize, userFriendSearch, ref count);
            commonPagerClass.CurrentPage = currentPage;
            commonPagerClass.PageSize    = pageSize;
            commonPagerClass.Count       = count;
            commonPagerClass.FirstPage   = "<<首页";
            commonPagerClass.PreviewPage = "<<上一页";
            commonPagerClass.NextPage    = "下一页>>";
            commonPagerClass.LastPage    = "末页>>";
            commonPagerClass.ListType    = false;
            commonPagerClass.DisCount    = false;
            commonPagerClass.PrenextType = true;

            string strUserID = string.Empty;

            foreach (UserFriendInfo userFriend in userFriendList)
            {
                if (strUserID == string.Empty)
                {
                    strUserID = userFriend.FriendID.ToString();
                }
                else
                {
                    strUserID += "," + userFriend.FriendID.ToString();
                }
            }
            if (strUserID != string.Empty)
            {
                UserSearchInfo userSearch = new UserSearchInfo();
                userSearch.InUserID = strUserID;
                userList            = UserBLL.SearchUserList(userSearch);
            }
        }
Exemplo n.º 10
0
 /// <summary>
 /// 页面加载
 /// </summary>
 protected override void PageLoad()
 {
     base.PageLoad();
     user          = UserBLL.ReadUserMore(base.UserID);
     userGradeName = UserGradeBLL.ReadUserGradeCache(base.GradeID).Name;
 }
Exemplo n.º 11
0
        protected override void PageLoad()
        {
            base.PageLoad();
            if (CookiesHelper.ReadCookieValue("ProductShowWay") != string.Empty)
            {
                this.productShowWay = Convert.ToInt32(CookiesHelper.ReadCookieValue("ProductShowWay"));
            }
            int queryString = RequestHelper.GetQueryString <int>("Page");

            if (queryString < 1)
            {
                queryString = 1;
            }
            int pageSize = 20;

            if (this.productShowWay == 2)
            {
                pageSize = 10;
            }
            int count = 0;
            ProductSearchInfo productSearch = new ProductSearchInfo();

            productSearch.IsSale           = 1;
            productSearch.ProductOrderType = CookiesHelper.ReadCookieValue("ProductOrderType");
            if (RequestHelper.GetQueryString <int>("SearchType") == 2)
            {
                string str  = StringHelper.SearchSafe(RequestHelper.GetQueryString <string>("ClassID"));
                int    num5 = -2147483648;
                if (str == num5.ToString())
                {
                    str = string.Empty;
                }
                else
                {
                    str = "|" + str + "|";
                }
                productSearch.ClassID   = str;
                productSearch.Key       = StringHelper.SearchSafe(RequestHelper.GetQueryString <string>("ProductName"));
                productSearch.InBrandID = RequestHelper.GetQueryString <string>("BrandID");
                productSearch.Tags      = StringHelper.SearchSafe(RequestHelper.GetQueryString <string>("Tags"));
            }
            else
            {
                productSearch.IsNew     = RequestHelper.GetQueryString <int>("IsNew");
                productSearch.IsHot     = RequestHelper.GetQueryString <int>("IsHot");
                productSearch.IsSpecial = RequestHelper.GetQueryString <int>("IsSpecial");
                productSearch.IsTop     = RequestHelper.GetQueryString <int>("IsTop");
            }
            if ((productSearch.ProductOrderType == "MemberPrice1") || (productSearch.ProductOrderType == "MemberPrice2"))
            {
                UserGradeInfo info2 = UserGradeBLL.ReadUserGradeCache(base.GradeID);
                if (productSearch.ProductOrderType == "MemberPrice2")
                {
                    productSearch.OrderType = OrderType.Asc;
                }
                this.productList = ProductBLL.SearchProductList(queryString, pageSize, productSearch, ref count, info2.ID, info2.Discount / 100M);
            }
            else
            {
                this.productList      = ProductBLL.SearchProductList(queryString, pageSize, productSearch, ref count);
                this.countPriceSingle = true;
                string strProductID = string.Empty;
                foreach (ProductInfo info3 in this.productList)
                {
                    if (strProductID == string.Empty)
                    {
                        strProductID = info3.ID.ToString();
                    }
                    else
                    {
                        strProductID = strProductID + "," + info3.ID.ToString();
                    }
                }
                if (strProductID != string.Empty)
                {
                    this.memberPriceList = MemberPriceBLL.ReadMemberPriceByProductGrade(strProductID, base.GradeID);
                }
            }
            this.ajaxPagerClass.CurrentPage = queryString;
            this.ajaxPagerClass.PageSize    = pageSize;
            this.ajaxPagerClass.Count       = count;
        }