Designer > Process Central Forms and Configuration > Configuring Task Role Filters
  

Configuring Task Role Filters

The Task Role Filters section of the Process Central configuration file allows for comprehensive configuration of the Tasks view, as shown by the circled areas on the following illustration.
You can add basic and advanced configuration.
Basic Configuration
Advanced Configuration
Advanced configuration provides customized task display and searching, including:

Basic Task Roles Filter Configuration

For an overview of this topic, see Configuring Task Role Filters.
In the Process Central configuration file (.avcconfig file), you can modify the default configuration in the Task Role Filters section as follows.
To add a new role to the Role list:
The base set of roles include the WS-HT roles of user (potential owner), administrator (business administrator), initiator (task initiator) and stakeholder. You may have your own role names to add, based on the WS-HT roles.
In the following line of the file, add an id of your choosing and fill in a name attribute for the Role name to be displayed.
<tns:taskRoleFilterDef id="FILL_IN_ROLE_NAME" name="FILL_IN_ROLE_NAME">
To add a new item to the Show list:
The base set of Show items displayed includes All, Unclaimed and Claimed.
In the following line of the file, add an Id and fill in a name attribute for the filter name to be displayed in the Show list.
<avccom:taskFilterDef id="FILL_IN_TASK_FILTER_ID" name="FILL_IN_TASK_FILTER_NAME">
To add a new category folder to the Task list:
The base set of categories includes Notifications, Open tasks and Closed tasks.
In the following line of the file, add an Id and fill in a name attribute for the category name to be displayed in the Task list.
<tns:taskFilterCategoryDef id="FILL_IN_FILTER_CATEGORY_ID" name="FILL_IN_FILTER_CATEGORY_NAME">
To show or hide folders for specified users and groups:
You can specify which users and groups can view the new folders you add. Using the Identity Service enabled in Process Server, copy the Role names associated with users and groups. If all users should see the new folders, remove the <role> elements.
Do not leave a <role> element as shown in the default, and do not leave the element empty because it means no one is allowed to see the folders.
<avccom:allowedRoles>
<avccom:role>FILL_IN_ROLE_1</avccom:role>
<avccom:role>FILL_IN_ROLE_2</avccom:role>
</avccom:allowedRoles>
You must delete the <roles> if you do not intend to specify user roles. The default value means that a user must be in the FILL_IN_ROLE_1 group to view the folder.
Example Configuration:
<tns:taskRoleFilterDefs>
<!-- for All users in the Role picklist -->
<tns:taskRoleFilterDef id="All_Role" name="All">
<!-- New folder -->
<tns:taskFilterCategoryDef id="Loan_Apps" name="New Car Loans">
<!-- Display the folder to these users and groups -->
<avccom:allowedRoles>
<avccom:role>group_Auto</avccom:role>
<avccom:role>gDriver</avccom:role>
</avccom:allowedRoles>
<!-- Add this filter to the Show picklist -->
<avccom:taskFilterDef id="auto_loans" name="InProgress">
</tns:taskFilterCategoryDef>
</tns:taskRoleFilterDef>
</tns:taskRoleFilterDefs>
For advanced configuration, see the following:

Configuring Custom Columns for Task Roles Filtering

In the Task Role Filters section of the .avcconfig file, you can add the task column names you want to display for a category (folder) of tasks. There is a default configuration of column names, and you can add to or replace the columns displayed.
Default Configuration
The default configuration for taskColumn uses standard WS-HT task properties (all prefixed with Task):
<avccom:taskColumns>
<avccom:taskColumn property="Task.Id">Id</avccom:taskColumn>
<avccom:taskColumn property="Task.Status"></avccom:taskColumn>
<avccom:taskColumn property="Task.Priority"></avccom:taskColumn>
<avccom:taskColumn property="Task.Name"></avccom:taskColumn>
<avccom:taskColumn property="Task.PresSubject"></avccom:taskColumn>
<avccom:taskColumn property="Task.CreatedOn"></avccom:taskColumn>
</avccom:taskColumns>
To replace or add to these columns, you can add your own column specification, using a custom task property, such as:
<avccom:taskColumn property="first">First Name</avccom:taskColumn>
You must create the custom column names as part of the task definition in a People activity.
To localize the column name, you can specify a key from a message properties file that you create. For example, the column name below is specified as ${bundle.key}:
<avccom:taskColumn property="Task.CreatedOn"
type="dateTime">${bundle.key}</avccom:taskColumn>
For details on creating a message properties file, see Adding Multilingual Support for Forms and Tasks.
The following sample Task Role Filter section illustrates the use of custom columns for Process Central.
<!--
Example - adding a new category/folder called Hello Tasks.
This folder will appear in the All role.
-->
<tns:taskRoleFilterDefs>
<tns:taskRoleFilterDef
id="ae-avc-role-all" name="${ae.avc.role.user.name}">
<tns:taskFilterCategoryDef id="custom-cat"
name="Hello Tasks">
<avccom:allowedRoles>
</avccom:allowedRoles>
<!--
Define custom columns that appear in Process Central
(or remove/comment out root element to use
default column list provided out of the box).
-->
<avccom:taskColumns>
<!-- Task.Id, Task.Status and Task.Name are
standard WS-HT columns.
-->
<avccom:taskColumn
property="Task.Id">Id</avccom:taskColumn>
<avccom:taskColumn
property="Task.Status"></avccom:taskColumn>
<avccom:taskColumn property="Task.Name">Task Name</avccom:taskColumn>
<avccom:taskColumn property="Task.PresName">
Display Name</avccom:taskColumn>
<!-- You can also specify the column data
formatting via the type attribute. Useful
values are date, dateTime and boolean. The
column display name can also be externalized
via ${18n.key} method.
-->
<avccom:taskColumn property="Task.CreatedOn"type="dateTime">
${bundle.key}</avccom:taskColumn>
<!-- The property names 'first' and 'last' are
WSHT task presentation parameters defined in
your tasks (custom properties).
-->
<avccom:taskColumn property="first">First Name</avccom:taskColumn>
<avccom:taskColumn property="surname">Surname (Last Name)</avccom:taskColumn>
</avccom:taskColumns>
<avccom:taskFilterDefRef ref="ae-avc-user-open-all"/>
<avccom:taskFilterDefRef
ref="ae-avc-user-open-unclaimed"/>
<avccom:taskFilterDefRef
ref="ae-avc-user-open-claimed"/>
<avccom:taskFilterDefRef
ref="ae-avc-user-open-suspended"/>
</tns:taskFilterCategoryDef>
</tns:taskRoleFilterDef>
</tns:taskRoleFilterDefs>

Configuring a GetMyTasks Filter with a WhereClause

In the Task Role Filters section of the .avcconfig file, you can add a filter to apply to the tasks in one of the Show pick entries. For example, you can create a filter for Unclaimed Tasks to show only Priority zero (highest priority).

Filtering a Task List using a Show Filter

Modify the default configuration in the <avccom:filter/> section of the <avccom:taskFilterDef/> section.
The following code snippet shows the default configuration:
<avccom:filter>
<tsst:getTasks xmlns:tsst="http://schemas.active-endpoints.com/b4p/wshumantask/2007/10/aeb4p-task-state-wsdl.xsd">
<htdt:getMyTasks
xmlns:htdt="http://www.example.org/WS-HT/api/xsd">
<htdt:taskType>TASKS</htdt:taskType
<htdt:genericHumanRole>POTENTIAL_OWNERS</htdt:genericHumanRole>
<htdt:status>READY</htdt:status>
<htdt:whereClause>Task.Name =
'ApproveLoan'</htdt:whereClause>
<htdt:maxTasks>20</htdt:maxTasks>
</htdt:getMyTasks>
<tsst:taskIndexOffset>0</tsst:taskIndexOffset>
</tsst:getTasks>
</avccom:filter>

Filtering a Task List by Parameter using a WS-HT whereClause

You can use the following operators in the whereClause:
The following examples show various whereClause syntax. Note that the Booleans and and or are case-sensitive.
For a complete list of task column names, task types, generic human roles and other WS-HT specifications, you can work with the Informatica Business Process Manager SDK.
Example 1
The following example shows a sample whereClause using a standard WS-HT task property name.
<htdt:whereClause>Task.Name = 'ApproveLoan'</htdtwhereClause>
Example 2
The following example combines filter properties:
Task.Priority &lt; 3 and Task.Owner = ‘loanrep1'
Example 3
The following example also combines filter properties.
Task.PaProcessId = 10
and(Task.Escalated = true
or Task.Priority = 0)
Example 4: Using Presentation Parameters (Custom Task Properties)
The following example shows using presentation parameters:
Task.Name = ‘LoanApproval'
and loanAmount &gt; 10000
and zipCode = '06484'

Presentation Parameters

If you query on presentation parameters, additional information is returned.
<tsst:propertyValues
xmlns:tsst=
"http://schemas.active-endpoints.com/b4p/wshumantask/
2007/10/aeb4p-task-state-wsdl.xsd">
<tsst:propertyValue
name="parentprocessid" type="ns:string"
xmlns:ns="http://www.w3.org/2001/XMLSchema">5013
</tsst:propertyValue>
</tsst:propertyValues>
If no task is deployed with the presentation parameter, an error message is returned:
<htdt:illegalArgument
xmlns:htdt="http://www.example.org/WS-HT/api/xsd">
Task parameter property 'parentProcessId1' does not
exist.
</htdt:illegalArgument>
However, if no task with this parameter exists but it is a valid name, the returned information is empty. Here is an example of this kind of parameter:
<aetgt:getMyTasksResponse
xmlns:aetgt="http://www.example.org/WS-HT/api/xsd"
xmlns:htdt="http://www.example.org/WS-HT/api/xsd"
xmlns:result="http://saxon.sf.net/xquery-results"
xmlns:tss="http://www.activebpel.org/b4p/2007/10/wshumantask/aeb4p-task-storage.wsdl"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >
This element lists tasks that a parentProcessId parameter and also returns what this value is:
<xsd:getMyTasks>
<xsd:taskType>TASK</xsd:taskType>
<xsd:whereClause>parentProcessId >''</xsd:whereClause>
</xsd:getMyTasks>
The following table summarized what can occur when you use a presentation parameter.
Presentation Parameter
Is it Deployed
Actual Values
Query
Result
MyString
Yes
"a", "b"
<a where clause>
<a parameter result>
MyStringB
Yes
No Values
<a where clause>
<a parameter result>
MyStringC
No
Not applicable
<a where clause>
<a parameter result>

Using a getTasks orderBy Element

You can sort the results returned by getTasks by using the orderBy element. The fields name you can use are:
The following example sorts the results with the most recent first (that is, in descending order), followed by the priority:
OrderBy orderBy = new OrderBy();
orderBy.getFieldId().add("-Created");
orderBy.getFieldId().add("-Created");
Notice the minus sign ("-") to set the order to descending.
In XML, this same example is:
<ns:orderBy>
<ns:fieldId>-Created</ns:fieldId>
<ns:fieldIPdriority</ns:fieldId>
</ns:orderBy>

Configuring an RSS or Atom Feed Filter

For an overview of this topic, see Configuring Task Role Filters.
In the Task Role Filters section of the .avcconfig file, there is an element containing default URL details for a RSS or Atom Web feed. Process Central contains a Web feed subscription service that users can select to be notified about task updates.
In the .avcconfig file, the default query and format is shown as:
<avccom:feedQueryString format="rss" />
At runtime, the Web feed URL is automatically generated based on <getMyTasks>. For example, in Process Central, if the Tasks list is showing open tasks, the feed will send updates when new tasks arrive.
The default Web feed format is rss, but you can change it to atom, if desired.
If you leave the Task Role Filters section commented out when you deploy the avcconfig file, the default Web feed URL is generated from the default avoscentral.avcconfig file. You can look at this file in the Process Console, under the Catalog section.
You can modify the Web feed query filter as follows: