Class ecm.widget.SinglePropertyEditorFactory

Provides a factory that creates a SinglePropertyEditor instance.
Defined in: <ecm\widget\SinglePropertyEditorFactory.js>.

Constructor Summary

Constructor Attributes Constructor Name and Description
 

Method Summary

Method Attributes Method Name and Description
 
createSinglePropertyEditor(kwArgs, callback)
Creates a single property editor.
 
 
Returns the decimal point for the language in use.
 
getFieldIsReadOnly(attributeDefinition, item, reason, isReadOnly)
Returns a boolean flag indicating whether the attribute is read only.
 
getMinMax(minValue, maxValue, dataType, format, minValueTimeZoneOffset, maxValueTimeZoneOffset)
Returns the minimum and maximum values in an object.
 
 
getPromptText(kwArgs)
Returns the prompt text.
 
getRegularExpression(dataType, format, repositoryType, forSearch, reason)
Returns the regular expression for the dataType.

Constructor Detail

ecm.widget.SinglePropertyEditorFactory()

Method Detail

createSinglePropertyEditor(kwArgs, callback)

Creates a single property editor.
Parameters:
kwArgs
The attributes for the editor.
  • dataType -- data type of this control, for example, xs:date
  • dataFormat -- format of this control, for example, yyyy-mm-dd (used for date, time, timestamp, and decimal)
  • minLength -- controls the length attribute value (used for strings, for example, TextEditor)
  • maxLength -- controls the length attribute value (used for strings, for example, TextEditor)
  • minValue --
  • maxValue --
  • readOnly -- true or false - readonly attribute
  • values -- value to display in the editor
  • name -- name
  • width -- widget width
  • label -- label
  • id -- id of the field
  • cardinality -- LIST == multi value editor, SINGLE == single choice/value editor
  • uniqueValues -- true or false - used by the multi-value editor to specify if the user can select only unique values
  • choiceListNested -- used by the single choice and multi value editor - true = show choice list in a tree
  • choiceList -- used by the single choice and multi-value editor - for single editor, use either choiceList or valueOptions to specify the options (label = displayName)
  • valueOptions -- used by single choice editor - used only if choiceList isn't specified (label == label)
  • invalidMessage -- used by _createTextEditor
  • votingParameter -- used by UserGroupSelectorPane
  • votingNumber -- used by UserGroupSelectorPane
  • repository -- used by UserGroupSelectorPane. Also provides the repository.type value for the ValidationTextBox repositoryType when repositoryType is not present in kwArgs.
  • repositoryType -- used by stand-alone or contained (text editor) ValidationTextBox widgets to determine how attribute string length limits should be measured. If repositoryType is not provided in kwArgs and repository is, the repository.type value is passed for ValidationTextBox repositoryType. If ValidationTextBox repositoryType is not set then no repository specific handling is applied, the string character length is always used to check against attribute length limits.
  • regularExpr -- optional - can override the default regularExpr
callback
Callback function required when using custom property editors.
Returns:
The property editor.

getAlphas()


getDecimalPoint()

Returns the decimal point for the language in use.

getFieldIsReadOnly(attributeDefinition, item, reason, isReadOnly)

Returns a boolean flag indicating whether the attribute is read only.
Parameters:
attributeDefinition
A ecm.model.AttributeDefinition object. Provides the definition for the attributes in the item parameter.
item
A ecm.model.ContentItem object (maybe null on create).
reason
The reason for displaying properties. Pass "create" when creating a new content item, "checkin" when checking in a content item, "editProperties" when editing the properties of a content item, or "multiEditProperties" when editing the properties of multiple content items.
isReadOnly
Pass true if the entire item is read only.
Since:
2.0.3

getMinMax(minValue, maxValue, dataType, format, minValueTimeZoneOffset, maxValueTimeZoneOffset)

Returns the minimum and maximum values in an object.
Parameters:
minValue
The minimum value.
maxValue
The maximum value.
dataType
The data type.
format
The format.
minValueTimeZoneOffset
maxValueTimeZoneOffset
Returns:
An object that contains these fields:
  • min: The minimum value.
  • minString: The minimum value display string.
  • max: The maximum value.
  • maxString: The maximum value display string.

getNumerics()


getPromptText(kwArgs)

Returns the prompt text.
Parameters:
kwArgs
The object of attributes.
  • promptText -- text from attribute definition, if set, will override dynamically created prompt
  • dataType -- data type of this control, for example, xs:date
  • dataFormat -- format of this control, for example, yyyy-mm-dd
  • maxLength -- input controls length attribute value
  • minMaxValues--
  • cardinality
  • choiceList --- IBM FileNet P8 choice list might be a data store in the future
  • valueOptions--
  • Returns:
    String representing the prompt text.

    getRegularExpression(dataType, format, repositoryType, forSearch, reason)

    Returns the regular expression for the dataType.
    Parameters:
    dataType
    The data type.
    format
    The format.
    repositoryType
    forSearch
    reason