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

View File

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