From 9395813f5aafb282a50b8e2313a3022737e7decc Mon Sep 17 00:00:00 2001 From: Philipp Dormann Date: Thu, 3 Dec 2020 17:55:27 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=A7=20Scan.ts=20-=20secondsSinceLastSc?= =?UTF-8?q?an?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/models/Scan.ts | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/src/models/Scan.ts b/src/models/Scan.ts index 3fd64ed..5e8cbf9 100644 --- a/src/models/Scan.ts +++ b/src/models/Scan.ts @@ -35,11 +35,19 @@ export abstract class Scan { @IsPositive() abstract distance: number; - /** - * Is the scan valid (for fraud reasons). - * Default: true - */ + /** + * Is the scan valid (for fraud reasons). + * Default: true + */ @Column() @IsBoolean() valid: boolean = true; + + /** + * seconds since last scan + */ + @IsInt() + @IsOptional() + secondsSinceLastScan: number; + }