src/workspace/dtos/workspace-stats.dto.ts
Properties |
|
| Readonly Optional prev_days_start_date |
Type : number
|
Default value : 0
|
Decorators :
@ApiPropertyOptional({description: 'Number of days in the past to start range block', default: 0, type: 'integer'})
|
|
Defined in src/workspace/dtos/workspace-stats.dto.ts:26
|
| Readonly Optional range |
Type : number
|
Default value : 30
|
Decorators :
@ApiPropertyOptional({description: 'Range in days', default: 30, type: 'integer'})
|
|
Defined in src/workspace/dtos/workspace-stats.dto.ts:15
|
| Optional repos |
Type : string[]
|
Decorators :
@ApiPropertyOptional({description: 'An array of repo names to filter for', isArray: true, example: undefined})
|
|
Defined in src/workspace/dtos/workspace-stats.dto.ts:36
|
import { ApiPropertyOptional } from "@nestjs/swagger";
import { Type } from "class-transformer";
import { IsArray, IsIn, IsInt, IsOptional } from "class-validator";
export class WorkspaceStatsOptionsDto {
@ApiPropertyOptional({
description: "Range in days",
default: 30,
type: "integer",
})
@Type(() => Number)
@IsIn([7, 30, 90, 180, 360])
@IsInt()
@IsOptional()
readonly range?: number = 30;
@ApiPropertyOptional({
description: "Number of days in the past to start range block",
default: 0,
type: "integer",
})
@Type(() => Number)
@IsIn([0, 7, 30, 90, 180])
@IsInt()
@IsOptional()
readonly prev_days_start_date?: number = 0;
@ApiPropertyOptional({
description: "An array of repo names to filter for",
isArray: true,
example: ["open-sauced/api", "open-sauced/app"],
})
@IsArray()
@IsOptional()
@Type(() => String)
repos?: string[];
}