For a non-temporary case, in the first assignment, the case creator can add attachments and view them in the Case Worker portal 'Recent Content' or in an embedded section in the perform harness.
For example, all attachments added to case "A-1" will have pxLinkedRefFrom = "TF-PROC-BPA-WORK A-1"
For a temporary case, the section 'Recent Content' is hidden, however, using the OTB section AttachmentListView displays several attachments not part of this case.
Here, for a temporary case, the AttachmentsListView will display all attachments where pxLinkedRefFrom = "TF-PROC-BPA-WORK" (there is no case id) and therefore will show attachments that are not really attached to this temporary case.
We have a business requirement, where the case creator should be able to upload attachments to a temporary case in a screenflow. Before the case creator completes the screenflow, he/show will be able to navigate forward/back and review the information along with attachments already entered. Once the screenflow is complete and submitted, the case is persisted.
If the case is set as a temporary case, the attachment list section shows all attachments that are not part of this temporary case, and hence OTB temporary case settings do not work for attachments.
Expected: The temporary case should also allow attachments specific to this temporary case. The attachments should be discarded if the case is not persisted, and the attachments should be persisted when the case is persisted.
What is the workaround to use attachments with a temporary case?
***Moderator Edit-Vidyaranjan: Updated SR details***
Sri, you could probably store the attachments as part of the work object (under pyWorkPage) until the case is persisted. When the case is persisted, remove the attachments from the work object and store them as regular case attachments using data-workattach-file and link-attachment entries. Of course, until the case is persisted, you need to have a specialized "Recent Content" section which shows attachments stored within the case as opposed to listing link-attachment entries.
I have submitted this as an enhancement and attached the FDBK ID to your original thread. You can use our internal system to view this enhancement. If you try what @PraneethPurighalla has replied and it does work, let me know and I can cancel the request.