angular-busy
angular-busy copied to clipboard
Allow advanced version to accept a promise, or something that has a .promise or .$promise
Of the two options to pass to cg-busy is it possible to have the advanced version to expect a promise (or something that has a .promise or .$promise similar to the simple version. That would allow the use of $q.defer() in the advanced version, and an easy invocation to either resolve or reject, for example:
// Controller
vm.busy = {
promise: $q.defer(),
templateUrl: 'something.html',
message: '...',
backdrop: false
}
// Template
<div cg-busy="vm.busy"></div>
+1
Hi @mtpultz implemented your desired modifications from this post https://github.com/cgross/angular-busy/issues/102 into my fork. https://github.com/tiberiuzuld/angular-busy