Replies: 2 comments
-
There is no
|
Beta Was this translation helpful? Give feedback.
0 replies
-
I have a similar use case. Each classDiagram
direction RL
class capabilities {
varchar(20) id
}
class capability_role {
varchar(20) role_id
varchar(20) capability_id
integer id
}
class roles {
varchar(20) id
}
class users {
varchar(255) email
varchar(180) password
varchar(255) remember_me_token
varchar(20) role
integer id
}
capabilities --> capability_role
roles --> capability_role
roles --> users
I don't fully understand whether it's possible to use What I want: await auth.user.load('capabilities')
auth.user.capabilities // [{id: 'cap1'}, {id: 'cap2'}] What I actually should do: await auth.user.load('role')
await auth.user.role.load('capabilities')
// or
await auth.user.load('role', (q) => q.preload('capabilities'))
auth.user.role.capabilities // [{id: 'cap1'}, {id: 'cap2'}] |
Beta Was this translation helpful? Give feedback.
0 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.
-
There is a relationship called hasManyThrough. But does it exist manyToManyThrough?
In my app, companies can belong to multiple lists and a team can have multiple lists.
Company <=> Company_List <=> List <=> Team
I would like to retrieve paginated results of companies that belong to a specific team
Beta Was this translation helpful? Give feedback.
All reactions