Support Article
Impossible to release lock after localizing button label
SA-18799
Summary
Developer has localized their application to French and the localized value for "End other session to Release Lock" is set to "L'autre extrémité session pour déverrouiller".
The localized value contains a single quote('). This causes a syntax error for that button and loss of OnClick functionality.
Error Messages
N/A
No message in tracer and log file. Button seems to do nothing
Steps to Reproduce
1. Create a field value as @baseclass • pyButtonLabel • End other session to Release Lock and add "L'autre extrémité session pour déverrouiller" as the translated value.
2. Open a case in Session 1 with Operator 1.
3. Open the same case in another session with the same operator(Operator 1).
Root Cause
There is a issue with Pega:lookup tag.
Removing pega:lookup tag and adding call to get localized value and escaping that value.
Changes in RUF GenerateButton.
l_caption_escape = StringUtils.escapeIntoJavaString(tools.getLocalizedTextForString("pyButtonLabel",paramCaption));
instead of
l_caption = "<pega:lookup property =\".pyButtonLabel\" value=\""+paramCaption+"\"/>";
Resolution
HFix-25666 resolved the issue.
Published January 31, 2016 - Updated October 8, 2020
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.