Example #1
0
        public ActionResult ChangeBasicInfo()
        {
            var model = new ChangeBasicInfoViewModel();

            model.SelectedCentreIDValue = UserManager.FindById(User.Identity.GetUserId()).DistributionCentreID.ToString();

            model.CentresInDropDownList = from c in _distributionCentreBLL.GetDistributionCentreList()
                                          select new SelectListItem
            {
                Text     = c.Name,
                Value    = c.ID.ToString(),
                Selected = model.SelectedCentreIDValue == c.ID.ToString()
            };

            model.FullName = UserManager.FindById(User.Identity.GetUserId()).FullName;

            model.Email = UserManager.FindById(User.Identity.GetUserId()).Email;

            return(View(model));
        }
Example #2
0
 // GET: CentreList
 public ActionResult CentreList()
 {
     return(View(distributionCentresBLL.GetDistributionCentreList()));
 }