File

src/published-data/dto/create-published-data.dto.ts

Index

Properties

Properties

Readonly Optional _id
Type : string
Decorators :
@IsString()
@IsOptional()
Readonly abstract
Type : string
Decorators :
@IsString()
Readonly Optional affiliation
Type : string
Decorators :
@IsString()
@IsOptional()
Readonly Optional authors
Type : string[]
Decorators :
@IsString({each: true})
@IsOptional()
Readonly creator
Type : string[]
Decorators :
@IsString({each: true})
Readonly dataDescription
Type : string
Decorators :
@IsString()
Readonly Optional doi
Type : string
Decorators :
@IsString()
@IsOptional()
Readonly Optional downloadLink
Type : string
Decorators :
@IsString()
@IsOptional()
Readonly Optional numberOfFiles
Type : number
Decorators :
@IsNumber()
@IsOptional()
Readonly pidArray
Type : string[]
Decorators :
@IsString({each: true})
Readonly publicationYear
Type : number
Decorators :
@IsNumber()
Readonly publisher
Type : string
Decorators :
@IsString()
Readonly Optional registeredTime
Type : Date
Decorators :
@IsDateString()
@IsOptional()
Readonly Optional relatedPublications
Type : string[]
Decorators :
@IsString({each: true})
@IsOptional()
Readonly resourceType
Type : string
Decorators :
@IsString()
Readonly Optional scicatUser
Type : string
Decorators :
@IsString()
@IsOptional()
Readonly Optional sizeOfArchive
Type : number
Decorators :
@IsNumber()
@IsOptional()
Readonly Optional status
Type : string
Decorators :
@IsString()
@IsOptional()
Readonly Optional thumbnail
Type : string
Decorators :
@IsString()
@IsOptional()
Readonly title
Type : string
Decorators :
@IsString()
Readonly Optional url
Type : string
Decorators :
@IsString()
@IsOptional()
import { IsDateString, IsOptional, IsString, IsNumber } from "class-validator";

export class CreatePublishedDataDto {
  @IsString()
  @IsOptional()
  readonly _id?: string;

  @IsString()
  @IsOptional()
  readonly doi?: string;

  @IsString()
  @IsOptional()
  readonly affiliation?: string;

  @IsString({
    each: true,
  })
  readonly creator: string[];

  @IsString()
  readonly publisher: string;

  @IsNumber()
  readonly publicationYear: number;

  @IsString()
  readonly title: string;

  @IsString()
  @IsOptional()
  readonly url?: string;

  @IsString()
  readonly abstract: string;

  @IsString()
  readonly dataDescription: string;

  @IsString()
  readonly resourceType: string;

  @IsNumber()
  @IsOptional()
  readonly numberOfFiles?: number;

  @IsNumber()
  @IsOptional()
  readonly sizeOfArchive?: number;

  @IsString({
    each: true,
  })
  readonly pidArray: string[];

  @IsString({
    each: true,
  })
  @IsOptional()
  readonly authors?: string[];

  @IsDateString()
  @IsOptional()
  readonly registeredTime?: Date;

  @IsString()
  @IsOptional()
  readonly status?: string;

  @IsString()
  @IsOptional()
  readonly scicatUser?: string;

  @IsString()
  @IsOptional()
  readonly thumbnail?: string;

  @IsString({
    each: true,
  })
  @IsOptional()
  readonly relatedPublications?: string[];

  @IsString()
  @IsOptional()
  readonly downloadLink?: string;
}

results matching ""

    No results matching ""