user_id === null) { throw new InvalidConfigException('"user_id" must be set.'); } $this->items = array_keys($this->getAuthManager()->getItemsByUser($this->user_id)); } /** * @inheritdoc */ public function attributeLabels() { return [ 'items' => Yii::t('user', 'Items') ]; } /** * @inheritdoc */ public function rules() { return [ ['user_id', 'required'], ['items', RbacItemsValidator::class], ['user_id', 'integer'] ]; } }