Exemplo n.º 1
0
        public async Task <IActionResult> RegisterNewUser([FromBody] ApplicationUserPostModel request)
        {
            await requestExecutor.ExecuteCommandAsync(new CreateUserCommand(request.Login, request.Password,
                                                                            request.Email, request.FirstName, request.LastName));

            return(Ok());
        }
Exemplo n.º 2
0
        public async Task <IActionResult> RegisterNewUser2()
        {
            ApplicationUserPostModel request = new ApplicationUserPostModel();

            request.Login     = "******";
            request.Password  = "******";
            request.Email     = "*****@*****.**";
            request.FirstName = "Mike";
            request.LastName  = "Gray";

            await requestExecutor.ExecuteCommandAsync(new CreateUserCommand(request.Login, request.Password,
                                                                            request.Email, request.FirstName, request.LastName));

            return(Ok());
        }