Hi Aran and thank you 1) OK, so it's obligatory to create a root node? Because in a tutorial, a guy has created a temporary controller to insert ARO/ACO/ACO_ARO and he has not created this root level... What kind of permissions and roles for this "root"?
2) Yes I'm using AclBehavior in models and AclComponent in controllers. But I don't understand why you said that AclBeavhior doesn't create alias?! It does! It doesn't create "model" and "foreign_key" and for you it's normal. OK, so what is the interest of "model" and "foreign_key" field in the ARO table? 3) Ok, you're right to this point, it's better useful to invert the tree! Sorry for my simple English: BR On 25 avr, 17:50, aranworld <[EMAIL PROTECTED]> wrote: > 1) The syntax in the end is correct. You could also do: > cake acl create aro root superadmin > > 2) When you create a node in the CLI, the model and foreign_key fields > are blank. If you want these fields added automatically, then you > need to add the nodes from within your application using the models > you created. I presume you are using the AclBehavior? Anyways, be > aware that the AclBehavior does NOT create the alias for you, so you > will have to create some coding to handle the alias creation > automatically. > > 3) I personally feel that it is easier to put the most generic user at > the top of my ARO tree and put the superuser at the bottom. Let's say > you have a user and an editor. > > If the editor is the parent of the user, you would have to do this: > > cake acl grant editor articles update > cake acl grant editor articles read > cake acl grant editor articles create > cake acl deny user articles update > cake acl deny user articles create > > If the user is the parent of the editor, then this is all you need: > > cake acl grant user read > cake acl grant editor create > cake acl grant editor update > > -Aran > > On Apr 25, 7:19 am,avairet<[EMAIL PROTECTED]> wrote: > > > Hi everybody, > > > I'm trying to use the ACL, but I don't understand some stuff. > > > I have created the 3 tables (aros, acos, aros_acos) with the CLI. > > Fine. > > I have a Groups table (called 'admin_groupes' in my case). > > I have a Users table (called 'administrateurs' in my case), with a FK > > called "admin_groupe_id" > > > I want create 3 aros : SuperAdmin, Admin, Redacteur that correspond to > > my AdminGroupes > > > So, I want create my first aro with the CLI and the mystery start! > > How must I launch my command in CLI? > > > Because I've tested this : > > > cake acl create aro AdminGroupe 1 null "Super Admin" > > > and I've this error message : Could not find parent node using > > reference "AdminGroupe" > > > If I launch this other command: > > > cake acl create aro / null "Super Admin" > > > I obtain this message : New Aro 'null' created. > > > And finally, if I launch : cake acl create aro / "Super Admin", that > > works fine, but the "model" and "foreign_key" fields from my aros > > table are empty... Why? Is it normal? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---