Exemple #1
0
        public ActionResult AddressFor(string edit = "")
        {
            try
            {
                Init("cabinet_addressfor");
                string id = GetRouteID();
                if (id == "")
                {
                    return(RedirectToAction("User", "Cabinet"));
                }
                UserAddress userAddress = new UserAddress(shared);

                userAddress.Select(id);
                if (edit == "ModeEdit")
                {
                    return(View("Address", userAddress));
                }
                return(View("AddressList", userAddress));
                // return View("~/View/Shared/_Menu.cshtml", userAddress);
            }
            catch (Exception ex)
            {
                return(ShowError(ex));
            }
        }
Exemple #2
0
 public ActionResult Address()
 {
     try
     {
         Init("cabinet_address");
         if (currUserId == "")
         {
             return(RedirectToAction("Index", "Login"));
         }
         UserAddress userAddress = new UserAddress(shared);
         userAddress.Select(currUserId);
         return(View(userAddress));
     }
     catch (Exception ex)
     {
         return(ShowError(ex));
     }
 }