From 63b1ca9b56d3c729a441390ca4b4dd1134ae0a37 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Sun, 3 Jan 2021 16:51:36 +0100 Subject: [PATCH] Added the minimum lap time to the track entity ref #71 --- src/models/entities/Track.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/models/entities/Track.ts b/src/models/entities/Track.ts index 22544d0..0636606 100644 --- a/src/models/entities/Track.ts +++ b/src/models/entities/Track.ts @@ -1,6 +1,7 @@ import { IsInt, IsNotEmpty, + IsOptional, IsPositive, IsString } from "class-validator"; @@ -38,6 +39,16 @@ export class Track { @IsPositive() distance: number; + /** + * The minimum time a runner should take to run a lap on this track. + * Will be used for fraud detection. + */ + @Column() + @IsInt() + @IsOptional() + @IsPositive() + minimumLapTime: number; + /** * Used to link scan stations to a certain track. * This makes the configuration of the scan stations easier.