change permission for reports
This commit is contained in:
parent
aea2c52124
commit
24e3dce192
@ -23,21 +23,24 @@ class ReportsController extends Controller
|
|||||||
public function behaviors()
|
public function behaviors()
|
||||||
{
|
{
|
||||||
return [
|
return [
|
||||||
|
'as AccessBehavior' => [
|
||||||
|
'class' => \developeruz\db_rbac\behaviors\AccessBehavior::className(),
|
||||||
|
],
|
||||||
'verbs' => [
|
'verbs' => [
|
||||||
'class' => VerbFilter::className(),
|
'class' => VerbFilter::className(),
|
||||||
'actions' => [
|
'actions' => [
|
||||||
'delete' => ['POST'],
|
'delete' => ['POST'],
|
||||||
],
|
],
|
||||||
],
|
],
|
||||||
'access' => [
|
// 'access' => [
|
||||||
'class' => AccessControl::className(),
|
// 'class' => AccessControl::className(),
|
||||||
'rules' => [
|
// 'rules' => [
|
||||||
[
|
// [
|
||||||
'allow' => true,
|
// 'allow' => true,
|
||||||
'roles' => ['admin'],
|
// 'roles' => ['admin'],
|
||||||
],
|
// ],
|
||||||
],
|
// ],
|
||||||
],
|
// ],
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -93,7 +93,7 @@
|
|||||||
['label' => 'Доступы', 'icon' => 'key', 'url' => ['/accesses/accesses'], 'active' => \Yii::$app->controller->id == 'accesses', 'visible' => Yii::$app->user->can('confidential_information')],
|
['label' => 'Доступы', 'icon' => 'key', 'url' => ['/accesses/accesses'], 'active' => \Yii::$app->controller->id == 'accesses', 'visible' => Yii::$app->user->can('confidential_information')],
|
||||||
['label' => 'Заметки', 'icon' => 'sticky-note', 'url' => ['/notes/notes'], 'active' => \Yii::$app->controller->id == 'notes', 'visible' => Yii::$app->user->can('confidential_information')],
|
['label' => 'Заметки', 'icon' => 'sticky-note', 'url' => ['/notes/notes'], 'active' => \Yii::$app->controller->id == 'notes', 'visible' => Yii::$app->user->can('confidential_information')],
|
||||||
['label' => 'Календарь ДР', 'icon' => 'calendar-check-o', 'url' => ['/calendar/calendar'], 'active' => \Yii::$app->controller->id == 'calendar', 'visible' => Yii::$app->user->can('confidential_information')],
|
['label' => 'Календарь ДР', 'icon' => 'calendar-check-o', 'url' => ['/calendar/calendar'], 'active' => \Yii::$app->controller->id == 'calendar', 'visible' => Yii::$app->user->can('confidential_information')],
|
||||||
['label' => 'Отчеты', 'icon' => 'calendar', 'url' => ['/reports/reports'], 'active' => \Yii::$app->controller->id == 'reports', 'visible' => Yii::$app->user->can('confidential_information')],
|
['label' => 'Отчеты', 'icon' => 'calendar', 'url' => ['/reports/reports'], 'active' => \Yii::$app->controller->id == 'reports', ], // 'visible' => Yii::$app->user->can('confidential_information')
|
||||||
['label' => 'Опции', 'icon' => 'list-alt', 'url' => ['/options/options'], 'active' => \Yii::$app->controller->id == 'options', 'visible' => Yii::$app->user->can('confidential_information')],
|
['label' => 'Опции', 'icon' => 'list-alt', 'url' => ['/options/options'], 'active' => \Yii::$app->controller->id == 'options', 'visible' => Yii::$app->user->can('confidential_information')],
|
||||||
[
|
[
|
||||||
'label' => 'Запрос интервью (' . \common\models\InterviewRequest::getNewCount() . ')',
|
'label' => 'Запрос интервью (' . \common\models\InterviewRequest::getNewCount() . ')',
|
||||||
|
Loading…
Reference in New Issue
Block a user