Пример #1
0
        public async Task <string> Novo(Cliente cliente)
        {
            string ret = null;

            try
            {
                SegurancaClienteHelper helper = new SegurancaClienteHelper();
                ContaCriada            conta  = await helper.CriarContaSegura();

                if (conta != null)
                {
                    if (_repo.AbertaContaCliente(cliente, conta.NumeroConta))
                    {
                        ret = conta.NumeroConta;
                    }
                }
            }
            catch (Exception)
            {
                ret = null;
            }

            return(ret);
        }