//USER ADDRESS public ActionResult UserAddress() { if (currentUser != null) { List <UserAddress> addresses = userAddressDAL.GetList(x => x.IsActive == true && x.UserID == currentUser.UserID).ToList(); return(View(addresses)); } else { return(View("Index", "Login")); } }
public ActionResult UserOrder() { if (currentUser != null) { VMOrderAddressDetail newUserOrder = new VMOrderAddressDetail(); newUserOrder.UserDetail = userDetailDAL.Get(x => x.IsActive == true && x.UserID == currentUser.UserID); newUserOrder.UserAddresses = userAddressDAL.GetList(x => x.IsActive == true && x.UserID == currentUser.UserID).ToList(); ViewBag.District = districtDAL.GetList(x => x.CityID == 34).OrderBy(x => x.DistrictName).ToList(); ViewBag.City = cityDAL.GetList().OrderBy(x => x.CityName).ToList(); return(View(newUserOrder)); } else { return(View("Index", "Login")); } }