Пример #1
0
        public async Task <ActionResult> EditSettings()
        {
            var model = new AgentHomePageViewModel();
            var user  = await _authManager.FindByIdAsync(User.Identity.GetUserId());

            if (user.Gender == null || string.IsNullOrEmpty(user.FirstName) || string.IsNullOrEmpty(user.LastName) || string.IsNullOrEmpty(user.PhoneNumber))
            {
                return(RedirectToAction(nameof(this.Contact)));
            }
            if (string.IsNullOrEmpty(user.Facebook) || string.IsNullOrEmpty(user.Twitter) || string.IsNullOrEmpty(user.Linkedin) || string.IsNullOrEmpty(user.GooglePlus))
            {
                return(RedirectToAction(nameof(this.Social)));
            }
            return(null);
        }
Пример #2
0
        public ActionResult Index()
        {
            var model = new AgentHomePageViewModel();

            return(View(model));
        }