跳到主要内容

Show text on the portal only to a certain usergroup - 知识库 / Developer & Reporting / Portal Customization - Deskpro Support

Show text on the portal only to a certain usergroup

作者列表

Question:

How do I edit a portal template to show some text only to users who belong to a particular usergroup?

 

Answer:

First, look up the ID number of the usergroup in Admin > CRM > Usergroups with the small gear icon at the top right of the usergroup list.

 

Now add this to the portal template where you want the message to appear:

 

{% if app.user.isMemberOfUsergroup(N) %}

Text to display

{% endif %}

 

replacing N with the ID of the usergroup, and putting the message you want in place of "Text to display".

 

See the admin manual for full details about editing Deskpro templates.

有帮助 没有帮助

71 人中 32 人认为这个页面有帮助

添加一条评论

请登录或注册以提交评论。

是否需要密码提醒?