You are here

public function TeamMemberRoleStorage::loadByTeam in Apigee Edge 8

Loads all team roles of all team members within a team.

WARNING: The fact whether the developer is actually member of the team (company) in Apigee Edge is not being verified here. The caller should perform this check if needed. Thanks for this approach we can minimize the API calls that are being sent to Apigee Edge.

Parameters

\Drupal\apigee_edge_teams\Entity\TeamInterface $team: Team entity object.

Return value

\Drupal\apigee_edge_teams\Entity\TeamMemberRoleInterface[] Array of team member role objects related to a team.

Overrides TeamMemberRoleStorageInterface::loadByTeam

File

modules/apigee_edge_teams/src/Entity/Storage/TeamMemberRoleStorage.php, line 137

Class

TeamMemberRoleStorage
Entity storage class for team member role entities.

Namespace

Drupal\apigee_edge_teams\Entity\Storage

Code

public function loadByTeam(TeamInterface $team) : array {
  return $this
    ->loadByProperties([
    'team' => $team
      ->id(),
  ]);
}