Show or Hide Specific Sidebar Menu

Hi Everyone,

I have this line on my main.php for the purpose of only showing the menu for certain users, but it seems it is not working.

‘visible’ => ‘auth_assignment.user_id’ == \Yii::$app->user->identity->id && ‘auth_assignment.user_id’ == ‘auth_item.name’ && ‘auth_item.decsription’ ==“EXTERNAL”

Any way to do it?

Thanks in advance.

Do you compare auth_assignment.user_id string with user identity? How’s that supposed to function?