public CollocationController(IMarketService iMarketService, ICollocationService iCollocationService, IProductService iProductService) { _iMarketService = iMarketService; settings = _iMarketService.GetServiceSetting(MarketType.Collocation); _iProductService = iProductService; _iCollocationService = iCollocationService; }
/// <summary> /// 设置拼团营销活动费用设置 /// </summary> /// <param name="price"></param> public static void SetMarketServicePrice(decimal price) { Entities.MarketSettingInfo marketser = new Entities.MarketSettingInfo() { TypeId = CurMarketType, Price = price }; MarketApplication.AddOrUpdateServiceSetting(marketser); }
public JsonResult SaveServiceSetting(decimal Price) { Result result = new Result(); var model = new Entities.MarketSettingInfo { Price = Price, TypeId = MarketType.Collocation }; _iMarketService.AddOrUpdateServiceSetting(model); result.success = true; result.msg = "保存成功!"; return(Json(result)); }
/// <summary> /// 拼团营销活动费用设置 /// </summary> /// <returns></returns> public static decimal GetMarketServicePrice() { var marketser = MarketApplication.GetServiceSetting(CurMarketType); if (marketser == null) { marketser = new Entities.MarketSettingInfo() { TypeId = CurMarketType, Price = 0 }; MarketApplication.AddOrUpdateServiceSetting(marketser); } return(marketser.Price); }
public ActionResult ServiceSetting() { Entities.MarketSettingInfo model = _iMarketService.GetServiceSetting(MarketType.Collocation); return(View(model)); }
public ActionResult ServiceSetting() { Entities.MarketSettingInfo model = _iMarketService.GetServiceSetting(MarketType.RandomlyBonus); return(View(model)); }