Created
July 22, 2018 09:44
-
-
Save ivanpaulovich/21c175748c960a844c6165167be267ff to your computer and use it in GitHub Desktop.
DepositPresenter.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Presenter | |
{ | |
public IActionResult ViewModel { get; private set; } | |
public void Populate(DepositOutput output) | |
{ | |
if (output == null) | |
{ | |
ViewModel = new NoContentResult(); | |
return; | |
} | |
ViewModel = new ObjectResult(new CurrentAccountBalanceModel( | |
output.Transaction.Amount, | |
output.Transaction.Description, | |
output.Transaction.TransactionDate, | |
output.UpdatedBalance | |
)); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment