Page 1 of 1

PostPosted: Mon Apr 23, 2007 6:19 am
by cbovio
hello,

i use permissions with users profiles.

i need to hide some tables tabs with users profiles. how do that ?

thanks

PostPosted: Mon Apr 23, 2007 8:33 am
by shannah

Currently you can't do this.Ê The best way to achieve this sort of thing is to hide the tables menu using preferences:

http://framework.weblite.ca/documentation/manual/delegate_classes/application-delegate-class/getPreferences-method


And then make your own menu.

-Steve


PostPosted: Tue Apr 24, 2007 2:33 am
by cbovio
OK thanks.

I see in NavMenu template loop on $ENV.APPLICATION._tables

there are no possibilities to filter this in ApplicationDeleguate.php ?

PostPosted: Tue Apr 24, 2007 10:40 am
by shannah

OK.. you probably could filter this in the getPreferences() method.Ê You can access this array using:

$app =& Dataface_Application::getInstance();

$tables =& $app->_conf['_tables'];

if (userIsNotAllowedToSeeFooTable()){

ÊÊÊ unset($tables['foo']);

}