Exemple #1
0
        public ActionResult BannerAdd(int bannerid = 0)
        {
            ViewBag.bannerid = bannerid;
            if (bannerid > 0)
            {
                BannerCache bannerCache = RemotingHelp.GetModelObject <BannerCache>();
                ViewBag.banner = bannerCache.GetBanners().SingleOrDefault(t => t.id == bannerid);
            }
            ProductCache productCache = RemotingHelp.GetModelObject <ProductCache>();

            ViewBag.products = productCache.GetNoRepeatProducts();
            return(View());
        }
Exemple #2
0
        public ActionResult CouponAdd(int coupontypeid = 0)
        {
            ViewBag.coupontypeid = coupontypeid;
            ViewBag.coupontype   = null;
            if (coupontypeid > 0)
            {
                COUPON coupon = RemotingHelp.GetModelObject <COUPON>();
                ViewBag.coupontype = (coupon.GetCouponType().data as List <ShowCouponTypeInfo>).SingleOrDefault(t => t.ct_coupontypeid == coupontypeid);
            }
            ProductCache productCache = RemotingHelp.GetModelObject <ProductCache>();

            ViewBag.products = productCache.GetNoRepeatProducts();
            return(View());
        }