%DeepSee.Dashboard.Control
Class %DeepSee.Dashboard.Control Extends (%SerialObject, %XML.Adaptor) [ System = 4 ]
This class defines a control within a user-defined DeepSee dashboard widget. Controls are used to vary the values of data source parameters (such as changing the time period to display).
Parameters
NAMESPACE
Parameter NAMESPACE = "http://www.intersystems.com/deepsee/library";
XMLNAME
Parameter XMLNAME = "control";
XMLIGNORENULL
Parameter XMLIGNORENULL = 1;
Properties
name
Property name As %String(MAXLEN = 255, XMLPROJECTION = "attribute");
Identifying name for this control. This is used to logically identify the control.
controlKey
Property controlKey As %String(MAXLEN = 255, XMLPROJECTION = "none") [ InitialExpression = {$R(1000000000)}, Internal ];
Internal key used to track this control instance.
action
Property action As %String(MAXLEN = 250, XMLPROJECTION = "attribute") [ InitialExpression = "applyFilter" ];
What action to take when this control is activated.
target
Property target As %String(MAXLEN = "", XMLPROJECTION = "attribute");
Comma-delimited list of names of widgets to apply action to. If "*", then send event to all widgets.
targetProperty
Property targetProperty As %String(MAXLEN = "", XMLPROJECTION = "attribute");
Name of property within widget to apply the action to. Typically this is the name of the filter being modified.
location
Property location As %String(MAXLEN = 50, VALUELIST = ",widget,dashboard,click", XMLPROJECTION = "attribute") [ InitialExpression = "widget" ];
Specifies where to place the control. If "click" then this defines what happens when a user clicks on an item within the widget.
type
Property type As %String(MAXLEN = 255, VALUELIST = ",auto,dropdown,searchBox,button,hidden,radioSet,timer,custom", XMLPROJECTION = "attribute");
General type of control to use.
If "custom", then the control specified by controlClass is used.
controlClass
Property controlClass As %String(MAXLEN = 255, XMLPROJECTION = "attribute");
Class name of component to user for this control when type is "custom". This is the name of a Zen control.
If the name does not include package, then "%ZEN.Component" is used.
If no name is provided, a default control is used.
timeout
Property timeout As %Integer(XMLPROJECTION = "attribute");
Timeout value (seconds) when type is "timer".
label
Property label As %String(MAXLEN = 255, XMLPROJECTION = "attribute");
Label to display for the control.
title
Property title As %String(MAXLEN = "", XMLPROJECTION = "attribute");
Title (tooltip) to display for the control.
value
Property value As %String(MAXLEN = "", XMLPROJECTION = "attribute");
Default value for the control. If this starts with "@" then it is the name of a user defined-setting.
valueRequired
Property valueRequired As %Boolean [ InitialExpression = 0 ];
If set to true, the control must be assigned a value.
text
Property text As %String(MAXLEN = "", XMLPROJECTION = "attribute");
Default text value for the control.
size
Property size As %Integer(MINVAL = 0, XMLPROJECTION = "attribute");
Size to apply to the control (if the control accepts a size).
readOnly
Property readOnly As %Boolean(XMLPROJECTION = "attribute") [ InitialExpression = 0 ];
Indicate that this control is read only.
valueList
Property valueList As %String(MAXLEN = "", XMLPROJECTION = "attribute");
Comma-delimited list of permitted values for the control. If supplied this overrides a default list.
displayList
Property displayList As %String(MAXLEN = 255, XMLPROJECTION = "attribute");
Comma-delimited list of display values for the filter. If supplied this overrides a default list.
activeWhen
Property activeWhen As %String(MAXLEN = 255, XMLPROJECTION = "attribute");
Specifies when this control is enabled.
actionDisplay
Property actionDisplay As %String(MAXLEN = 250, XMLPROJECTION = "none") [ Transient ];
Transient display name for action.
typeDisplay
Property typeDisplay As %String(MAXLEN = 250, XMLPROJECTION = "none") [ Transient ];
Transient display name for type.
locationDisplay
Property locationDisplay As %String(MAXLEN = 250, XMLPROJECTION = "none") [ Transient ];
Transient display name for location.
targetPropertyDisplay
Property targetPropertyDisplay As %String(MAXLEN = 250, XMLPROJECTION = "none");
Display name for targetProperty. (This value is saved so that we don't have to recompute it later; the value is only used for display purposes).
activeWhenDisplay
Property activeWhenDisplay As %String(MAXLEN = 250, XMLPROJECTION = "none") [ Transient ];
Transient display name for activeWhen.
Methods
%CopyTo
Method %CopyTo(ByRef pTarget) As %Status
Copy contents of this control to pTarget.
%CopyToDao
Method %CopyToDao(ByRef pTarget As %DynamicObject = {$$$NULLOREF}) As %Status
Copy contents to a dynamic object
%CopyToDef
Method %CopyToDef(ByRef pTarget As %DeepSee.Dashboard.Control) As %Status
Copy contents to a structured Control definition
%OnOpen
Method %OnOpen() As %Status [ Private, ServerOnly = 1 ]
%OnAddToSaveSet
Method %OnAddToSaveSet(depth As %Integer = 3, insert As %Integer = 0, callcount As %Integer = 0) As %Status [ Private, ServerOnly = 1 ]
This callback method is invoked when the current object is added to the SaveSet, either because %Save() was invoked on this object or on an object that references this object. %OnAddToSaveSet can modify the current object. It can also add other objects to the current SaveSet by invoking %AddToSaveSet or remove objects by calling %RemoveFromSaveSet.
If this method returns an error status then %Save() will fail and the transaction will be rolled back.