diff --git a/dist/fix/fix.compact.js b/dist/fix/fix.compact.js index 35a642878..abe505d96 100644 --- a/dist/fix/fix.compact.js +++ b/dist/fix/fix.compact.js @@ -115,7 +115,7 @@ function createStore () { var needPop = false; - if (_global.Fix && this._store) { + if (this._store) { var store = findStore(this.options.context || this._parent || this.options.element || this._context); if (store) { pushTarget(store); @@ -151,7 +151,11 @@ var __initWatch = BI.Widget.prototype.__initWatch; BI.Widget.prototype.__initWatch = function () { __initWatch.apply(this, arguments); - if (_global.Fix && this._store) { + var workerMode = BI.Providers.getProvider("bi.provider.system").getWorkerMode(); + if (workerMode && this._worker) { + return; + } + if (this._store) { initWatch(this, this.watch); } }; diff --git a/dist/fix/worker.compact.js b/dist/fix/worker.compact.js index f178f37bf..e537706ad 100644 --- a/dist/fix/worker.compact.js +++ b/dist/fix/worker.compact.js @@ -88,7 +88,7 @@ name: name, eventType: "create", options: options, - watches: BI.map(this.watch, function (key) { + watches: BI.map(this.$watch || this.watch, function (key) { return key; }) }); diff --git a/examples/worker.html b/examples/worker.html index 03cdc5be6..759f0eac4 100644 --- a/examples/worker.html +++ b/examples/worker.html @@ -6,7 +6,6 @@ --> -