docs(views): update to denote dynamic permissions

ref: #248 #345 #374
This commit is contained in:
2024-11-01 18:55:05 +09:30
parent d20a1460da
commit 223e78ae07

View File

@ -37,13 +37,12 @@ Views are used with Centurion ERP to Fetch the data for rendering.
## Permissions
If you wish to deviate from the standard CRUD permissions, define a function called `get_dynamic_permissions` within the `view`/`ViewSet`. The function must return a list of permissions. This is useful if you have added additional permissions to a model.
If you wish to deviate from the standard CRUD permissions, define a function called `get_dynamic_permissions` within the `view`/`ViewSet`. The function must return a list of permissions. This is useful if you have added additional permissions to a model.
Example of the function `get_dynamic_permissions`
``` py
def get_dynamic_permissions(self):
if self.action == 'create':