19 lines
570 B
TypeScript
19 lines
570 B
TypeScript
import { Field } from '@nestjs/graphql';
|
|
import { ArgsType } from '@nestjs/graphql';
|
|
import { UserCreateManyInput } from './user-create-many.input';
|
|
import { Type } from 'class-transformer';
|
|
import { ValidateNested } from 'class-validator';
|
|
|
|
@ArgsType()
|
|
export class CreateManyUserArgs {
|
|
|
|
@Field(() => [UserCreateManyInput], {nullable:false})
|
|
@Type(() => UserCreateManyInput)
|
|
@Type(() => UserCreateManyInput)
|
|
@ValidateNested({each: true})
|
|
data!: Array<UserCreateManyInput>;
|
|
|
|
@Field(() => Boolean, {nullable:true})
|
|
skipDuplicates?: boolean;
|
|
}
|