Documentation

Single Condition

Conditions can be added to modules to display them only when all the given conditions are true.

Single Conditions can take optional parameters. These parameters will be passed in to the condition's init() method as a map of string key/value pairs before any condition checks are performed.

To invert a condition, add the attribute invert="true" to the condition element. This is useful where you want to show the section if a certain condition is not satisfied.

Single Conditions must contain a condition attribute with the name of the condition to check.

The valid condition names are as follows:

JIRA

  • browse_users_permission
  • linking_enabled
  • user_is_the_logged_in_user
  • external_user_management_disabled
  • has_last_search_request
  • is_issue_reported_by_current_user
  • not_version_context
  • is_issue_unresolved
  • user_has_issue_history
  • voting_enabled
  • time_tracking_enabled
  • has_link_types_available
  • is_field_hidden
  • has_issue_permission
  • watching_enabled
  • has_selected_project
  • can_create_shared_objects
  • can_manage_attachments
  • is_watching_issue
  • can_convert_to_issue
  • is_sub_task
  • is_issue_assigned_to_current_user
  • can_attach_file_to_issue
  • has_project_permission
  • user_is_project_admin
  • can_attach_screenshot_to_issue
  • can_convert_to_sub_task
  • has_voted_for_issue
  • is_issue_editable
  • is_admin_mode
  • sub_tasks_enabled
  • user_is_admin
  • user_is_logged_in
  • has_sub_tasks_available
  • is_keyboard_shortcuts_enabled
  • user_is_sysadmin
  • smtp_mail_server_configured

CONFLUENCE

  • space_function_permission
  • user_can_update_user_status
  • printable_version
  • user_watching_space_for_content_type
  • user_can_create_personal_space
  • user_has_personal_space
  • target_user_can_set_status
  • threaded_comments
  • favourite_space
  • writable_directory_exists
  • not_personal_space
  • favourite_page
  • has_blog_post
  • can_signup
  • content_has_any_permissions_set
  • user_can_use_confluence
  • user_watching_space
  • showing_page_attachments
  • can_edit_space_styles
  • target_user_has_personal_space
  • user_has_personal_blog
  • user_logged_in_editable
  • tiny_url_supported
  • user_watching_page
  • latest_version
  • has_space
  • has_page
  • viewing_content
  • viewing_own_profile
  • user_favouriting_target_user_personal_space
  • create_content
  • active_theme
  • target_user_has_personal_blog
  • following_target_user
  • has_attachment
  • has_template
  • user_is_logged_in
  • space_sidebar
  • email_address_public
  • user_is_confluence_administrator
  • user_is_sysadmin
  • can_cluster

Example

{
  "condition": {
    "condition": "user_is_logged_in",
    "invert": false
  }
}

Properties

condition

Type
string
Required
Yes

invert

Type
boolean
Defaults to
false

params

Type
object
Description

This object represents a map of key/value pairs, where each property name and value corresponds to the parameter name and value respectively.

Example

{
  "params": {
    "someOtherProperty": "someValue",
    "myCustomProperty": "myValue"
  }
}