On the leave request form that I'm working on, there are certain leave types that require that the form originator
attach some sort of documentation, like a doctor's note if they are claiming sick leave.
In my start point, I have the "Permit adding attachments" checkbox selected, and store the attachments in a process variable called "formAttachments", which is of type "document<list>".
In my processing, I need to verify that they attached a file. I have a decision point with a conditional route that is executed if an attachment is found in "formAttachments". I've run into a problem trying to find the proper way to make this determination.
I currrently have the expression:
get-collection-size(/process_data/formAttachments) != 0
I've also tried:
getDocAttribute(/process_data/formAttachments[1],"wsfilename") > ""
to check for the existence of a filename attribute. Neither of these works.
Could someone please help me figure out the proper way to check for the attachment?
Thanks much for any help.