Active Wizard Configurations - tsgrp/HPI GitHub Wiki

Micro States

The microState attribute is designed to keep track of which priority/task is current awaiting completion in a workflow. For example, it could read: Waiting on CR Approvers since 9/9/2015. The desired verbiage for the attribute is configurable (in OC) for each potential priority in a workflow.

The wizard-bean-config.xml should be where your configuration takes place, and should be conceptualized as a Map<String, Map<String, String>> data structure. The "main" map will be comprised of "sub" maps--one for each priority/task in a workflow. Each submap will contain the desired microState value, once that priority/task is pending. Here is the default configuration for Simple CR:

<util:map id="MicroStateMap" map-class="java.util.HashMap">
    <entry key="Initial QA" value-ref="InitialQAAttrMap" />
    <entry key="Regulatory" value-ref="RegulatoryAttrMap" />
    <entry key="CR Approval" value-ref="CRApproversAttrMap"/>
</util:map>

<util:map id="InitialQAAttrMap" map-class="java.util.HashMap">
    <entry key="microState" value="Waiting on Initial QA since {currentDate}"/>
</util:map>

<util:map id="RegulatoryAttrMap" map-class="java.util.HashMap">
    <entry key="microState" value="Waiting on Regulatory since {currentDate}"/>
</util:map>

<util:map id="CRApproversAttrMap" map-class="java.util.HashMap">
    <entry key="microState" value="Waiting on CR Approvers since {currentDate}"/>
</util:map>

To clarify, the keys of the MicroStateMap correspond to each (potential) priority/task, and the key of a submap is the attribute that will be changed, while the value is what that attribute will be modified to.

Notes:

  • The {currentDate} placeholder can be used to insert the date and time at which the priority/task was started.
  • Micro states can be enabled/disabled in the wizard-defaults.propeties by switching the wizard.microstates.enabled variable to true or false.
  • The microState will automatically become "Approved" when the workflow is approved.
  • StartUserTaskListener.java is largely where the implementation of microStates is, so look there to understand how it works, or to add additional placeholders, etc.
⚠️ **GitHub.com Fallback** ⚠️