YiiBackboneBoilerplate icon indicating copy to clipboard operation
YiiBackboneBoilerplate copied to clipboard

User access info

Open itsazzad opened this issue 12 years ago • 1 comments

What is the default user access info in the frontend and backend? What is the username and password? What is the source of user information or where will I add new users? What is the data structure/schema of user information? What are the necessary steps for the user login to be worked?

itsazzad avatar Feb 04 '13 21:02 itsazzad

Hello,

Insert this in your two files:

/frontend/componentes/Controller.php and /backend/componentes/Controller.php

public function filters()
{
    return array( 'accessControl' ); // perform access control
}

public function accessRules()
{
    return array(
        // logged in users can do whatever they want to
        array('allow', 'users' => array('@')),
        // not logged in users can't do anything except above
        array('deny'),
    );
}

With that all controllers will allow actions are taken only by authenticated users.

Luiz Fernando M. de Carvalho Belo Horizonte - MG

2013/2/4 itsazzad [email protected]

What is the default user access info in the frontend and backend? What are the necessary steps for the user login to be worked?

— Reply to this email directly or view it on GitHubhttps://github.com/clevertech/YiiBackboneBoilerplate/issues/8.

luizmcarvalho avatar Feb 04 '13 21:02 luizmcarvalho