Skip to content

Instantly share code, notes, and snippets.

@eddpascoal
Created May 21, 2014 11:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save eddpascoal/9bcfc17fab097c42fe95 to your computer and use it in GitHub Desktop.
Save eddpascoal/9bcfc17fab097c42fe95 to your computer and use it in GitHub Desktop.
public $components = array(
'DebugKit.Toolbar',
'Session',
'Auth' => array(
'loginAction' => array('controller' => 'Users', 'action' => 'login'),
'logoutRedirect' => array('controller' => 'Users', 'action' => 'login'),
'authenticate' => array('Form' => array(
'userModel' => 'User',
'fields' => array(
'username' => 'email',
'password' => 'password'
),
'scope' => array('User.activo' => 'Sim')
)
),
'scope' => array('User.activo' => 'Sim'),
'authorize' => 'Controller',
'allow' => array('index', 'view'),
'authError'=> "Não tem acesso à pagina.",
'authorize' =>array('Controller'))
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment