Policies of the uiswitch module
The policy functions of uiswitch and their limitations, from $FunctionList in kernel/uiswitch/module.php. In the administration they are chosen under Roles and policies; a policy on uiswitch/* grants every function.
design
Checked by the views: set, state.
No limitations: the policy is all or nothing.
// Give a role the policy (eZRole::appendPolicy( $module, $function, $limitations ))
$role = eZRole::fetchByName( 'Editor' );
$role->appendPolicy( 'uiswitch', 'design' );if fetch( 'user', 'has_access_to', hash( 'module', 'uiswitch', 'function', 'design' ) )
...
/iflanguage
Checked by the views: set, state.
No limitations: the policy is all or nothing.
// Give a role the policy (eZRole::appendPolicy( $module, $function, $limitations ))
$role = eZRole::fetchByName( 'Editor' );
$role->appendPolicy( 'uiswitch', 'language' );if fetch( 'user', 'has_access_to', hash( 'module', 'uiswitch', 'function', 'language' ) )
...
/ifRelated
Generated by ./console exp:help:examples from kernel/uiswitch/module.php, kernel/classes/ezrole.php. Do not edit this page: change the source and generate again (how). Free documentation: GFDL 1.3 or later.