Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
2791 มุมมอง

Guys, need help, in header i would like to add attribute 'clickable' but only if admin.

Is it possible to add 'clickable'?

...  attrs="{'clickable':[('user_id','=','Administrator')]}" ...

or how should it look like ?

อวตาร
ละทิ้ง

The admin user is always user_id 0 so set it as attrs="{'clickable':[('user_id','=','0')]}" ...

What I also think that could work: ('user_id.login','=','youruserlogin')

ผู้เขียน

Thank you Yanthe, i'll try tomorrow ;)

ผู้เขียน

Unfortunately "user_id" is not in domain :(