Support Article
P7: "error” is displaying on top of member 360 when Submitted
Summary
"Error” is displaying at the top of member 360 when user submits the assignment without filling the required filed in the form.
Error Messages
*Error
Steps to Reproduce
- Log into CPM Interaction portal.
- Create Interaction.
- Go to Member 360 screen.
- Submit the screen.
- Top of section error occurs.
Root Cause
In an assignment, if a validation of required for a control is kept, and process the assignment by keeping the control value empty in a dynamic layout group; then user witness an error message in the dynamic layout group.
When a tool tip is generated for the required filed a div is generated with the id=""iconErrorDiv".
If it exists then in webwb • pzpega_ui_layoutgroup there is function which adds error message:
div _addLayoutErrorMessage = function(layout) {
var iconErrorDivsSize = layout.find(".iconErrorDiv, .inputErrorDiv").filter(pega.u.d.isDisplayNone).length,
message;
// If there are errors, create the error table if it doesn't exist and set a message
if(iconErrorDivsSize == 1) {
message = pega.u.d.fieldValuesList.get("Error");
} else {
message = pega.u.d.fieldValuesList.get("Show next error");
}
errorTable = layout.children(".errorText");
if (errorTable.length == 0) {
layout.prepend("<div class='errorText error-table' style='width:100%; padding:10px;border-bottom:none;'>" + message + "</div>").children(".errorText").click(_goToNextError);
} else {
errorTable.text(message);
}
},
Resolution
Add the below code in the userworkform:
<style>
.content-layout-group > .error-table {
cursor: pointer;
display: none !important;
}
</style>
Published April 29, 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.