Support Article
Adding suggestion intent conditionally in confirm harness
SA-6004
Summary
User is trying to implement adding intent task to suggestion list in confirm harness. They are following CPM_ImplementationGuide_71R2.pdf which is provided by pega. When they do configuration as implementation guide, it is not working as expected.
Implementation guide refers the sample Statement Request process, but there is no such process in sample application.
They are referring ‘Configuring Task Suggestions on the Confirm Harness’ 5-25 page in CPM_ImplementationGuide_71R2.pdf.
Problem Scenario:
1. User navigates to intent driver.
2. User perform intent task.
3. User Click on the check box which is given in UI.
4. User Click on the submit button and navigates to confirm harness.
5. User click on ‘close’ button in confirm harness.
Expected Result:
Suggested intent task should be in suggestion list.
Actual Result:
Suggested intent task is not added in suggestion list.
Error Messages
NA
Steps to Reproduce
1. Create a intent when rule.
2. Added intent when to ‘CPMTaskSuggestionsOnConfirm’ map value.
3. Added intent when rule in to flow and action configured as ‘Suggestion’
4. Intent when rule returns true when user click on the checkbox which is in UI.
Root Cause
The root cause of this problem is a defect in user's application code/rules. The configuration of CPM DataSource and IntenWhen rule are incorrect. The property for when rule evaluation is not present in the primary page during when evaluation which is CAPortalInteraction.
The intent when rule is evaluating false for user is because the service item is running on a different thread and the interaction item is on a different thread with an altogether different page context. So, during run time, the when rule evaluation happens in a different thread where the property user is trying to refer may not exist or may hold a different value.
Resolution
In order for the value of the service item case to be present in parent interaction case so that the when rule evaluates correctly, user will need to propagate the value from service item to interaction item. This can be done by setting the value for the property in the CAPortalInteraction page in the service item thread. CPM code will take care of inter thread communication.
To achieve this , in the post activity of your service case flow action, do a property set on the CAPortalInteraction page for the when rule evaluation property.
Tags:
Published January 31, 2016 - Updated December 2, 2021
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.