Skip to content

Instantly share code, notes, and snippets.

@hai5nguy
Created June 15, 2016 18:24
Show Gist options
  • Save hai5nguy/94144ccdf398303cc6bdc6f370ab927a to your computer and use it in GitHub Desktop.
Save hai5nguy/94144ccdf398303cc6bdc6f370ab927a to your computer and use it in GitHub Desktop.
function workflowHasMultipleActiveFacts2() {
var hasMultipleFacts = false;
vm.Workflow.WorkflowItems.forEach(function (w) {
var itemsWithFacts = w.Facts.filter(function (f) { return f.Export })
if (itemsWithFacts.length >= 2) {
hasMultipleFacts = true; return
}
})
return hasMultipleFacts
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment