Beispiel #1
0
        public ActionResult ResendEmailVerification(ContentModel model, string u)
        {
            var unverifiedUser = _auth0Helper.GetAuth0User(u);
            var customer       = new AccountProfileModel(model.Content)
            {
                UserId       = unverifiedUser.UserId,
                EmailAddress = unverifiedUser.Email,
                FirstName    = unverifiedUser.FirstName,
                LastName     = unverifiedUser.LastName
            };

            MailController.Instance(Request, model.Content, CurrentUser.LanguageCode).RegistrationConfirmMail(customer).Send();
            return(Redirect($"/{CurrentUser.LanguageCode}/account/confirm-your-email-address/"));
        }
Beispiel #2
0
        public ActionResult AccountProfile(ContentModel model)
        {
            var auth0Helper = new Auth0Helper();
            var user        = auth0Helper.GetAuth0User(CurrentUser.UserId);
            var customer    = new AccountProfileModel(model.Content)
            {
                UserId                 = user.UserId,
                EmailAddress           = user.Email,
                FirstName              = user.FirstName,
                LastName               = user.LastName,
                Phone                  = user.UserMetadata != null ? user.UserMetadata.Phone : "",
                SubscribedToNewsletter = user.UserMetadata != null?Convert.ToBoolean(user.UserMetadata.SubscribedToNewsletter) : false,
            };

            return(CurrentTemplate(customer));
        }