/// <summary>
 /// For backward compatibility with old wrappers.
 /// </summary>
 public PromotionRuleTypeCollection GetPromotionRules(int StoreCategoryID, PromotionMethodCodeType PromotionMethod)
 {
     this.StoreCategoryID = StoreCategoryID;
     this.PromotionMethod = PromotionMethod;
     Execute();
     return(PromotionRuleList);
 }
Example #2
0
 /// <summary>
 /// For backward compatibility with old wrappers.
 /// </summary>
 public CrossPromotionsType GetCrossPromotions(string ItemID, PromotionMethodCodeType PromotionMethod)
 {
     this.ItemID          = ItemID;
     this.PromotionMethod = PromotionMethod;
     Execute();
     return(CrossPromotion);
 }
 /// <summary>
 /// For backward compatibility with old wrappers.
 /// </summary>
 public PromotionRuleTypeCollection GetPromotionRules(string ItemID, PromotionMethodCodeType PromotionMethod)
 {
     this.ItemID          = ItemID;
     this.PromotionMethod = PromotionMethod;
     Execute();
     return(PromotionRuleList);
 }
		/// <summary>
		/// <b>No longer recommended.</b> The eBay Store Cross Promotions are no longer
		/// supported in the Trading API. Retrieves a list of upsell or cross-sell items associated
		/// with the specified Item ID.
		/// </summary>
		/// 
		/// <param name="ItemID">
		/// The unique ID of the referring item. The cross-promoted
		/// items will supplement this item.
		/// </param>
		///
		/// <param name="PromotionMethod">
		/// The cross-promotion method you want to use for the
		/// returned list, either UpSell or CrossSell.
		/// </param>
		///
		/// <param name="PromotionViewMode">
		/// The role of the person requesting to view the cross-promoted
		/// items, either seller or buyer. Default is buyer.
		/// </param>
		///
		public CrossPromotionsType GetCrossPromotions(string ItemID, PromotionMethodCodeType PromotionMethod, TradingRoleCodeType PromotionViewMode)
		{
			this.ItemID = ItemID;
			this.PromotionMethod = PromotionMethod;
			this.PromotionViewMode = PromotionViewMode;

			Execute();
			return ApiResponse.CrossPromotion;
		}
Example #5
0
        /// <summary>
        /// <b>No longer recommended.</b> The eBay Store Cross Promotions are no longer
        /// supported in the Trading API. Retrieves a list of upsell or cross-sell items associated
        /// with the specified Item ID.
        /// </summary>
        ///
        /// <param name="ItemID">
        /// The unique ID of the referring item. The cross-promoted
        /// items will supplement this item.
        /// </param>
        ///
        /// <param name="PromotionMethod">
        /// The cross-promotion method you want to use for the
        /// returned list, either UpSell or CrossSell.
        /// </param>
        ///
        /// <param name="PromotionViewMode">
        /// The role of the person requesting to view the cross-promoted
        /// items, either seller or buyer. Default is buyer.
        /// </param>
        ///
        public CrossPromotionsType GetCrossPromotions(string ItemID, PromotionMethodCodeType PromotionMethod, TradingRoleCodeType PromotionViewMode)
        {
            this.ItemID            = ItemID;
            this.PromotionMethod   = PromotionMethod;
            this.PromotionViewMode = PromotionViewMode;

            Execute();
            return(ApiResponse.CrossPromotion);
        }
		/// <summary>
		/// <b>No longer recommended.</b> eBay Store Cross Promotions are no
		/// longer supported in the Trading API. Retrieves all promotion rules associated with the specified item or store category.
		/// </summary>
		/// 
		/// <param name="ItemID">
		/// The unique ID of the item for which to retrieve promotion rules.
		/// Mutually exclusive with StoreCategoryID.
		/// </param>
		///
		/// <param name="StoreCategoryID">
		/// The unique ID of the store category for which to retrieve promotion rules.
		/// Mutually exclusive with ItemID.
		/// </param>
		///
		/// <param name="PromotionMethod">
		/// The type of promotion. (CrossSell: items that are related to or
		/// useful in combination with this item. UpSell: items that are more
		/// expensive than or of higher quality than this item.)
		/// </param>
		///
		public PromotionRuleTypeCollection GetPromotionRules(string ItemID, long StoreCategoryID, PromotionMethodCodeType PromotionMethod)
		{
			this.ItemID = ItemID;
			this.StoreCategoryID = StoreCategoryID;
			this.PromotionMethod = PromotionMethod;

			Execute();
			return ApiResponse.PromotionRuleArray;
		}
        public void GetPromotionRulesFull()
        {
            bool   isTherePropertyNull;
            int    nullPropertyNums;
            string nullPropertyNames;

            Assert.IsNotNull(TestData.NewItem2, "Failed because no item available -- requires successful AddItem test");
            GetPromotionRulesCall api = new GetPromotionRulesCall(this.apiContext);

            string itemID = TestData.NewItem2.ItemID;
            PromotionMethodCodeType     promotionType = PromotionMethodCodeType.UpSell;
            PromotionRuleTypeCollection rules         = api.GetPromotionRules(itemID, promotionType);

            //check whether the call is success.
            Assert.IsTrue(api.ApiResponse.Ack == AckCodeType.Success || api.ApiResponse.Ack == AckCodeType.Warning, "do not success!");

            Assert.IsNotNull(rules);
            if (rules != null && rules.Count > 0)
            {
                isTherePropertyNull = ReflectHelper.IsProperteValueNotNull(rules[0], out nullPropertyNums, out nullPropertyNames);
                Assert.IsTrue(isTherePropertyNull, "there are" + nullPropertyNums.ToString() + " properties(" + nullPropertyNames + ")value is null");
            }
        }
		/// <summary>
		/// For backward compatibility with old wrappers.
		/// </summary>
		public CrossPromotionsType GetCrossPromotions(string ItemID, PromotionMethodCodeType PromotionMethod)
		{
			this.ItemID = ItemID;
			this.PromotionMethod = PromotionMethod;
			Execute();
			return CrossPromotion;
		}
Example #9
0
 /// <summary>
 /// For backward compatibility with old wrappers.
 /// </summary>
 public PromotionRuleTypeCollection GetPromotionRules(int StoreCategoryID, PromotionMethodCodeType PromotionMethod)
 {
     this.StoreCategoryID = StoreCategoryID;
     this.PromotionMethod = PromotionMethod;
     Execute();
     return PromotionRuleList;
 }
Example #10
0
 /// <summary>
 /// For backward compatibility with old wrappers.
 /// </summary>
 public PromotionRuleTypeCollection GetPromotionRules(string ItemID, PromotionMethodCodeType PromotionMethod)
 {
     this.ItemID = ItemID;
     this.PromotionMethod = PromotionMethod;
     Execute();
     return PromotionRuleList;
 }
        /// <summary>
        /// <b>No longer recommended.</b> eBay Store Cross Promotions are no
        /// longer supported in the Trading API. Retrieves all promotion rules associated with the specified item or store category.
        /// </summary>
        ///
        /// <param name="ItemID">
        /// The unique ID of the item for which to retrieve promotion rules.
        /// Mutually exclusive with StoreCategoryID.
        /// </param>
        ///
        /// <param name="StoreCategoryID">
        /// The unique ID of the store category for which to retrieve promotion rules.
        /// Mutually exclusive with ItemID.
        /// </param>
        ///
        /// <param name="PromotionMethod">
        /// The type of promotion. (CrossSell: items that are related to or
        /// useful in combination with this item. UpSell: items that are more
        /// expensive than or of higher quality than this item.)
        /// </param>
        ///
        public PromotionRuleTypeCollection GetPromotionRules(string ItemID, long StoreCategoryID, PromotionMethodCodeType PromotionMethod)
        {
            this.ItemID          = ItemID;
            this.StoreCategoryID = StoreCategoryID;
            this.PromotionMethod = PromotionMethod;

            Execute();
            return(ApiResponse.PromotionRuleArray);
        }