private void PopulateListingAddDropDowns(ListingAddViewModel model)
        {
            /*
             * var statesRepo = StatesRepositoryFactory.GetRepository();
             * var bathroomTypesRepo = BathroomTypesRepositoryFactory.GetRepository();
             * model.States = new SelectList(statesRepo.StateGetAll(), "StateId", "StateId");
             * model.BathroomTypes = new SelectList(bathRoomTypesRepo.BathroomTypeGetAll(), "BathroomTypeId", "BathroomTypeName");
             */

            model.States        = new SelectList(_svc.StateGetAll(), "StateId", "StateId");
            model.BathroomTypes = new SelectList(_svc.BathroomTypeGetAll(), "BathroomTypeId", "BathroomTypeName");
        }
Exemple #2
0
        [HttpGet] // GET: /MyAccount/UpdateAccount
        public ActionResult UpdateAccount()
        {
            var model = new UpdateAccountViewModel();

            model.States       = new SelectList(_svc.StateGetAll(), "StateId", "StateId");
            model.EmailAddress = User.Identity.Name;

            return(View(model));
        }