public ActionResult TransferConfirmation(string hashedAccountId, TransferConfirmationViewModel request) { if (!ModelState.IsValid) { return(View("TransferConfirmation", request)); } var url = request.SelectedOption == TransferConfirmationViewModel.Option.Homepage ? _linkGenerator.AccountsLink($"accounts/{hashedAccountId}/teams") : _linkGenerator.AccountsLink($"accounts/{hashedAccountId}/transfers"); return(Redirect(url)); }
public async Task <ActionResult> TransferConfirmation(TransferConfirmationViewModel viewModel) { var request = await _modelMapper.Map <TransferConfirmationWhatNextRequest>(viewModel); return(Redirect(request.WhatNextUrl)); }