Column-Value-Based-Permissions
Posted: 2020-03-20 09:50
Hi,
me again.
I created a new permission check: Column-Value-Based permissions (CVB) enable you to hide certain records from usergroups if
these records have a specific value in a (lookup) field.
What does it do?
You have project managers and each project manager should only see projects that are assigned to him/her. Let’s say usergroup North has projects Greenland, Norway and Kenya (yes, I know this is pretty equator, but wait, you will read in a minute why it’s there). Another usergroup of your
application names South has South Africa, Australia and Kenya. You notice: Both have Kenya.
Now think, that your table “travels†has a column “country†that holds the country with currently possible values of Greenland, Norway, Kenya, South Africa and Australia.
This extension of AG enables you to show the entries of table “travels†based on the fields value of the column country, resulting in this: Usergroup North sees only records from it’s area: Greenland, Norway and Kenya. Group South sees only South Africa, Australia and Kenya. Both groups work
on Kenya, so both have access to them. Other records that do not match the criteria (for options, see below), are not shown. Short: In tableview (TV) - see or no see; in detailview (DV) allow access or do not allow access.
CVB is different from AG’s permissions model as in CVB one user can “belong†to different groups at the same time.
It looks like this (in the demo)
Permissions table Data the superadmin sees Data usergroup North sees Data usergroup South sees
It's working for me and while documenting I think I fixed some bugs, so go ahead and try (and give feedback).
In my opinion it's much easier to implement that my Field-Permissions extension ( viewtopic.php?f=4&t=3308&start=25 ).
Download v0.8 (340 KB)
https://dl.olaf-noehring.de/?t=8c3138f6 ... acbe9f8cf0
Download complete AG demo v0.8 (1.2 MB, does not include how-to/docs!)
AXP file, generated and extended application, complete SQL just throw on your testserver and try
https://dl.olaf-noehring.de/?t=6f16271e ... 2a19857846
Suggestions? Feedback? Please.
Olaf
me again.
I created a new permission check: Column-Value-Based permissions (CVB) enable you to hide certain records from usergroups if
these records have a specific value in a (lookup) field.
What does it do?
You have project managers and each project manager should only see projects that are assigned to him/her. Let’s say usergroup North has projects Greenland, Norway and Kenya (yes, I know this is pretty equator, but wait, you will read in a minute why it’s there). Another usergroup of your
application names South has South Africa, Australia and Kenya. You notice: Both have Kenya.
Now think, that your table “travels†has a column “country†that holds the country with currently possible values of Greenland, Norway, Kenya, South Africa and Australia.
This extension of AG enables you to show the entries of table “travels†based on the fields value of the column country, resulting in this: Usergroup North sees only records from it’s area: Greenland, Norway and Kenya. Group South sees only South Africa, Australia and Kenya. Both groups work
on Kenya, so both have access to them. Other records that do not match the criteria (for options, see below), are not shown. Short: In tableview (TV) - see or no see; in detailview (DV) allow access or do not allow access.
CVB is different from AG’s permissions model as in CVB one user can “belong†to different groups at the same time.
It looks like this (in the demo)
Permissions table Data the superadmin sees Data usergroup North sees Data usergroup South sees
It's working for me and while documenting I think I fixed some bugs, so go ahead and try (and give feedback).
In my opinion it's much easier to implement that my Field-Permissions extension ( viewtopic.php?f=4&t=3308&start=25 ).
Download v0.8 (340 KB)
https://dl.olaf-noehring.de/?t=8c3138f6 ... acbe9f8cf0
Download complete AG demo v0.8 (1.2 MB, does not include how-to/docs!)
AXP file, generated and extended application, complete SQL just throw on your testserver and try
https://dl.olaf-noehring.de/?t=6f16271e ... 2a19857846
Suggestions? Feedback? Please.
Olaf