Skip to main content

%ZEN.Auxiliary.condition

Class %ZEN.Auxiliary.condition Extends %ZEN.Component.object [ Deprecated, System = 3 ]

Defines a style-condition for a %ZEN.Component.tablePane.
A %ZEN.Component.tablePane may define one or more conditions. Each condition is evaluated when the table is displayed and provides a way to change the style of rows or cells within the table based on the data values within a given row.
Each condition consists of:

  • colName - The name of the column in the table that provides the value to test.
  • value - The value to test against (a literal or a reference to another column value)
  • predicate - The comparison operator to use for the test.
  • cellStyle - The CSS style to apply to the target cell if the condition is true.
  • rowStyle - The CSS style to apply to the current row if the condition is true.

Properties

colName

Property colName As %ZEN.Datatype.string(ZENEXPRESSION = 1);

Name of a column within the table that this condition applies to.

value

Property value As %ZEN.Datatype.string(ZENEXPRESSION = 1);

Literal value that is compared against column value
Note: if the value of value is enclosed in {}, then it refers to a column of that name within the table. For example, "{PatientName}", will resolve to the value of the PatientName column within the table.

predicate

Property predicate As %ZEN.Datatype.string(VALUELIST = ",GT,EQ,LT,NEQ,GTEQ,LTEQ,EXTEQ,STARTSWITH,CONTAINS") [ InitialExpression = "EQ" ];

The comparison operator used to compare the value of the colName column with value.
This is one of the following:

  • GT - Greater than
  • EQ - Equal to
  • LT - Less than
  • NEQ - Not equal to
  • GTEQ - Greater than or equal to
  • LTEQ - Less than or equal to
  • EXTEQ - File extension (text after last ".") equal to
  • CONTAINS - Contains
  • STARTSWITH - Starts with

targetCol

Property targetCol As %ZEN.Datatype.string;

Optional. The name of the column to apply CellStyle to. If this is not provided, then the column specified by colName is used as the target.

cellStyle

Property cellStyle As %ZEN.Datatype.style;

Style to apply to cell if condition is true.
This is a CSS style string: e.g., "color: red;"

rowStyle

Property rowStyle As %ZEN.Datatype.style;

Style to apply to row if condition is true.
This is a CSS style string: e.g., "color: red;"

Methods

Eval

Method Eval(ByRef pValues As %String) As %Boolean [ Internal ]

Internal Method.
Evaluate this condition using the values in the provided row arrays.