contributte / menu-control

🍔 Menu and breadcrumb components for Nette framework (@nette)
MIT License
29 stars 20 forks source link

Allow: module doesn't work #18

Closed FigaCZ closed 7 years ago

FigaCZ commented 8 years ago

When you set rights for menu item like this:

allow: roles: [root] module: Admin

method isAllowed() returns always true due to this OR condition in Item.php:634

$this->isAllowedForModule($this->getAllowedForModule()) || $this->isAllowedForParameters($this->getAllowedForParameters())

davidkudera commented 8 years ago

Hello, I would probably suggest you to use authorization by acl. I plan to rewrite this package completly in a near future and there'll be probably just this type of authorization (acl).

But of course this is a bug

davidkudera commented 7 years ago

There is now new concept using authorizators in 2.0.0.