Update type for a model does not have nor id nor parentId #1392
Unanswered
PixelsCommander
asked this question in
Q&A
Replies: 1 comment 3 replies
-
|
Seem I had to read Prisma basics again. The behavior is odd but expected |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Prisma`s Update type for a model does not have nor id nor parentId.
The situation is - there is an item that has a category.
While editing an item I get the whole Item into its form values. When I try to submit a form update mutation errors on backend saying that id and categoryId are not expected to be on the ItemUpdate type.
The first one is solvable by removing id from the form data and keeping it into where only. This is annoying but works. But without categoryId I can not actually update category. Is this a bug? What do I do wrong?
Beta Was this translation helpful? Give feedback.
All reactions