Example #1
0
        public JsonResult EditVShop(Entities.VShopInfo vshopInfo)
        {
            if (vshopInfo.Id > 0)
            {
                var vshop = _iVShopService.GetVShop(vshopInfo.Id);
                vshop.StrLogo            = vshopInfo.StrLogo;
                vshop.WXLogo             = vshopInfo.WXLogo;
                vshop.StrBackgroundImage = vshopInfo.StrBackgroundImage;
                vshop.Tags = vshopInfo.Tags;

                _iVShopService.UpdateVShop(vshop);
            }
            else
            {
                _iVShopService.CreateVshop(vshopInfo);
            }

            return(Json(new { success = true }));
        }
Example #2
0
        public ActionResult EditVShop(long shopId)
        {
            if (shopId != CurrentSellerManager.ShopId)
            {
                throw new HimallException("获取店铺信息错误");
            }
            var vshop = _iVShopService.GetVShopByShopId(shopId);

            if (vshop == null)
            {
                vshop = new Entities.VShopInfo();
            }
            else
            {
                vshop.StrLogo            = Core.HimallIO.GetRomoteImagePath(vshop.StrLogo);
                vshop.StrBackgroundImage = Core.HimallIO.GetRomoteImagePath(vshop.StrBackgroundImage);
                vshop.WXLogo             = Core.HimallIO.GetRomoteImagePath(vshop.WXLogo);
            }
            ViewBag.ShopId = CurrentSellerManager.ShopId;
            return(View(vshop));
        }
Example #3
0
 /// <summary>
 /// 更新微店
 /// </summary>
 /// <param name="vshopInfo">微店信息</param>
 public static void UpdateVShop(Entities.VShopInfo vshopInfo)
 {
     Service.UpdateVShop(vshopInfo);
 }
Example #4
0
 /// <summary>
 /// 创建微店
 /// </summary>
 /// <param name="vshopInfo">微店信息</param>
 public static void CreateVshop(Entities.VShopInfo vshopInfo)
 {
     Service.CreateVshop(vshopInfo);
 }