コード例 #1
0
        private void DisplayShop(Shop shop)
        {
            if (!string.IsNullOrEmpty(shop.LogoUrl))
            {
                imgShop.Visible  = true;
                imgShop.ImageUrl = string.Format(ShopLogUrlFormat, shop.LogoUrl);
            }
            else
            {
                imgShop.Visible = false;
            }
            lblNick.Text      = shop.SellerNick;
            lblShopTitle.Text = shop.Title;

            ITopClient      client   = GetProductTopClient();
            ItemsGetRequest reqItems = new ItemsGetRequest();

            reqItems.Fields   = TopFieldsHelper.GetItemFields_OnlyId();
            reqItems.Nicks    = shop.SellerNick;
            reqItems.PageNo   = 1;
            reqItems.PageSize = 1;
            ResponseList <Item> rsp = client.Execute(reqItems, new ItemListJsonParser());

            lblItemCount.Text   = rsp.TotalResults.ToString();
            lblImportCount.Text = (rsp.TotalResults - IgnoreList.Count).ToString();
        }
コード例 #2
0
        private int GetTotalImportCount(string nick)
        {
            ITopClient      client   = GetProductTopClient();
            ItemsGetRequest reqItems = new ItemsGetRequest();

            reqItems.Fields   = TopFieldsHelper.GetItemFields_OnlyId();
            reqItems.Nicks    = nick;
            reqItems.PageNo   = 1;
            reqItems.PageSize = 1;
            ResponseList <Item> rsp = client.Execute(reqItems, new ItemListJsonParser());

            return((int)rsp.TotalResults);
        }