Question

How can a when rule be applied as a filter in a report definition?

Hello,

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?

-Joe

***Edited by Moderator: Lochan to update platform capability tags***

Correct Answer
November 14, 2019 - 11:10am

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.

 

-Joe

Comments

Keep up to date on this post and subscribe to comments

November 14, 2019 - 12:23am

Hi

Can you confirm in what scenario the drop down  is editable or read only?

Regards

Bhavya

November 14, 2019 - 8:09am
Response to Bhavya_Incessant

Hi, 

Yes. And thank you for your timely response.

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.

Thanks.

 

-Joe

November 14, 2019 - 11:10am

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.

 

-Joe