Compare commits
No commits in common. "42d3f9cb9896c3fac60aca4a6049a7a3ed51ea06" and "0a0050368fa0e921e20efe43f653c672c7f477ae" have entirely different histories.
42d3f9cb98
...
0a0050368f
@ -66,7 +66,7 @@ export class RunnerOrganisationController {
|
|||||||
@ResponseSchema(RunnerOrganisationIdsNotMatchingError, { statusCode: 406 })
|
@ResponseSchema(RunnerOrganisationIdsNotMatchingError, { statusCode: 406 })
|
||||||
@OpenAPI({ description: "Update a runnerOrganisation object (id can't be changed)." })
|
@OpenAPI({ description: "Update a runnerOrganisation object (id can't be changed)." })
|
||||||
async put(@Param('id') id: number, @EntityFromBody() runnerOrganisation: RunnerOrganisation) {
|
async put(@Param('id') id: number, @EntityFromBody() runnerOrganisation: RunnerOrganisation) {
|
||||||
let oldRunnerOrganisation = await this.runnerOrganisationRepository.findOne({ id: id });
|
let oldRunnerOrganisation = await this.runnerOrganisationRepository.findOne({ id: id }, { relations: ['address', 'contact', 'teams'] });
|
||||||
|
|
||||||
if (!oldRunnerOrganisation) {
|
if (!oldRunnerOrganisation) {
|
||||||
throw new RunnerOrganisationNotFoundError();
|
throw new RunnerOrganisationNotFoundError();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user