hidden fields on whereUniqueInput should be excluded from Prisma.AtLeast<> in Args classes
bobschulte opened this issue · 0 comments
bobschulte commented
I have my "id" field hidden from all inputs and outputs.
/// @HideField({ input: true, output: true})
id Int @id @default(autoincrement())
Since I have other unique fields on User (username & email), shouldn't the desired behavior be that it would not show up in my various generated args classes as well? For example:
@ArgsType()
export class FindUniqueUserOrThrowArgs {
@Field(() => UserWhereUniqueInput, {nullable:false})
@Type(() => UserWhereUniqueInput)
where!: Prisma.AtLeast<UserWhereUniqueInput, 'id' | 'username' | 'email'>;
}
Even though 'id' is correctly receiving a HideField decorator in my UserWhereUniqueInput generated class, it would be desirable for 'id' to be excluded from the Prisma.AtLeast here as well within the generated args class.