Annotation Interface AdminPresentation


@Retention(RUNTIME) @Target(FIELD) public @interface AdminPresentation
Author:
jfischer
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Optional - only required if you want to display a friendly name to the user
    boolean
    Optional - only required if you want to allow an enum field to have "No Value Selected" as an option.
    Optional - identifies another field on this entity which is associated with this one.
    Optional - only required for BROADLEAF_ENUMERATION field types
    boolean
    Optional - only required if you want to explicity override whether a linkable field (e.g., SupportedFieldType.ADDITIONAL_FOREIGN_KEY) should link to an external entity from a LisGrid (i.e., be a clickable link).
    Optional - only required if you want to explicitly control column width for this field in a grid in the admin tool
    Optional - If you have FieldType set to SupportedFieldType.MONEY, then you can specify a money currency property field.
    Optional - only required if you want to display a default value to the user when adding a new entity
    Optional - only required if you want to explicitly specify the field type.
    boolean
    Optional - only required if you want to explicitly exclude this field from dynamic management by the admin tool
    Optional - drives the component that renders the UI for an entityform
    Optional - drives the component that renders the UI for an entityform
    Optional - only required if you want to explicitly specify the field type.
    Optional - only required if you want to display a friendly name to the user
    Optional - drives the component that renders the UI for a listgrid
    Optional - drives the component that renders the UI for a listgrid
    int
    Optional - required only if you want to order the appearance of this field as it relates to other fields in a grid.
    Used to map the field to a group defined in AdminPresentationClass using AdminGroupPresentation.
    boolean
    Deprecated.
    not supported
    int
    Optional - only required if you want to order the appearance of groups in the UI
    Optional - only required if you want to provide help text for this field
    boolean
    Optional - only required if you want to hide this field when there are no enumeration options provided
    Optional - only required if you want to provide a hint for this field
    boolean
    Optional - only required if you want to give the user extra room to enter a value for this field in the UI
    int
    Optional - only required if you want to order the appearance of this field in the UI
    boolean
    Optional - only required if you want this field to appear as one of the default columns in a grid in the admin tool
    boolean
    Optional - only required if you want to make the field immutable
    Optional - only required if you want to explicitly make a field required.
    Optional - only required if the fieldType is SupportedFieldType.RULE_SIMPLE or SupportedFieldType.RULE_COMPLEX
    Deprecated.
    not supported
    Optional - only required if you want hide the field based on the supplied field's value
    Optional - propertyName , only required if you want hide the field based on this property's value
    Optional - only required if you want the field to appear under a different tab
    int
    Optional - only required if you want to order the appearance of the tabs in the UI
    Optional - only required if you want to provide a tooltip for the field
    boolean
    Optional - marks this field as being translatable, which will render the translations modal in the admin UI
    Optional - only required if you want to provide validation for this field
    Optional - only required if you want to restrict the visibility of this field in the admin tool
  • Element Details

    • friendlyName

      String friendlyName

      Optional - only required if you want to display a friendly name to the user

      <The friendly name to present to a user for this field in a GUI. If supporting i18N, the friendly name may be a key to retrieve a localized friendly name using the GWT support for i18N.

      Returns:
      the friendly name
      Default:
      ""
    • addFriendlyName

      String addFriendlyName

      Optional - only required if you want to display a friendly name to the user

      <The add friendly name to present to a user for this field in the add GUI. If supporting i18N, the friendly name may be a key to retrieve a localized friendly name using the GWT support for i18N.

      Returns:
      the friendly name
      Default:
      ""
    • securityLevel

      String securityLevel
      Deprecated.
      not supported
      Optional - only required if you want to restrict this field

      If a security level is specified, it is registered with org.broadleafcommerce.openadmin.client.security.SecurityManager The SecurityManager checks the permission of the current user to determine if this field should be disabled based on the specified level.

      Returns:
      the security level
      Default:
      ""
    • order

      int order
      Optional - only required if you want to order the appearance of this field in the UI

      The order in which this field will appear in a GUI relative to other fields from the same class

      Returns:
      the display order
      Default:
      99999
    • gridOrder

      int gridOrder
      Optional - required only if you want to order the appearance of this field as it relates to other fields in a grid. Note that this field will only be relevant if prominent() is also set to true.
      Returns:
      Default:
      9999
    • visibility

      VisibilityEnum visibility
      Optional - only required if you want to restrict the visibility of this field in the admin tool

      Describes how the field is shown in admin GUI.

      Returns:
      whether or not to hide the form field.
      Default:
      VISIBLE_ALL
    • fieldType

      Optional - only required if you want to explicitly specify the field type. This value is normally inferred by the system based on the field type in the entity class.

      Explicity specify the type the GUI should consider this field Specifying UNKNOWN will cause the system to make its best guess

      Returns:
      the field type
      Default:
      UNKNOWN
    • displayType

      Optional - only required if you want to explicitly specify the field type. This value is normally inferred by the system based on the field type in the entity class.

      Explicity specify the type the GUI should consider this field Specifying UNKNOWN will cause the system to make its best guess

      Returns:
      the field type
      Default:
      NORMAL
    • canLinkToExternalEntity

      boolean canLinkToExternalEntity
      Optional - only required if you want to explicity override whether a linkable field (e.g., SupportedFieldType.ADDITIONAL_FOREIGN_KEY) should link to an external entity from a LisGrid (i.e., be a clickable link).

      This is only relevant on linkable fields and will otherwise be ignored.

      Returns:
      whether this field is allowed to link to an external entity from a ListGrid
      Default:
      true
    • group

      String group
      Used to map the field to a group defined in AdminPresentationClass using AdminGroupPresentation. If the group cannot be found in AdminPresentationClass, the group (and the tab, if not present) will be created using the field-level AdminPresentation data.

      Optional - only required if you want to specify a grouping for this field

      Specify a GUI grouping for this field Fields in the same group will be visually grouped together in the GUI

      Note: for support I18N, this can also be a key to retrieve a localized String

      Returns:
      the group for this field
      Default:
      "General"
    • groupOrder

      int groupOrder
      Optional - only required if you want to order the appearance of groups in the UI

      Specify an order for this group. Groups will be sorted in the resulting form in ascending order based on this parameter.

      Returns:
      the order for this group
      Default:
      99999
    • groupCollapsed

      boolean groupCollapsed
      Deprecated.
      not supported
      Optional - only required if you want to control the initial collapsed state of the group

      Specify whether a group is collapsed by default in the admin UI.

      Returns:
      whether or not the group is collapsed by default
      Default:
      false
    • tab

      String tab
      Optional - only required if you want the field to appear under a different tab

      Specify a GUI tab for this field

      Returns:
      the tab for this field
      Default:
      "General"
    • tabOrder

      int tabOrder
      Optional - only required if you want to order the appearance of the tabs in the UI

      Specify an order for this tab. Tabs will be sorted int he resulting form in ascending order based on this parameter.

      The default tab will render with an order of 99999.

      Returns:
      the order for this tab
      Default:
      99999
    • largeEntry

      boolean largeEntry
      Optional - only required if you want to give the user extra room to enter a value for this field in the UI

      If the field is a string, specify that the GUI provide a text area

      Returns:
      is a text area field
      Default:
      false
    • prominent

      boolean prominent
      Optional - only required if you want this field to appear as one of the default columns in a grid in the admin tool

      Provide a hint to the GUI about the prominence of this field. For example, prominent fields will show up as a column in any list grid in the admin that displays this entity.

      Returns:
      whether or not this is a prominent field
      Default:
      false
    • columnWidth

      String columnWidth
      Optional - only required if you want to explicitly control column width for this field in a grid in the admin tool

      Specify the column space this field will occupy in grid widgets. This value can be an absolute integer or a percentage. A value of "*" will make this field use up equally distributed space.

      Returns:
      the space utilized in grids for this field
      Default:
      "*"
    • broadleafEnumeration

      String broadleafEnumeration
      Optional - only required for BROADLEAF_ENUMERATION field types

      For fields with a SupportedFieldType of BROADLEAF_ENUMERATION, you must specify the fully qualified class name of the Broadleaf Enumeration here.

      Returns:
      Broadleaf enumeration class name
      Default:
      ""
    • hideEnumerationIfEmpty

      boolean hideEnumerationIfEmpty

      Optional - only required if you want to hide this field when there are no enumeration options provided

      Whether or not to show the field if no Enumeration options are provided.

      Returns:
      whether or not to show the field if empty
      Default:
      false
    • allowNoValueEnumOption

      boolean allowNoValueEnumOption
      Optional - only required if you want to allow an enum field to have "No Value Selected" as an option. This field is ignored for required fields. For optional fields (DB allows nulls), this property is best set along with a default value.
      Returns:
      where or not the enum value "No Value Selected" should be shown.
      Default:
      false
    • fieldComponentRenderer

      SupportedFieldType fieldComponentRenderer
      Optional - drives the component that renders the UI for an entityform

      When not specified, will default to the fieldType

      Returns:
      the component name responsible for rendering this field
      Default:
      UNKNOWN
    • fieldComponentRendererTemplate

      String fieldComponentRendererTemplate
      Optional - drives the component that renders the UI for an entityform

      When not specified, will default to the fieldType

      Returns:
      the component name responsible for rendering this field
      Default:
      ""
    • gridFieldComponentRenderer

      SupportedFieldType gridFieldComponentRenderer
      Optional - drives the component that renders the UI for a listgrid

      When not specified, will default to the fieldType

      Returns:
      the component name responsible for rendering this field
      Default:
      UNKNOWN
    • gridFieldComponentRendererTemplate

      String gridFieldComponentRendererTemplate
      Optional - drives the component that renders the UI for a listgrid

      When not specified, will default to the fieldType

      Returns:
      the component name responsible for rendering this field
      Default:
      ""
    • readOnly

      boolean readOnly
      Optional - only required if you want to make the field immutable

      Explicitly specify whether or not this field is mutable.

      Returns:
      whether or not this field is read only
      Default:
      false
    • validationConfigurations

      ValidationConfiguration[] validationConfigurations
      Optional - only required if you want to provide validation for this field

      Specify the validation to use for this field in the admin, if any

      Returns:
      the configuration for the validation
      Default:
      {}
    • requiredOverride

      RequiredOverride requiredOverride
      Optional - only required if you want to explicitly make a field required. This setting is normally inferred by the JPA annotations on the field.

      Specify whether you would like the admin to require this field, even if it is not required by the ORM.

      Returns:
      the required override enumeration
      Default:
      IGNORED
    • excluded

      boolean excluded
      Optional - only required if you want to explicitly exclude this field from dynamic management by the admin tool

      Specify if this field should be excluded from inclusion in the admin presentation layer

      Returns:
      whether or not the field should be excluded
      Default:
      false
    • tooltip

      String tooltip
      Optional - only required if you want to provide a tooltip for the field

      Helpful tooltip to be displayed when the admin user hovers over the field. This can be localized by providing a key which will use the GWT support for i18N.

      Default:
      ""
    • helpText

      String helpText
      Optional - only required if you want to provide help text for this field

      On the form for this entity, this will show a question mark icon next to the field. When the user clicks on the icon, whatever HTML that is specified in this helpText is shown in a popup.

      For i18n support, this can also be a key to a localized version of the text

      Reference implementation: http://www.smartclient.com/smartgwt/showcase/#form_details_hints

      Default:
      ""
    • hint

      String hint
      Optional - only required if you want to provide a hint for this field

      Text to display immediately to the right of a form field. For instance, if the user needs to put in a date, the hint could be the format the date needs to be in like 'MM/YYYY'.

      For i18n support, this can also be a key to a localized version of the text

      Reference implementation: http://www.smartclient.com/smartgwt/showcase/#form_details_hints

      Default:
      ""
    • showIfProperty

      String showIfProperty

      Optional - propertyName , only required if you want hide the field based on this property's value

      If the property is defined and found to be set to false, in the AppConfiguraionService, then this field will be excluded in the admin presentation layer

      Returns:
      name of the property
      Default:
      ""
    • showIfFieldEquals

      FieldValueConfiguration[] showIfFieldEquals

      Optional - only required if you want hide the field based on the supplied field's value

      If the property is defined and found to be equal to one of the values provided then this field will be excluded in the admin presentation layer

      Returns:
      configuration of the field values
      Default:
      {}
    • currencyCodeField

      String currencyCodeField
      Optional - If you have FieldType set to SupportedFieldType.MONEY, then you can specify a money currency property field.
      Returns:
      the currency property field
      Default:
      ""
    • ruleIdentifier

      String ruleIdentifier

      Optional - only required if the fieldType is SupportedFieldType.RULE_SIMPLE or SupportedFieldType.RULE_COMPLEX

      Identifies the type for which this rule builder is targeted. See RuleIdentifier for a list of identifier types supported out-of-the-box. Note - one of the main uses of this value is to help identify the proper RuleBuilderService instance to generate the correct field value options for this rule builder.

      Returns:
      The identifier value that denotes what type of rule builder this is - especially influences the fields that are available in the UI
      Default:
      ""
    • translatable

      boolean translatable

      Optional - marks this field as being translatable, which will render the translations modal in the admin UI

      Returns:
      whether or not this field is translatable
      Default:
      false
    • defaultValue

      String defaultValue

      Optional - only required if you want to display a default value to the user when adding a new entity

      The default value to present to a user for this field when adding a new entity.

      Default values on Boolean require "true" or "false".

      Default values on Date support the string "today" and strings with the format of yyyy.MM.dd HH:mm:ss (e.g. "2020.02.05 22:11:05").

      Returns:
      the defaultValue set for the field.
      Default:
      ""
    • associatedFieldName

      String associatedFieldName

      Optional - identifies another field on this entity which is associated with this one.

      The associated field will be rendered next to this field in the admin interface.

      Returns:
      the associatedFieldName set for the field.
      Default:
      ""