@@ -23,4 +23,7 @@ export class RunnerOrganisation extends RunnerGroup {
 | 
				
			|||||||
 */
 | 
					 */
 | 
				
			||||||
  @OneToMany(() => RunnerTeam, team => team.parentGroup, { nullable: true })
 | 
					  @OneToMany(() => RunnerTeam, team => team.parentGroup, { nullable: true })
 | 
				
			||||||
  teams: RunnerTeam[];
 | 
					  teams: RunnerTeam[];
 | 
				
			||||||
 | 
					  public async getTeams() {
 | 
				
			||||||
 | 
					    return await getConnectionManager().get().getRepository(RunnerTeam).find({ parentGroup: this });
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -22,7 +22,6 @@ export class RunnerTeam extends RunnerGroup {
 | 
				
			|||||||
   * Returns all runners associated with this team.
 | 
					   * Returns all runners associated with this team.
 | 
				
			||||||
   */
 | 
					   */
 | 
				
			||||||
  public async getRunners() {
 | 
					  public async getRunners() {
 | 
				
			||||||
    let runnerRepo = await getConnectionManager().get().getRepository(Runner);
 | 
					    return await getConnectionManager().get().getRepository(Runner).find({ group: this });
 | 
				
			||||||
    return await runnerRepo.find({ group: this });
 | 
					 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
		Reference in New Issue
	
	Block a user