Error occurs when sending email with attachments
Pega Platform 8.1. 1 is updated to Pega Platform 8.2.1.
During testing, unable to send emails with workobject attachments. Additionally, the Send Email works without attachments.
Cannot open or save instances of class Data-EmailAttachments
Steps to Reproduce
The SendEmailWith*Attachments activity is to send an email with the Case attachments. If the attachment is not associated with a case, then the attachment's information must be specified by custom pages or parameters.
The 'ReferencePage' parameter is an optional parameter to inform the API to which case the case attachments belong to. If the attachment is not associated with a case, then the attachment's information must be specified by custom pages or parameters.
After refactoring the code in Pega Platform 8.2, when the ReferencePage is present or set with some data, then that work object is attempted to be opened. When the ReferencePage is set with the AttchmentPage as a reference, the application attempted to open the 'Data-EmailAttachments' page which is not present but is populated with the stream data. As a result, the error occurs.
Perform the following local-change:
Use the SendEmailNotification with AttachmentPage parameter set (instead of SendEmailWith*Attachments).