Get all Teams related to current record

This will allow you to programmatically get all teams that have been assigned to the current record.

The function wrapping is simply there so you know where $bean originated from.

<?php
public function process_records($bean, $event, $arguments) {
	$teamSetBean = new TeamSet();
	$teams = $teamSetBean->getTeams($bean->team_set_id);
	foreach ($teams as $team) {
		echo $team->name . ': ' . $team->id;
	}
}

 team_set_id contains the id for the set of data that relates to what teams the record is a part of. Basically you're just calling the TeamSet and loading by the id given.

At the time of this writing you can find the TeamSet::getTeams() function within modules/Teams/TeamSet.php Line 84

Print