Skip to content
This repository has been archived by the owner on Nov 29, 2021. It is now read-only.

Commit

Permalink
feat: define CreateAgendaInput
Browse files Browse the repository at this point in the history
  • Loading branch information
YanceyOfficial committed Feb 2, 2020
1 parent b5e7875 commit 3a86869
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions src/agenda/dtos/create-agenda.input.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import { InputType, Field } from 'type-graphql'
import { IsString, IsNotEmpty, IsDate } from 'class-validator'

@InputType()
export class CreateAgendaInput {
@Field()
@IsString()
@IsNotEmpty()
public readonly title: string

@Field()
@IsDate()
@IsNotEmpty()
public readonly startDate: Date

@Field()
@IsDate()
public readonly endDate?: Date

@Field()
@IsString()
public readonly rRule?: string

@Field()
@IsDate()
public readonly exDate?: Date
}

0 comments on commit 3a86869

Please sign in to comment.