|
|
|
@ -34527,10 +34527,11 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
|
|
var _resolve = void 0; |
|
|
|
|
callbacks.push(function () { |
|
|
|
|
if (cb) { |
|
|
|
|
// try {
|
|
|
|
|
try { |
|
|
|
|
cb.call(ctx); |
|
|
|
|
// } catch (e) {
|
|
|
|
|
// }
|
|
|
|
|
} catch (e) { |
|
|
|
|
console.error(e); |
|
|
|
|
} |
|
|
|
|
} else if (_resolve) { |
|
|
|
|
_resolve(ctx); |
|
|
|
|
} |
|
|
|
@ -35147,7 +35148,7 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
|
|
} catch (e) { |
|
|
|
|
// if (this.user) {
|
|
|
|
|
// } else {
|
|
|
|
|
throw e; |
|
|
|
|
console.error(e); |
|
|
|
|
// }
|
|
|
|
|
} finally { |
|
|
|
|
// "touch" every property so they are all tracked as
|
|
|
|
@ -35213,12 +35214,17 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
|
|
var oldValue = this.value; |
|
|
|
|
this.value = value; |
|
|
|
|
if (this.user) { |
|
|
|
|
// try {
|
|
|
|
|
try { |
|
|
|
|
this.cb.call(this.vm, value, oldValue, options); |
|
|
|
|
// } catch (e) {
|
|
|
|
|
// }
|
|
|
|
|
} catch (e) { |
|
|
|
|
console.log(e); |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
try { |
|
|
|
|
this.cb.call(this.vm, value, oldValue, options); |
|
|
|
|
} catch (e) { |
|
|
|
|
console.log(e); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
@ -35384,7 +35390,7 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
|
|
return NaN; |
|
|
|
|
}, function (newValue, oldValue, opt) { |
|
|
|
|
callback(i, newValue, oldValue, _.extend({ index: i }, opt)); |
|
|
|
|
}); |
|
|
|
|
}, options); |
|
|
|
|
watchers.push(function unwatchFn() { |
|
|
|
|
w.teardown(); |
|
|
|
|
v.__ob__._scopeDeps && remove(v.__ob__._scopeDeps, dep); |
|
|
|
@ -35425,7 +35431,7 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
|
|
return NaN; |
|
|
|
|
}, function (newValue, oldValue, opt) { |
|
|
|
|
callback(i, newValue, oldValue, _.extend({ index: i }, opt)); |
|
|
|
|
}); |
|
|
|
|
}, options); |
|
|
|
|
watchers.push(function unwatchFn() { |
|
|
|
|
_w.teardown(); |
|
|
|
|
root._globalDeps && delete root._globalDeps[regStr]; |
|
|
|
@ -35537,9 +35543,7 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
|
|
if (typeof cb === 'string') { |
|
|
|
|
cb = vm[cb]; |
|
|
|
|
} |
|
|
|
|
return watch(vm.model, keyOrFn, _.bind(cb, vm.$$model ? vm.model : vm), _.extend({ |
|
|
|
|
sync: true |
|
|
|
|
}, options)); |
|
|
|
|
return watch(vm.model, keyOrFn, _.bind(cb, vm.$$model ? vm.model : vm), options); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function initMethods(vm, methods) { |
|
|
|
@ -85542,6 +85546,9 @@ BI.MultiSelectBar = BI.inherit(BI.BasicButton, {
|
|
|
|
|
this.checkbox.on(BI.Controller.EVENT_CHANGE, function () { |
|
|
|
|
self.fireEvent(BI.Controller.EVENT_CHANGE, BI.Events.CLICK, self.isSelected(), self); |
|
|
|
|
}); |
|
|
|
|
this.checkbox.on(BI.Checkbox.EVENT_CHANGE, function () { |
|
|
|
|
self.fireEvent(BI.MultiSelectBar.EVENT_CHANGE, self.isSelected(), self); |
|
|
|
|
}); |
|
|
|
|
this.half.on(BI.Controller.EVENT_CHANGE, function () { |
|
|
|
|
self.fireEvent(BI.Controller.EVENT_CHANGE, BI.Events.CLICK, self.isSelected(), self); |
|
|
|
|
}); |
|
|
|
@ -93595,26 +93602,6 @@ BI.extend(BI.AbstractFilterItem, {
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
BI.shortcut("bi.filter_expander", FilterExpander); |
|
|
|
|
}());/** |
|
|
|
|
* Created by Urthur on 2017/12/21. |
|
|
|
|
*/ |
|
|
|
|
!(function () { |
|
|
|
|
BI.constant("bi.constant.component.filter", { |
|
|
|
|
FORMULA_COMBO: [{ |
|
|
|
|
text: BI.i18nText("BI-Conf_Formula_And"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_FORMULA_AND |
|
|
|
|
}, { |
|
|
|
|
text: BI.i18nText("BI-Conf_Formula_Or"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_FORMULA_OR |
|
|
|
|
}], |
|
|
|
|
CONDITION_COMBO: [{ |
|
|
|
|
text: BI.i18nText("BI-Conf_Condition_And"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_CONDITION_AND |
|
|
|
|
}, { |
|
|
|
|
text: BI.i18nText("BI-Conf_Condition_Or"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_CONDITION_OR |
|
|
|
|
}] |
|
|
|
|
}); |
|
|
|
|
}());/** |
|
|
|
|
* 过滤 |
|
|
|
|
* |
|
|
|
@ -93920,6 +93907,27 @@ BI.Filter.FILTER_TYPE.EMPTY_CONDITION = 37;
|
|
|
|
|
!(function () { |
|
|
|
|
var OPERATION_ADD_CONDITION = 0, OPERATION_ADD_ANDOR_CONDITION = 1; |
|
|
|
|
var FilterOperation = BI.inherit(BI.Widget, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
return BI.extend(FilterOperation.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
|
constants: { |
|
|
|
|
FORMULA_COMBO: [{ |
|
|
|
|
text: BI.i18nText("BI-Conf_Formula_And"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_FORMULA_AND |
|
|
|
|
}, { |
|
|
|
|
text: BI.i18nText("BI-Conf_Formula_Or"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_FORMULA_OR |
|
|
|
|
}], |
|
|
|
|
CONDITION_COMBO: [{ |
|
|
|
|
text: BI.i18nText("BI-Conf_Condition_And"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_CONDITION_AND |
|
|
|
|
}, { |
|
|
|
|
text: BI.i18nText("BI-Conf_Condition_Or"), |
|
|
|
|
value: BI.AbstractFilterItem.FILTER_OPERATION_CONDITION_OR |
|
|
|
|
}] |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
props: { |
|
|
|
|
baseCls: "bi-filter-operation", |
|
|
|
|
expander: {}, |
|
|
|
@ -94070,13 +94078,13 @@ BI.Filter.FILTER_TYPE.EMPTY_CONDITION = 37;
|
|
|
|
|
case BI.AbstractFilterItem.FILTER_OPERATION_FORMULA: |
|
|
|
|
text = BI.i18nText("BI-Conf_Add_Formula"); |
|
|
|
|
cls = "filter-formula-font"; |
|
|
|
|
items = BI.Constants.getConstant("bi.constant.component.filter").FORMULA_COMBO; |
|
|
|
|
items = this.options.constants.FORMULA_COMBO; |
|
|
|
|
break; |
|
|
|
|
case BI.AbstractFilterItem.FILTER_OPERATION_CONDITION: |
|
|
|
|
default: |
|
|
|
|
text = BI.i18nText("BI-Conf_Add_Condition"); |
|
|
|
|
cls = "filter-condition-font"; |
|
|
|
|
items = BI.Constants.getConstant("bi.constant.component.filter").CONDITION_COMBO; |
|
|
|
|
items = this.options.constants.CONDITION_COMBO; |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -100657,6 +100665,7 @@ BI.MultiTreeSearcher = BI.inherit(BI.Widget, {
|
|
|
|
|
var o = this.options; |
|
|
|
|
ob || (ob = {}); |
|
|
|
|
ob.value || (ob.value = {}); |
|
|
|
|
var count = 0; |
|
|
|
|
if (BI.isNumber(ob)) { |
|
|
|
|
this.editor.setState(ob); |
|
|
|
|
} else if (BI.size(ob.value) === 0) { |
|
|
|
@ -100666,9 +100675,17 @@ BI.MultiTreeSearcher = BI.inherit(BI.Widget, {
|
|
|
|
|
BI.each(ob.value, function (name, children) { |
|
|
|
|
var childNodes = getChildrenNode(children); |
|
|
|
|
text += (o.valueFormatter(name + "") || name) + (childNodes === "" ? "" : (":" + childNodes)) + "; "; |
|
|
|
|
if (childNodes === "") { |
|
|
|
|
count++; |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
if (count > 20) { |
|
|
|
|
this.editor.setState(BI.Selection.Multi); |
|
|
|
|
} else { |
|
|
|
|
this.editor.setState(text); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function getChildrenNode (ob) { |
|
|
|
|
var text = ""; |
|
|
|
@ -100677,6 +100694,9 @@ BI.MultiTreeSearcher = BI.inherit(BI.Widget, {
|
|
|
|
|
index++; |
|
|
|
|
var childNodes = getChildrenNode(children); |
|
|
|
|
text += (o.valueFormatter(name + "") || name) + (childNodes === "" ? "" : (":" + childNodes)) + (index === size ? "" : ","); |
|
|
|
|
if (childNodes === "") { |
|
|
|
|
count++; |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
return text; |
|
|
|
|
} |
|
|
|
|