P
P
Pavel Gogolinsky2015-07-08 12:41:16
Yii
Pavel Gogolinsky, 2015-07-08 12:41:16

How to stop picking pears?

RBAC.
There are two roles: appleCollector and pearCollector. One for the apple picker, the other for the pear picker.
Possible promotion and demotion, ie. an apple picker can become a pear picker and vice versa.
The important thing is that the picker of apples under no circumstances has the right to pick pears and vice versa.
Is it possible to configure RBAC in such a way that the appleCollector role automatically disables pearCollector and pearCollector disables appleCollector?
Or do you need methods to write addAppleRole() and addPearRole(), in which to give one role and remove another?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
B
bkosun, 2015-07-08
@bkosun

If the roles are not interrelated, then you need to remove one and add another, if necessary. What promotion/demotion are we talking about if an apple picker cannot become a pear picker and vice versa? It's just a change of activity/role.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question