parent
28fb9834e1
commit
56c73c2555
@ -94,7 +94,7 @@ export class RunnerOrganisationController {
|
|||||||
@ResponseSchema(RunnerOrganisationHasTeamsError, { statusCode: 406 })
|
@ResponseSchema(RunnerOrganisationHasTeamsError, { statusCode: 406 })
|
||||||
@ResponseSchema(RunnerOrganisationHasRunnersError, { statusCode: 406 })
|
@ResponseSchema(RunnerOrganisationHasRunnersError, { statusCode: 406 })
|
||||||
@OnUndefined(204)
|
@OnUndefined(204)
|
||||||
@OpenAPI({ description: 'Delete the organsisation whose id you provided. <br> If the organisation still has runners and/or teams associated this will fail. <br> To delete the organisation with all associated runners and teams set the force QueryParam to true (cascading deletion might take a while). <br> If no organisation with this id exists it will just return 204(no content).' })
|
@OpenAPI({ description: 'Delete the organsisation whose id you provided. <br> If the organisation still has runners and/or teams associated this will fail. <br> To delete the organisation with all associated runners and teams set the force QueryParam to true (cascading deletion might take a while). <br> This won\'t delete the associated contact. <br> If no organisation with this id exists it will just return 204(no content).' })
|
||||||
async remove(@Param("id") id: number, @QueryParam("force") force: boolean) {
|
async remove(@Param("id") id: number, @QueryParam("force") force: boolean) {
|
||||||
let organisation = await this.runnerOrganisationRepository.findOne({ id: id });
|
let organisation = await this.runnerOrganisationRepository.findOne({ id: id });
|
||||||
if (!organisation) { return null; }
|
if (!organisation) { return null; }
|
||||||
|
@ -93,7 +93,7 @@ export class RunnerTeamController {
|
|||||||
@ResponseSchema(ResponseEmpty, { statusCode: 204 })
|
@ResponseSchema(ResponseEmpty, { statusCode: 204 })
|
||||||
@ResponseSchema(RunnerTeamHasRunnersError, { statusCode: 406 })
|
@ResponseSchema(RunnerTeamHasRunnersError, { statusCode: 406 })
|
||||||
@OnUndefined(204)
|
@OnUndefined(204)
|
||||||
@OpenAPI({ description: 'Delete the team whose id you provided. <br> If the team still has runners associated this will fail. <br> To delete the team with all associated runners set the force QueryParam to true (cascading deletion might take a while). <br> If no team with this id exists it will just return 204(no content).' })
|
@OpenAPI({ description: 'Delete the team whose id you provided. <br> If the team still has runners associated this will fail. <br> To delete the team with all associated runners set the force QueryParam to true (cascading deletion might take a while). <br> This won\'t delete the associated contact.<br> If no team with this id exists it will just return 204(no content).' })
|
||||||
async remove(@Param("id") id: number, @QueryParam("force") force: boolean) {
|
async remove(@Param("id") id: number, @QueryParam("force") force: boolean) {
|
||||||
let team = await this.runnerTeamRepository.findOne({ id: id });
|
let team = await this.runnerTeamRepository.findOne({ id: id });
|
||||||
if (!team) { return null; }
|
if (!team) { return null; }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user