コード例 #1
0
        public async Task <IActionResult> CreateAccount(CreateAccountViewModel vm)
        {
            if (!ModelState.IsValid)
            {
                return(View(vm));
            }

            var inviteSuccess = await _usersApiClient.InviteUser(vm);

            _sessionService.Set("NewAccount", vm);

            return(inviteSuccess ? RedirectToAction("InviteSent") : RedirectToAction("Error", "Home"));
        }