cms
cms copied to clipboard
fix: resolve database seeding issue
This PR fixes the issue with the database seeding process, which was failing due to a unique constraint violation on the id field of the Content model.
Changes:
-
Updated the
seedContentfunction to create the folder first, and then generate content items with dynamic IDs and the correctparentIdreferencing the folder's ID. -
Removed the hard-coded
idvalues from the content items, as Prisma will now generate unique IDs automatically.
before :
after:
@hkirat can u check this >?