Implemented the basic request classes feature/1-input_classes #2

Merged
niggl merged 9 commits from feature/1-input_classes into dev 2021-02-03 16:49:23 +00:00
2 changed files with 7 additions and 5 deletions
Showing only changes of commit aae4f507ea - Show all commits

View File

@ -1,12 +1,14 @@
import { import {
IsInt, IsInt,
IsObject,
IsString IsString
} from "class-validator"; } from "class-validator";
import { RunnerGroup } from './RunnerGroup';
/** /**
* Defines the contract runner class (from which the runner sponsoring contracts get generated). * Defines the contract runner class (from which the runner sponsoring contracts get generated).
*/ */
export class ContractRunner { export class Runner {
/** /**
* The runner's id. * The runner's id.
*/ */
@ -34,6 +36,6 @@ export class ContractRunner {
/** /**
* The runner's group. * The runner's group.
*/ */
@IsString() @IsObject()
group: string; group: RunnerGroup;
} }

View File

@ -5,7 +5,7 @@ import {
IsObject, IsObject,
IsString IsString
} from "class-validator"; } from "class-validator";
import { ContractRunner } from './ContractRunner'; import { Runner } from './Runner';
/** /**
* Defines the runner card class (used to create runner card pdfs). * Defines the runner card class (used to create runner card pdfs).
@ -21,7 +21,7 @@ export class RunnerCard {
* The card's associated runner. * The card's associated runner.
*/ */
@IsObject() @IsObject()
runner: ContractRunner | null; runner: Runner | null;
/** /**
* The card's code. * The card's code.