Question

6
Replies
1362
Views
sumaa Member since 2013 2 posts
PEGA
Posted: 2 years ago
Last activity: 2 years 8 months ago
Closed

How to delegate a property ?

Hi,

I am using Pega 7.3.1 and get an option to delegate a property (Actions -> Delegate). I understand that the feature of rule delegation to business users is available for rules such as decision table, decision tree, map value and so on and I assume the feature to delegate a property is something that might have been introduced in 7.3.

Delegate option for a property.PNG

I am assuming that if a property can be delegated, the business users can add/remove the local lists defined on the property. And this can save me from creating a decision table or any other addition rule that usually gets delegated. I would like to understand how can I leverage this new feature.

I have a text type property with "pxDropdown" as UI Control and table type specified as "PromptList" with sample values specified as standard and prompt value. When I try to delegate the property, it throws an error "This Property cannot be delegated because no selectable options are available for this configuration.".

Property delegation error.PNG

I tried several options like using local list, prompt list to specify a list a values that could be selected, or by altering the UI control from text input to dropdown, on property types of text or page but ended up with the same error.

I am unable to figure out what does "selectable options" mean here.

This error is set by the OOTB activity "pzGetValidEditingExperiences" in step 11 (when the value of pyIsEnabled is not true) and the pyIsEnabled property is set using local variable "enabled" in step 7.4. The value of the local variable "enabled" is determined in the java step 7.3 probably through evaluation of a when rule "pyBlockName". But I don't find a when rule by that name, there are two identifier type properties with name "pyBlockName" of classes Rule-Obj-When and Rule-Access-When.

#######################################

Java code snippet :

StringMap strMap = new HashStringMap();

strMap.putString("pyBlockName", whenRule);

PRStackFrame frame = ((PegaAPI)tools).pushStackFrame("when", null, page , true, false);

try {

enabled = tools.evaluateWhen(strMap);

} finally {

if (frame != null) ((PegaAPI)tools).popStackFrame(frame, false);

}

#########################################

I would need help to understand how a property should be defined so that it can be delegated. Help page for property rule doesn't talk about the delegation feature (probably because it is not part of the property rule form, however this should have been captured somewhere in the help, like in the more part of the property help page).

Right now I am achieving the desired feature using a decision table and a clipboard page, but will prefer to avoid creating extra rules if that is possible.

Thanks,
Akhilesh

Low-Code App Development Dev/Designer Studio Data Integration Java and Activities
Moderation Team has archived post
Share this page LinkedIn