Forum Discussion
VarunGrazitti
9 years agoBoss
yurikleban - Sure, try this.
<#attempt> <#assign user_has_role = false /> <#if user.registered > <#list restadmin("/users/id/${user.id?c}/roles").roles.role as role> <#if role.name?? && (role.name == "Role1" || role.name == "Role2" || role.name == "Role3")> <#assign user_has_role = true /> </#if> </#list> </#if> <#if user_has_role > Content will go here </#if> <#recover> <!-- Something bad happened --> </#attempt>
I hope this helps.
Related Content
- 4 years ago
- 5 years ago