Handler - ValueChangeMonitor
ValueChangeMonitor handler monitors value changes of a target attribute. It stores data about the value, when it has been changed, who has made the change, and for how long the value has been same. The values are hidden, but when a user clicks the Show link in the data card view, the values become visible.
Time spent in a certain value can be stored in a particular attribute. If a data type of the particular attribute is number, the value will be in minutes. If a data type of the of particular attribute is string, the value will be in form: dd:hh:mm. This functionality can be achieved by defining state_ metadata.
For example, let's assume that Monitored attribute has values "1. Untouched", "2. Opened" and "3. Closed" and target attributes have codes spentTimeUntouched, spentTimeOpened. Metadata for this ValueChange attribute will be state_1. Untouched = spentTimeUntouched and state_2. Opened = timeSpentOpened.
Normally the time spent in the last line is left blank. If you want time calculated to last line according to current time or value of a date and time attribute, you can define metadata Fill last.
The handler creates data cards from predefined template and links them to its own attribute. New value of the monitored attribute is saved in created data card. This handler needs multivalue reference field referencing to the predefined template. The predefined template must have code ValueChange and it must have a String attribute with code value and Date and Time attribute (with code creationTime) which has CreationStamp as handler and this field must be the primary attribute of the template. Example template is attached at the end of this document.
If Business Hours attribute, SLA attribute or default SLA configurations are used, the times can be calculated as business hours. Check more information on Handler - BusinessHoursFinder and Handler - SLAFinder .
Table 1. Attribute Settings
| Handler name | Datatype |
|---|---|
ValueChangeMonitor |
Reference |
Table 2. Required Attribute Metadata
| Name | Value | Description |
|---|---|---|
Monitored attribute |
attribute code | Code of the attribute which will be monitored. |
Table 3. Optional Attribute Metadata
| Name | Value | Description |
|---|---|---|
Business Hours attribute |
attribute code |
Code of Business Hours attribute of this template. If Defining this metadata overrides all SLA metadata configurations. Check more information on Handler - BusinessHoursFinder |
SLA attribute |
attribute code |
Code of SLA attribute of this template. If Check more information on Handler - SLAFinder |
Default SLA data card |
[name of the default SLA data card] |
Name of the default SLA data card. Identifies the default SLA data card together with the Check more information on Handler - SLAFinder |
Default SLA template |
[template_code] |
Template code of the SLA template. Identifies the default SLA data card together with the Check more information on Handler - SLAFinder |
Fill last |
attribute code|attribute code [| currentTime] |
Defines if last line of the status changes contains a value. Since there is no natural end time, it can be defined to be taken from other date and time attribute of the template. If the wished end time is current time, value of the metadata is set to If intended functionality is that value for end time should be take from attribute A if it contains value or from current time if A is blank, the value will be If intended functionality is that value for end time should be take from attribute A if it contains value or from attribute B if A is blank, the value will be |
state_XXX |
attribute code |
If it is wanted to store the time spent in certain states of the target attribute, it can be defined with If the data type of attribute that the value refers is number, the stored value will be in minutes. If the data type of attribute that the value refers is string, the stored value will be in form of There can be multiple target attributes for any value. It is defined by multiple |
Example ValueChange Template
<?xml version="1.0" encoding="iso-8859-15"?>
<templateset>
<template>
<id>1568</id>
<code>ValueChange</code>
<name>ValueChanges</name>
<description>This template is used by ValueChangeMonitor handler. Do not modify manually.</description>
<system-code>system</system-code>
<protected>false</protected>
<reference-cascade>false</reference-cascade>
<class>
<id>1569</id>
<name>Value changes</name>
<order>0</order>
<attribute>
<id>1570</id>
<class-attribute-id>1572</class-attribute-id>
<code>value</code>
<name>Value</name>
<datatype>string</datatype>
<multivalue>false</multivalue>
<output-is-always-shown>false</output-is-always-shown>
<static>false</static>
<hierarchy>false</hierarchy>
<hierarchy-leafs-only>false</hierarchy-leafs-only>
<special>false</special>
<expand-references-automatically>false</expand-references-automatically>
<expand-complete-output-automatically>false</expand-complete-output-automatically>
<import-referenced-data-to-referrer>false</import-referenced-data-to-referrer>
<large-text>false</large-text>
<query-hidden>false</query-hidden>
<output-hidden>false</output-hidden>
<query-header-hidden>false</query-header-hidden>
<output-header-hidden>false</output-header-hidden>
<field-width>40</field-width>
<field-height>1</field-height>
<space-demand>4</space-demand>
<order>100</order>
<selected>false</selected>
<unique>false</unique>
<required>false</required>
<protected>false</protected>
</attribute>
<attribute>
<id>1573</id>
<class-attribute-id>1574</class-attribute-id>
<code>creationTime</code>
<name>Date</name>
<primary>true</primary>
<datatype>datetime</datatype>
<multivalue>false</multivalue>
<output-is-always-shown>false</output-is-always-shown>
<static>false</static>
<hierarchy>false</hierarchy>
<hierarchy-leafs-only>false</hierarchy-leafs-only>
<special>true</special>
<expand-references-automatically>false</expand-references-automatically>
<expand-complete-output-automatically>false</expand-complete-output-automatically>
<import-referenced-data-to-referrer>false</import-referenced-data-to-referrer>
<handler>com.bitmount.equipment.entitydatahandler.plugin.CreationStampHandler</handler>
<large-text>false</large-text>
<query-hidden>true</query-hidden>
<output-hidden>false</output-hidden>
<query-header-hidden>false</query-header-hidden>
<output-header-hidden>false</output-header-hidden>
<field-width>40</field-width>
<field-height>1</field-height>
<space-demand>4</space-demand>
<order>200</order>
<selected>false</selected>
<unique>false</unique>
<required>false</required>
<protected>false</protected>
</attribute>
<attribute>
<id>1575</id>
<class-attribute-id>1576</class-attribute-id>
<code>creator</code>
<name>User</name>
<datatype>string</datatype>
<multivalue>false</multivalue>
<output-is-always-shown>false</output-is-always-shown>
<static>false</static>
<hierarchy>false</hierarchy>
<hierarchy-leafs-only>false</hierarchy-leafs-only>
<special>true</special>
<expand-references-automatically>false</expand-references-automatically>
<expand-complete-output-automatically>false</expand-complete-output-automatically>
<import-referenced-data-to-referrer>false</import-referenced-data-to-referrer>
<handler>com.bitmount.equipment.entitydatahandler.plugin.CreatorStampHandler</handler>
<large-text>false</large-text>
<query-hidden>true</query-hidden>
<output-hidden>false</output-hidden>
<query-header-hidden>false</query-header-hidden>
<output-header-hidden>false</output-header-hidden>
<field-width>40</field-width>
<field-height>1</field-height>
<space-demand>4</space-demand>
<order>300</order>
<selected>false</selected>
<unique>false</unique>
<required>false</required>
<protected>false</protected>
</attribute>
</class>
</template>
</templateset>
Table of Contents