/// <summary>活动信息变更 /// </summary> /// <param name="redisKey"></param> /// <param name="pid"></param> public void ChangeProductActivity(long pid) { ProductService pservice = new ProductService(); string redisKey = RedisKeyConst.GetProductInfoKey(pid).Key; var prodInfo = CN100.Redis.Client.RedisClientUtility.GetData<ProductInfoModel>(redisKey); if (prodInfo == null) { pservice.PublishProduct(pid); } else { using (WcfTcpClient<IActivityService> clint = factory.CreateClient<IActivityService>()) { prodInfo.ProductActivityList = clint.Channel.GetProductActivitys(pid); } CN100.Redis.Client.RedisClientUtility.SetData<ProductInfoModel>(redisKey, prodInfo); pservice.ChangeProductSKUDetail(prodInfo.SkuList, prodInfo.ProductActivityList, RedisKeyConst.GetProductSKUKey(pid).Key); } }
public OrderService() { productService = new ProductService(); }