public async Task <ActionResult <TeamModel> > GetTeam([Required] Guid managerId) { var response = await _getTeamDetailsOperation .Execute(new GetTeamDetailsOperationRequest { ManagerId = managerId }); var model = new TeamModel(response); return(Ok(model)); }
public async Task <GetTeamDetailsOperationResponse> Execute() { var employee = await _authorizationContext.CurrentEmployee(); var getMySubordinatesRequest = new GetTeamDetailsOperationRequest { ManagerId = employee.Id }; return(await _getTeamDetailsOperation.Execute(getMySubordinatesRequest)); }