public async Task <IActionResult> PutProduct(int id, UserRequestCommand userRequest) { var command = new UserUpdateCommand(userRequest, id); var result = await _mediator.Send(command); return(result != null ? (IActionResult)Ok(result) : NotFound(string.Format(ModelConstants.PropertyNotFoundFromController, "იუზერი"))); }
public async Task <IActionResult> PostUser(UserRequestCommand command) { var result = await _mediator.Send(command); return(CreatedAtAction("GetUser", new { id = result.Id }, result)); }