Skip to content
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

Support M:N relation #68

Open
CodeXiD opened this issue Feb 27, 2024 · 1 comment
Open

Support M:N relation #68

CodeXiD opened this issue Feb 27, 2024 · 1 comment

Comments

@CodeXiD
Copy link

CodeXiD commented Feb 27, 2024

Hello, thank you for your work, it is very valuable to us. I would like to know if there are plans to support M:N relation. I know that this can be done through the "relations" package, but you need to create an intermediate table yourself. It would be very cool if it were possible to describe the connection in a simple way

@ManyToMany(() => Category)
@JoinTable()
categories: Category[]

I probably would have sent this issue to the "relations" package, but as I understand it is closed) Thanks for any comment

@dziraf
Copy link

dziraf commented Feb 27, 2024

AdminJS requires an actual model for junction table to run queries and this kind of model isn't generated automatically by TypeORM. The same applies to other ORMs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants