Пример #1
0
        public ActionResult Completed(long id, string openId = "", [DecimalConstant(0, 0, 0, 0, 0)] decimal price = default(decimal), string user = "", long grantid = 0L, long rid = 0L, string wxhead = "", string host = "")
        {
            SetShareData();
            ShopBonusModel shopBonusModel = new ShopBonusModel(_bonusService.Get(id));

            ViewBag.GrantId          = grantid;
            ViewBag.ShareHref        = string.Concat(host, "/m-weixin/shopbonus/index/", grantid.ToString());
            ViewBag.HeadImg          = wxhead;
            ViewBag.ShopAddress      = GetShopAddress(shopBonusModel.ShopId);
            ViewBag.UserName         = user;
            ViewBag.Price            = price;
            ViewBag.HighPrice        = price + 60;
            ViewBag.OpenId           = openId;
            ViewBag.ShopName         = ServiceHelper.Create <IShopService>().GetShopName(shopBonusModel.ShopId);
            shopBonusModel.ShareImg  = string.Concat("http://", host, shopBonusModel.ShareImg);
            shopBonusModel.ReceiveId = rid;
            if (shopBonusModel.SynchronizeCard && base.PlatformType == Himall.Core.PlatformType.WeiXin)
            {
                shopBonusModel.WXJSInfo = ser_wxcard.GetSyncWeiXin(id, rid, ThisCouponType, base.Request.Url.AbsoluteUri);
                if (shopBonusModel.WXJSInfo != null)
                {
                    shopBonusModel.IsShowSyncWeiXin = true;
                }
            }
            return(View(shopBonusModel));
        }
Пример #2
0
        public ActionResult Edit(long id)
        {
            ShopBonusInfo shopBonusInfo = _bonusService.Get(id);

            return(View(new ShopBonusModel(shopBonusInfo)));
        }
 /// <summary>
 ///  获取红包列表
 /// </summary>
 public static ObsoletePageModel <ShopBonusInfo> Get(long shopid, string name, int state, int pageIndex, int pageSize)
 {
     return(_iShopBonusService.Get(shopid, name, state, pageIndex, pageSize));
 }