Product Update
Require a Minimum Number of Attachments
Xurrent UI extensions now provide the ability to determine the number of files that are attached to aĀ record before this record is saved. This can be accomplished with the following JavaScript in aĀ UIĀ extension:
ITRP.field(āattachmentā).size()
The JavaScript example below prevents someone in Xurrent Self Service from submitting a request without adding at least 3 attachments:
$(ā#saveā).on(āclickā, function(e) {
Ā Ā if (ITRP.field(āattachmentā).size() < 3) {
Ā Ā Ā Ā // at least 3 attachments
Ā Ā Ā Ā e.stopImmediatePropagation();
Ā Ā Ā Ā // prevents save action
Ā Ā Ā Ā // do something, show alert or error message
Ā Ā }
});