Skip to content

Commit

Permalink
improved PA selector disabler
Browse files Browse the repository at this point in the history
  • Loading branch information
innerjoin committed Mar 28, 2018
1 parent fd0ae0b commit b110cb6
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions src/components/bulk-mover.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,10 +189,19 @@ const BulkMoverComponent = Vue.extend({
},

loadQuery() {
var el = JazzHelpers.getQueryDialog(this.querySelected);
setTimeout(function() {
el.contentWidget.areaSelect.disabled = true;
}, 100);
var queryDialog = JazzHelpers.getQueryDialog(this.querySelected);
this.disablePASelectorInQuery(queryDialog, 0);
},

disablePASelectorInQuery(queryDialog, attempt) {
var self = this;
if(typeof queryDialog.contentWidget !== "undefined" && typeof queryDialog.contentWidget.areaSelect !== "undefined") {
queryDialog.contentWidget.areaSelect.disabled = true;
} else if(attempt < 15) {
setTimeout(function() {
self.disablePASelectorInQuery(queryDialog, ++attempt);
}, 50);
}
},

querySelected(data) {
Expand Down

0 comments on commit b110cb6

Please sign in to comment.