Exemplo n.º 1
0
        public IActionResult CreateBankUser(BankAppUser bankAppUser)
        {
            return(Gatekeeper(() =>
            {
                if (_manager.CreateUser(bankAppUser))
                {
                    return Ok();
                }

                return BadRequest();
            }));
        }
Exemplo n.º 2
0
        static void CreateUser()
        {
            BankAppUserManager manager = new BankAppUserManager();

            Console.Write("Enter Username: ");

            var username = Console.ReadLine();

            var bankAppUser = new BankAppUser()
            {
                Username = username
            };

            manager.CreateUser(bankAppUser);
        }