Beispiel #1
0
        public ActionResult DetailtoCart(int caseid, int quantity)
        {
            int scid;
            int mid;

            if (Session["MEMBERID"] == null)
            {
                return(RedirectToAction("Login", "Member", new { area = "MyMember" }));
            }
            else
            {
                mid = (int)Session["MEMBERID"];
            }



            if (Session["shoppingcardID"] == null)
            {
                scid = b.buycheck(mid);
                Session["shoppingcardID"] = scid;
            }
            else
            {
                scid = (int)Session["shoppingcardID"];
            }

            b.SaveinCart(mid, caseid, quantity, 0, scid);
            return(RedirectToAction("BrowseGoodsAll", "Goods", new { area = "TotalCase" }));
            //return RedirectToAction("CartDatainOrders", "Recipient", new { area = "ShoppingCart" });
        }
Beispiel #2
0
        public ActionResult Index2()
        {
            int scid;
            int mid = (int)Session["MEMBERID"];

            if (Session["shoppingcardID"] == null)
            {
                scid = b.buycheck(mid);
                Session["shoppingcardID"] = scid;
            }
            else
            {
                scid = (int)Session["shoppingcardID"];
            }



            b.SaveinCart(mid, 1, 2, 0, scid);

            return(RedirectToAction("CartDatainOrders", "Recipient", new { area = "ShoppingCart" }));



            //return View();
        }
        public ActionResult MPDetailtoCart(int caseid)
        {
            int scid;
            int mid;

            if (Session["MEMBERID"] == null)
            {
                return(RedirectToAction("Login", "Member", new { area = "MyMember" }));
            }
            else
            {
                mid = (int)Session["MEMBERID"];



                if (Session["shoppingcardID"] == null)
                {
                    scid = b.buycheck(mid);
                    Session["shoppingcardID"] = scid;
                }
                else
                {
                    scid = (int)Session["shoppingcardID"];
                }

                b.SaveinCart(mid, caseid, 1, 0, scid);

                return(RedirectToAction("ManPowerAll", "ManPowers", new { area = "TotalCase" }));
            }
        }