-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat/support many to many relations #947
base: main
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@prakha is attempting to deploy a commit to the ROUTE06 Core Team on Vercel. A member of the Team first needs to authorize it. |
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
This comment was marked as off-topic.
This comment was marked as off-topic.
PR Code Suggestions ✨Explore these optional code suggestions:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!! Could you add a test cases for parser?
yes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@prakha I'm sorry, I was mistaken. What we wanted to do here was not to add "MANY_TO_MANY" to the cardinality, but to render the table that Prisma creates in a implicit way.
Please read this comment? #609 (comment)
@MH4GF Okay, should I remove the relationship between the two tables when hovering over the table? |
@prakha Thanks!
Yeah, this is a little bad as UX. However, if you can display an implicit table and use “one to many” to display it, there is no problem. |
Issue
Why is this change needed?
There was no support for many-to-many relationships when parsing through Prisma. This branch adds support for many-to-many relationships.
What would you like reviewers to focus on?
I want the reviewer to review the logic of the code when there exist a "many to many" relationship and the generation of the join table to define the relationship.
Testing Verification
What was done
🤖 Generated by PR Agent at 5396a3b
Detailed Changes
parser.ts
Implement "many-to-many" relationship parsing and join table creation
frontend/packages/db-structure/src/parser/prisma/parser.ts
dbStructure.ts
Extend cardinality schema to include "MANY_TO_MANY"
frontend/packages/db-structure/src/schema/dbStructure.ts
RelationshipEdge.tsx
Prevent rendering of "many-to-many" relationship edges
frontend/packages/erd-core/src/features/erd/components/ERDContent/components/RelationshipEdge/RelationshipEdge.tsx
relationships.
Additional Notes