play freamwork 页面的Html+Groovy模板中的if判断

#{if session.get("user_permission").contains("UserManager")}
                    <a href="@{edit(user.id,page)}">&{'edit'}</a>
                    <a href="@{delete(page,user.id)}" onclick="javaxcript:return confirm(&quot;&{'sure_you_want_to_delete'}?&quot;)">&{'delete'}</a>
                    <a href="@{resetPassword(page,user.id)}" onclick="javaxcript:return confirm(&quot;&{'sure_you_want_to_reset_password'}?&quot;)">&{'password_reset'}</a>

#{/if}

原文地址:https://www.cnblogs.com/xunfang123/p/4196225.html