Hiding a content block by using a script in the Condition field will also hide any blocks placed below it.


Steps to Reproduce

  1. Create a new content_block_static record with the following information (also shown in the attachment):

    • Category: General
    • Conditional: Checked
    • Condition: gs.getSession().hasRole('admin');
  2. Add this this block to the ITIL Homepage so that it has content blocks above and below it.

  3. View the homepage while logged in as the System Administrator.

    Note that the block shows as expected.

  4. Impersonate an ITIL user that does not have the admin role.

  5. View the ITIL Homepage again.

    The content block is not visible and all elements below the block are also hidden.


This is expected behaviour. The condition field of a CMS content block is meant to work on CMS pages, not Home pages. While some CMS widgets may run on Home pages be aware they were not developed for Home pages but for CMS pages.

Content Blocks were designed for Content Pages (CMS), not for Home Pages. Although they might work on home pages, it is recommended not to use them on Home Pages, as this is not supported.

Since Helsinki, Responsive Dashboards can be used. Like Home Pages, these do not support some Content Blocks features, and we do not plan on supporting them, as Dashboards are not CMS Content Pages.

It is not recommended to rely on the content block condition field, because it will make difficult migrating to Dashboards, which rely on proper ACLs to grant access to content instead of condition expressions.

Related Problem: PRB648998

Seen In

Fuji Patch 5
Geneva Patch 1
Geneva Patch 8

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2020-09-22 14:44:29