Support Article
Harness icons appearing on modal dialog
SA-279
Summary
When you click a button from a harness(having icons) it opens a modal dialog which displays a section with 'Bar' layout header for the first time. The second time you click the same button, it opens the modal dialog and shows the section but this time the harness icons appear on the section layout header as well.
Error Messages
none

Steps to Reproduce
1. Configure a button and configure it to open a local action in a modal dialog.
2. Include this button in a section which is included on a harness containing icons.
3. The section in the modal dialog has a simple layout with a header of type 'Bar'.
4. At runtime, click the button to open the modal dialog, dismiss the modal dialog.
5. Click the button the second time to launch the modal dialog, this time notice that harness icons appear on the modal dialog.
Root Cause
The root cause of this problem is a defect in customer application code/rules.
When Tracer and inspect the Parameter page are run on any step in ProcessAction activity, HeaderButtonSectionName parameter does not exist when the issue is reproducible.
The below markup(without the highlighted input tag) was part of a non-autogenerated section which was included in the Customer's Perform harness.
<pega:when test="param.headerButtonsAdded != \"true\"">
<td>
<script>
try {
var gHeaderButtonHTML=document.getElementById("HEADER_BUTTON_HTML");
document.write(gHeaderButtonHTML.innerHTML);
} catch(e) {}
</script>
</td>
<td><input type="hidden" id="HeaderButtonSectionIndicator" value="SubSectionCAWorkObjWrapperHeaderB" /></td>
<% tools.putParamValue("headerButtonsAdded","true"); %>
</pega:when>
The missing <input type="hidden" id="HeaderButtonSectionIndicator" value="SubSectionCAWorkObjWrapperHeaderB" /> is what causes the HeaderButtonSectionName to be passed empty hence causing the problem.
Resolution
This issue is resolved through the following local change:
Use below input tag in the non-autogenerated HTML markup
<input type="hidden" id="HeaderButtonSectionIndicator" value="SubSection<Name of your non-auto generated section that has the header with icons>B" />
In the reported case…
<input type="hidden" id="HeaderButtonSectionIndicator" value="SubSectionCAWorkObjWrapperHeaderB" />
Published February 9, 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.