Posted: 13 Nov 2019 15:56 EST Last activity: 15 Nov 2019 4:51 EST
How can a when rule be applied as a filter in a report definition?
In Pega 7.1.5, I have a report definition from a data table with active and inactive names being used for a dropdown menu for a section. How can I apply a when rule so that when its read only, all names are made available, while if its editable(selectable from the dropdown) only active names are available?
***Edited by Moderator: Lochan to update platform capability tags***
The section is used on all transactions, historical for review as well as for new transactions. Some of the names are no longer applicable to new transactions therefore they are ''Inactive' while when reviewing transactions 'Inactive' names will still need to populate for historical bookkeeping.
So to clarify, editable will be on new transactions, read only will be on transactions that have already been taken place. Or editable for only 'Active' names, while read only we need both 'Active' and 'Inactive' names on the list to be able to populate.
I believe I found a solution. Instead of trying to insert a when rule in the section or within the report definition, I created a data page rule as the source for the dropdown/read only field in the section. Within that data page I indicated List structure which allowed for applying a when rule to source the report definition. I did have to create a seperate report definition making them two, one to FetchAllNames, the other to FetchActiveNames. But it works using pxIsEditable as the when rule.