If it makes sense for your application it is perfectly logical to have both custom layouts and views for each type of user. Just make sure you call $this->layout=’//layouts/customlayout’ (or whatever) at the beginning of the controller action that handles the custom view (the recipient of the render() method in the login action).
public function beforeControllerAction($controller, $action)
{
$roles=Rights::getAssignedRoles(Yii::app()->user->Id); // check for single role
foreach($roles as $role)
{
if(sizeof($roles)==1 and $role->name == 'parent')
{
$controller->layout='none';
}
if(sizeof($roles)==1 and $role->name == 'student')
{
$controller->layout='studentmain';
}
if(sizeof($roles)==1 and $role->name == 'teacher')
{
$controller->layout='teachers';
}
}