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

Access to entity on permissions builder (outdated docs) #592

Open
andreassh opened this issue Nov 13, 2023 · 0 comments
Open

Access to entity on permissions builder (outdated docs) #592

andreassh opened this issue Nov 13, 2023 · 0 comments

Comments

@andreassh
Copy link

In the docs it states that you can access the current entity in the permissionsBuilder.
This seems outdated according to the types.d definitions. Docs says that you the permissionsBuilder is called with following properties:

{
    entity,
    path,
    user,
    authController,
    context
}

But types says its called with:

{ 
  pathSegments, 
  user, 
  collection,
  authController 
} 

Which seems to be right.

But what can be done do make permissions dependent on properties on and entity in v. 2.2.0?
E.g. if you want do disable create, depending on an entity prop?

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

1 participant