Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Well, I use <a href="http://www.yiiframework.com/" rel="nofollow">Yii framework</a> with its nice RBAC layer. I'm not too familiar with ACLs, nor did I need to be, lately.</p> <p>In Yii RBAC terms, your key to the solution is using 'business rules'. Bizrules are small snippets of code that are attached to a 'permission' or a 'role' (an 'auth item' in Yii's terms). This code is run dynamically when the need to determine access to a certain 'permission' (lets say, but it could also be attached to a 'role'), and it recieves the 'item in question' (task in your example) and determine actual access to the specific task or not. Here's a more detailed example:</p> <ul> <li>say you need to have the following permissions: <ul> <li>Edit task (which should be allowed to anyone with the role 'tasks administrator')</li> <li>Edit own tasks (which should be allowed to the person who submitted <em>this</em> task).</li> </ul></li> <li>Now, in the 'task edit' code section, you would first check for 'edit task' permission. if ok - allow.</li> <li>if wasn't allowed, also check for 'edit own task' (using else-if construct). Now on the last mentioned permission there should be attached a bizrule (=php code) that accepts a 'task' object and compares its 'creator id' to the 'currently checked user id'. If equal, it returns true, meaning access should be granted.</li> </ul> <p>That's in a nutshell. If you're interested in more, see <a href="http://www.yiiframework.com/doc/guide/1.1/en/topics.auth#role-based-access-control" rel="nofollow">this section</a> of the official guide. There are also a bunch of other resources, should you need.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload