motiondev
03/23/2022, 3:47 PMreturn ctx.prisma.dataProvider.update({
data: {
name: args.data?.name,
description: args.data?.description,
},
where: {
id: BigInt(args.data.id), // <===== I have to do this to every Prisma operation where I work with IDS
},
});
Is there something like a way to extend models to accept id as string and cast it at model level with BigInt(id)?
Thanks in advance!Austin
03/23/2022, 9:16 PMparams.args
for the id
field and then cast it to a BigInt
.motiondev
03/24/2022, 1:53 PM