Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function beforeTaskSave(colleagueId, nextSequenceId, userList) {
- var attachments = hAPI.listAttachments();
- var hasAttachment = false;
- for (var i = 0; i < attachments.size(); i++) {
- var attachment = attachments.get(i);
- if (attachment.getDocumentDescription() == "fluig.pdf") {
- hasAttachment = true;
- }
- }
- if (!hasAttachment) {
- throw "Erro... Não há anexo fluig.pdf!";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement