29 lines
800 B
TypeScript
29 lines
800 B
TypeScript
import { ApiProperty } from '@nestjs/swagger';
|
|
import { GetReportDataDto } from './report-data.get.dto';
|
|
import { IsString, IsNumber, IsOptional, IsArray } from 'class-validator';
|
|
import { ColumnStateEntity } from '../entities/query-model.entity';
|
|
|
|
export class CreateReportExportDto extends GetReportDataDto {
|
|
@ApiProperty({ name: 'time_zone', required: true, default: 'Asia/Jakarta' })
|
|
@IsString()
|
|
time_zone: string;
|
|
|
|
@ApiProperty({ name: 'file_name', required: true })
|
|
@IsString()
|
|
file_name?: string;
|
|
|
|
@ApiProperty({
|
|
name: 'column_state',
|
|
type: [Object],
|
|
required: true,
|
|
default: [
|
|
{ colId: 'main__created_at' },
|
|
{ colId: 'main__updated_at' },
|
|
{ colId: 'main__name' },
|
|
],
|
|
})
|
|
@IsOptional()
|
|
@IsArray()
|
|
column_state: ColumnStateEntity[];
|
|
}
|