Module: alfresco/renderers/Boolean

alfresco/renderers/Boolean

Extends the Property renderer (module:alfresco/renderers/Property) to provide an interpreted boolean display with i18n and image functionality.
Author:
  • Richard Smith
License:
Source:

Example

Sample configuration within table cells

widgets: [
   {
      name: "alfresco/lists/views/layouts/Cell",
      config: {
         widgets: [
            {
               name: "alfresco/renderers/Boolean",
               config: {
                  propertyToRender: "myProperty"
                  // Default YESNO style
               }
            }
         ]
      }
   },
   {
      name: "alfresco/lists/views/layouts/Cell",
      config: {
         widgets: [
            {
               name: "alfresco/renderers/Boolean",
               config: {
                  propertyToRender: "myProperty",
                  displayType: "TRUEFALSE" // TRUEFALSE style
               }
            }
         ]
      }
   },
   {
      name: "alfresco/lists/views/layouts/Cell",
      config: {
         widgets: [
            {
               name: "alfresco/renderers/Boolean",
               config: {
                  propertyToRender: "myProperty",
                  displayType: "IMAGE" // IMAGE style
               }
            }
         ]
      }
   }
]

Extends

  • alfresco/renderers/Property

Members

cssRequirements :object[]

An array of the CSS files to use with this widget.
Type:
  • object[]
Default Value:
  • [{cssFile:"./css/Boolean.css"}]
Source:

displayType :String

The display type to be used.
Type:
  • String
Default Value:
  • "YESNO"
Source:

i18nRequirements :object[]

An array of the i18n files to use with this widget.
Type:
  • object[]
Default Value:
  • [{i18nFile: "./i18n/Boolean.properties"}]
Source:

<private, inner> displayTypeOptions :Enum

An enum of displayType options.
Type:
  • Enum
Source:

Methods

postMixInProperties()

Set up the attributes to be used when rendering the template.
Source: