Beispiel #1
0
        public void SetDefaultTest()
        {
            int addressId = 2;
            ConsigneeProvider provider = new ConsigneeProvider();
            bool res = provider.SetDefault(addressId);

            Assert.IsTrue(res);
        }
Beispiel #2
0
        /// <summary>
        /// 设置默认收货地址
        /// </summary>
        /// <param name="AddressId"></param>
        /// <returns></returns>
        public ActionResult SetDefault(int AddressId)
        {
            ConsigneeProvider provider = new ConsigneeProvider();

            if (!provider.SetDefault(AddressId))
            {
                return(FailResult(provider.PromptInfo.CustomMessage, (int)provider.PromptInfo.ResultType));
            }
            return(SuccessResult());
        }