public void Handle(RegistrarNovoUsuarioCommand command) { if (!command.IsValid()) { } Cadastro cadastro = new Cadastro(command.Senha); Usuario usuario = new Usuario(command.Nome, command.Sobrenome, command.Email, command.CPF, command.DataNascimento); usuario.CriarNovoCadastro(cadastro); var usuarioBase = _usuarioRepository.ObtemPorCPF(); if (usuario == null) { } //TODO: UoW _usuarioRepository.Add(usuario); _usuarioRepository.SaveChanges(); }
public Task <Result <RegistrarNovoUsuarioResponse> > Handle(RegistrarNovoUsuarioCommand request, CancellationToken cancellationToken) { throw new NotImplementedException(); }