Question
IBPM
UA
Last activity: 14 Jan 2016 5:43 EST
How to clear comments form on pressing the Submit button?
Hi!
I have an assignment with comments form (text area, "add comment" button, and history of comments). It is designed with standard Pega mechanism. At clipboard there is page Note (Data-WorkAttach-Note) and page AllNotes (Code-Pega-List).
Button "Add comment" contains a control pxButton with behavior:
Event Click - Refresh Section (Target: This section).
Button Submit is designed as custom submit button with a single action in its behavior:
Event Click - FinishAssignment.
So I have such problem. I have to add new comment only by pressing "Add comment" button. But new comment is also added when I press Submit. I tried to solve this problem by adding events on Submit button in these ways:
1) Add an event Display -> Set Value -> Note.pyNote == "", and event Refresh before FinishAssignment.
2) Add Data Transform that sets Note.pyNote to "". (before FinishAssignment).
3) Add Activity that sets Note.pyNote to "". (before FinishAssignment).
But it doesn't work. Comment always move to AllNotes list on Submit button
Can anybody help to solve it?