|
|
|
@ -20478,7 +20478,7 @@ _.extend(BI, {
|
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
afterFunc: function (func) { |
|
|
|
|
afterFunc: function (sFunc, func) { |
|
|
|
|
var __self = sFunc; |
|
|
|
|
return function () { |
|
|
|
|
var ret = __self.apply(sFunc, arguments); |
|
|
|
@ -33732,7 +33732,9 @@ BI.shortcut("bi.inline_vertical_adapt", BI.InlineVerticalAdaptLayout);/**
|
|
|
|
|
BI.FlexCenterLayout = BI.inherit(BI.Layout, { |
|
|
|
|
props: function () { |
|
|
|
|
return BI.extend(BI.FlexCenterLayout.superclass.props.apply(this, arguments), { |
|
|
|
|
baseCls: "bi-flex-center-adapt-layout" |
|
|
|
|
baseCls: "bi-flex-center-adapt-layout", |
|
|
|
|
hgap: 0, |
|
|
|
|
vgap: 0 |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
render: function () { |
|
|
|
@ -33743,7 +33745,14 @@ BI.FlexCenterLayout = BI.inherit(BI.Layout, {
|
|
|
|
|
_addElement: function (i, item) { |
|
|
|
|
var o = this.options; |
|
|
|
|
var w = BI.FlexCenterLayout.superclass._addElement.apply(this, arguments); |
|
|
|
|
w.element.css({position: "relative", "flex-shrink": "0"}); |
|
|
|
|
w.element.css({ |
|
|
|
|
position: "relative", |
|
|
|
|
"flex-shrink": "0", |
|
|
|
|
"margin-left": (i === 0 ? o.hgap : 0) + "px", |
|
|
|
|
"margin-right": o.hgap + "px", |
|
|
|
|
"margin-top": o.vgap + "px", |
|
|
|
|
"margin-bottom": o.vgap + "px" |
|
|
|
|
}); |
|
|
|
|
return w; |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
@ -33792,8 +33801,6 @@ BI.FlexHorizontalCenter = BI.inherit(BI.Layout, {
|
|
|
|
|
scrollable: o.scrollable, |
|
|
|
|
hgap: o.hgap, |
|
|
|
|
vgap: o.vgap, |
|
|
|
|
lgap: o.lgap, |
|
|
|
|
rgap: o.rgap, |
|
|
|
|
tgap: o.tgap, |
|
|
|
|
bgap: o.bgap, |
|
|
|
|
items: o.items |
|
|
|
@ -33923,12 +33930,10 @@ BI.FlexVerticalCenter = BI.inherit(BI.Layout, {
|
|
|
|
|
scrollx: o.scrollx, |
|
|
|
|
scrolly: o.scrolly, |
|
|
|
|
scrollable: o.scrollable, |
|
|
|
|
hgap: o.hgap, |
|
|
|
|
vgap: o.vgap, |
|
|
|
|
lgap: o.lgap, |
|
|
|
|
rgap: o.rgap, |
|
|
|
|
tgap: o.tgap, |
|
|
|
|
bgap: o.bgap, |
|
|
|
|
hgap: o.hgap, |
|
|
|
|
items: o.items |
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
@ -34043,7 +34048,13 @@ BI.FlexWrapperCenterLayout = BI.inherit(BI.Layout, {
|
|
|
|
|
_addElement: function (i, item) { |
|
|
|
|
var o = this.options; |
|
|
|
|
var w = BI.FlexWrapperCenterLayout.superclass._addElement.apply(this, arguments); |
|
|
|
|
w.element.css({position: "relative"}); |
|
|
|
|
w.element.css({ |
|
|
|
|
position: "relative", |
|
|
|
|
"margin-left": (i === 0 ? o.hgap : 0) + "px", |
|
|
|
|
"margin-right": o.hgap + "px", |
|
|
|
|
"margin-top": o.vgap + "px", |
|
|
|
|
"margin-bottom": o.vgap + "px" |
|
|
|
|
}); |
|
|
|
|
return w; |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
@ -34103,8 +34114,6 @@ BI.FlexWrapperHorizontalCenter = BI.inherit(BI.Layout, {
|
|
|
|
|
scrollable: o.scrollable, |
|
|
|
|
hgap: o.hgap, |
|
|
|
|
vgap: o.vgap, |
|
|
|
|
lgap: o.lgap, |
|
|
|
|
rgap: o.rgap, |
|
|
|
|
tgap: o.tgap, |
|
|
|
|
bgap: o.bgap, |
|
|
|
|
items: o.items |
|
|
|
@ -34242,8 +34251,6 @@ BI.FlexWrapperVerticalCenter = BI.inherit(BI.Layout, {
|
|
|
|
|
vgap: o.vgap, |
|
|
|
|
lgap: o.lgap, |
|
|
|
|
rgap: o.rgap, |
|
|
|
|
tgap: o.tgap, |
|
|
|
|
bgap: o.bgap, |
|
|
|
|
items: o.items |
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
@ -45373,9 +45380,12 @@ BI.Button = BI.inherit(BI.BasicButton, {
|
|
|
|
|
} |
|
|
|
|
if (BI.isKey(o.iconCls)) { |
|
|
|
|
this.icon = BI.createWidget({ |
|
|
|
|
type: "bi.icon", |
|
|
|
|
type: "bi.icon_label", |
|
|
|
|
cls: o.iconCls, |
|
|
|
|
width: 18, |
|
|
|
|
height: o.height - 2 |
|
|
|
|
height: o.height - 2, |
|
|
|
|
iconWidth: o.iconWidth, |
|
|
|
|
iconHeight: o.iconHeight |
|
|
|
|
}); |
|
|
|
|
this.text = BI.createWidget({ |
|
|
|
|
type: "bi.label", |
|
|
|
@ -45385,14 +45395,9 @@ BI.Button = BI.inherit(BI.BasicButton, {
|
|
|
|
|
}); |
|
|
|
|
BI.createWidget({ |
|
|
|
|
type: "bi.center_adapt", |
|
|
|
|
cls: o.iconCls, |
|
|
|
|
element: this, |
|
|
|
|
hgap: o.hgap, |
|
|
|
|
vgap: o.vgap, |
|
|
|
|
tgap: o.tgap, |
|
|
|
|
bgap: o.bgap, |
|
|
|
|
lgap: o.lgap, |
|
|
|
|
rgap: o.rgap, |
|
|
|
|
items: [{ |
|
|
|
|
type: "bi.horizontal", |
|
|
|
|
items: [this.icon, this.text] |
|
|
|
@ -47667,7 +47672,7 @@ BI.shortcut("bi.checkbox", BI.Checkbox);/**
|
|
|
|
|
var multipart = function (boundary, name, file) { |
|
|
|
|
return "--".concat( |
|
|
|
|
boundary, CRLF, |
|
|
|
|
"Content-Disposition: form-data; name=\"", name, "\"; filename=\"", BI.cjkEncode(file.fileName), "\"", CRLF, |
|
|
|
|
"Content-Disposition: form-data; name=\"", name, "\"; filename=\"", _global.encodeURIComponent(file.fileName), "\"", CRLF, |
|
|
|
|
"Content-Type: application/octet-stream", CRLF, |
|
|
|
|
CRLF, |
|
|
|
|
file.getAsBinary(), CRLF, |
|
|
|
@ -47756,7 +47761,9 @@ BI.shortcut("bi.checkbox", BI.Checkbox);/**
|
|
|
|
|
switch (xhr.readyState) { |
|
|
|
|
case 2: |
|
|
|
|
case 3: |
|
|
|
|
if (rpe.total <= rpe.loaded) {rpe.loaded = rpe.total;} |
|
|
|
|
if (rpe.total <= rpe.loaded) { |
|
|
|
|
rpe.loaded = rpe.total; |
|
|
|
|
} |
|
|
|
|
upload.onprogress(rpe); |
|
|
|
|
break; |
|
|
|
|
case 4: |
|
|
|
@ -47822,8 +47829,12 @@ BI.shortcut("bi.checkbox", BI.Checkbox);/**
|
|
|
|
|
var url = handler.url.concat(-1 === handler.url.indexOf("?") ? "?" : "&", "AjaxUploadFrame=true"), |
|
|
|
|
rpe = { |
|
|
|
|
loaded: 1, total: 100, simulation: true, interval: setInterval(function () { |
|
|
|
|
if (rpe.loaded < rpe.total) {++rpe.loaded;} |
|
|
|
|
if (isFunction(handler.onprogress)) {handler.onprogress(rpe, {});} |
|
|
|
|
if (rpe.loaded < rpe.total) { |
|
|
|
|
++rpe.loaded; |
|
|
|
|
} |
|
|
|
|
if (isFunction(handler.onprogress)) { |
|
|
|
|
handler.onprogress(rpe, {}); |
|
|
|
|
} |
|
|
|
|
}, 100) |
|
|
|
|
}, |
|
|
|
|
onload = function () { |
|
|
|
@ -47840,7 +47851,7 @@ BI.shortcut("bi.checkbox", BI.Checkbox);/**
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// attachO.fileSize = responseText.length;
|
|
|
|
|
attachO.filename = BI.cjkDecode(handler.file.fileName); |
|
|
|
|
attachO.filename = _global.decodeURIComponent(handler.file.fileName); |
|
|
|
|
if (handler.maxlength == 1) { |
|
|
|
|
handler.attach_array[0] = attachO; |
|
|
|
|
} else { |
|
|
|
@ -49329,7 +49340,7 @@ BI.Toast = BI.inherit(BI.Tip, {
|
|
|
|
|
}); |
|
|
|
|
BI.Toast.EVENT_DESTORY = "EVENT_DESTORY"; |
|
|
|
|
BI.shortcut("bi.toast", BI.Toast);/** |
|
|
|
|
* toast提示 |
|
|
|
|
* title提示 |
|
|
|
|
* |
|
|
|
|
* Created by GUY on 2015/9/7. |
|
|
|
|
* @class BI.Tooltip |
|
|
|
@ -52221,12 +52232,7 @@ BI.SingleSelectIconTextItem = BI.inherit(BI.Single, {
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
BI.shortcut("bi.single_select_icon_text_item", BI.SingleSelectIconTextItem);/** |
|
|
|
|
* guy |
|
|
|
|
* 复选框item |
|
|
|
|
* @type {*|void|Object} |
|
|
|
|
*/ |
|
|
|
|
BI.SingleSelectItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
BI.shortcut("bi.single_select_icon_text_item", BI.SingleSelectIconTextItem);BI.SingleSelectItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
return BI.extend(BI.SingleSelectItem.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
|
extraCls: "bi-single-select-item bi-list-item-active", |
|
|
|
@ -52978,12 +52984,7 @@ BI.Switch = BI.inherit(BI.BasicButton, {
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
BI.Switch.EVENT_CHANGE = "EVENT_CHANGE"; |
|
|
|
|
BI.shortcut("bi.switch", BI.Switch);/** |
|
|
|
|
* guy |
|
|
|
|
* 复选框item |
|
|
|
|
* @type {*|void|Object} |
|
|
|
|
*/ |
|
|
|
|
BI.FirstTreeLeafItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
BI.shortcut("bi.switch", BI.Switch);BI.FirstTreeLeafItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
return BI.extend(BI.FirstTreeLeafItem.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
|
extraCls: "bi-first-tree-leaf-item bi-list-item-active", |
|
|
|
@ -53169,12 +53170,7 @@ BI.shortcut("bi.first_tree_leaf_item", BI.FirstTreeLeafItem);BI.IconTreeLeafItem
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
BI.shortcut("bi.icon_tree_leaf_item", BI.IconTreeLeafItem);/** |
|
|
|
|
* guy |
|
|
|
|
* 复选框item |
|
|
|
|
* @type {*|void|Object} |
|
|
|
|
*/ |
|
|
|
|
BI.LastTreeLeafItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
BI.shortcut("bi.icon_tree_leaf_item", BI.IconTreeLeafItem);BI.LastTreeLeafItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
return BI.extend(BI.LastTreeLeafItem.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
|
extraCls: "bi-last-tree-leaf-item bi-list-item-active", |
|
|
|
@ -53273,12 +53269,7 @@ BI.LastTreeLeafItem = BI.inherit(BI.BasicButton, {
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
BI.shortcut("bi.last_tree_leaf_item", BI.LastTreeLeafItem);/** |
|
|
|
|
* guy |
|
|
|
|
* 复选框item |
|
|
|
|
* @type {*|void|Object} |
|
|
|
|
*/ |
|
|
|
|
BI.MidTreeLeafItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
BI.shortcut("bi.last_tree_leaf_item", BI.LastTreeLeafItem);BI.MidTreeLeafItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
return BI.extend(BI.MidTreeLeafItem.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
|
extraCls: "bi-mid-tree-leaf-item bi-list-item-active", |
|
|
|
@ -54221,16 +54212,7 @@ BI.ColorChooser = BI.inherit(BI.Widget, {
|
|
|
|
|
var fn = function () { |
|
|
|
|
var color = self.colorPicker.getValue(); |
|
|
|
|
self.trigger.setValue(color); |
|
|
|
|
var colors = BI.string2Array(BI.Cache.getItem("colors") || ""); |
|
|
|
|
var que = new BI.Queue(8); |
|
|
|
|
que.fromArray(colors); |
|
|
|
|
que.remove(color); |
|
|
|
|
que.unshift(color); |
|
|
|
|
BI.Cache.setItem("colors", BI.array2String(que.toArray())); |
|
|
|
|
}; |
|
|
|
|
this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW, function () { |
|
|
|
|
self.colorPicker.setStoreColors(BI.string2Array(BI.Cache.getItem("colors") || "")); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW, function () { |
|
|
|
|
self.fireEvent(BI.ColorChooser.EVENT_CHANGE, arguments); |
|
|
|
@ -54288,43 +54270,21 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
|
|
|
|
|
|
|
|
|
|
this.colorEditor.on(BI.ColorPickerEditor.EVENT_CHANGE, function () { |
|
|
|
|
self.setValue(this.getValue()); |
|
|
|
|
self._dealStoreColors(); |
|
|
|
|
self.fireEvent(BI.ColorChooserPopup.EVENT_VALUE_CHANGE, arguments); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
this.storeColors = BI.createWidget({ |
|
|
|
|
type: "bi.color_picker", |
|
|
|
|
cls: "bi-border-bottom bi-border-right", |
|
|
|
|
items: [[{ |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}, { |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}, { |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}, { |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}, { |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}, { |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}, { |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}, { |
|
|
|
|
value: "", |
|
|
|
|
disabled: true |
|
|
|
|
}]], |
|
|
|
|
items: [this._digestStoreColors(BI.string2Array(BI.Cache.getItem("colors") || ""))], |
|
|
|
|
width: 210, |
|
|
|
|
height: 24, |
|
|
|
|
value: o.value |
|
|
|
|
}); |
|
|
|
|
this.storeColors.on(BI.ColorPicker.EVENT_CHANGE, function () { |
|
|
|
|
self.setValue(this.getValue()[0]); |
|
|
|
|
self._dealStoreColors(); |
|
|
|
|
self.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE, arguments); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
@ -54337,6 +54297,7 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
|
|
|
|
|
|
|
|
|
|
this.colorPicker.on(BI.ColorPicker.EVENT_CHANGE, function () { |
|
|
|
|
self.setValue(this.getValue()[0]); |
|
|
|
|
self._dealStoreColors(); |
|
|
|
|
self.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE, arguments); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
@ -54384,6 +54345,7 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
|
|
|
|
|
break; |
|
|
|
|
case 1: |
|
|
|
|
self.setValue(self.customColorChooser.getValue()); |
|
|
|
|
self._dealStoreColors(); |
|
|
|
|
self.more.hideView(); |
|
|
|
|
self.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE, arguments); |
|
|
|
|
break; |
|
|
|
@ -54457,8 +54419,19 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
|
|
|
|
|
this.mask.setVisible(!enable); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
setStoreColors: function (colors) { |
|
|
|
|
if (BI.isArray(colors)) { |
|
|
|
|
_dealStoreColors: function () { |
|
|
|
|
var color = this.getValue(); |
|
|
|
|
var colors = BI.string2Array(BI.Cache.getItem("colors") || ""); |
|
|
|
|
var que = new BI.Queue(8); |
|
|
|
|
que.fromArray(colors); |
|
|
|
|
que.remove(color); |
|
|
|
|
que.unshift(color); |
|
|
|
|
var array = que.toArray(); |
|
|
|
|
BI.Cache.setItem("colors", BI.array2String(array)); |
|
|
|
|
this.setStoreColors(array); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
_digestStoreColors: function (colors) { |
|
|
|
|
var items = BI.map(colors, function (i, color) { |
|
|
|
|
return { |
|
|
|
|
value: color |
|
|
|
@ -54470,7 +54443,12 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
|
|
|
|
|
disabled: true |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
this.storeColors.populate([items]); |
|
|
|
|
return items; |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
setStoreColors: function (colors) { |
|
|
|
|
if (BI.isArray(colors)) { |
|
|
|
|
this.storeColors.populate([this._digestStoreColors(colors)]); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
@ -56450,7 +56428,12 @@ BI.shortcut("bi.icon_text_value_combo", BI.IconTextValueCombo);
|
|
|
|
|
BI.IconTextValueComboPopup = BI.inherit(BI.Pane, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
return BI.extend(BI.IconTextValueComboPopup.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
|
baseCls: "bi-icon-text-icon-popup" |
|
|
|
|
baseCls: "bi-icon-text-icon-popup", |
|
|
|
|
behaviors: { |
|
|
|
|
redmark: function () { |
|
|
|
|
return true; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
@ -56470,11 +56453,7 @@ BI.IconTextValueComboPopup = BI.inherit(BI.Pane, {
|
|
|
|
|
layouts: [{ |
|
|
|
|
type: "bi.vertical" |
|
|
|
|
}], |
|
|
|
|
behaviors: { |
|
|
|
|
redmark: function () { |
|
|
|
|
return true; |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
behaviors: o.behaviors, |
|
|
|
|
value: o.value |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
@ -60072,6 +60051,7 @@ BI.AllCountPager = BI.inherit(BI.Widget, {
|
|
|
|
|
this.options.pages = v; |
|
|
|
|
this.pager.setAllPages(v); |
|
|
|
|
this.editor.setEnable(v >= 1); |
|
|
|
|
this.setPagerVisible(v > 1); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
setValue: function (v) { |
|
|
|
@ -63772,7 +63752,7 @@ BI.shortcut("bi.down_list_item", BI.DownListItem);BI.DownListGroupItem = BI.inhe
|
|
|
|
|
type: "bi.icon_button", |
|
|
|
|
cls: o.iconCls1, |
|
|
|
|
width: 36, |
|
|
|
|
forceNotSelected: true, |
|
|
|
|
disableSelected: true, |
|
|
|
|
selected: this._digest(o.value) |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
@ -64142,11 +64122,7 @@ BI.DownListPopup = BI.inherit(BI.Pane, {
|
|
|
|
|
|
|
|
|
|
BI.DownListPopup.EVENT_CHANGE = "EVENT_CHANGE"; |
|
|
|
|
BI.DownListPopup.EVENT_SON_VALUE_CHANGE = "EVENT_SON_VALUE_CHANGE"; |
|
|
|
|
BI.shortcut("bi.down_list_popup", BI.DownListPopup);/** |
|
|
|
|
* 汇总表格帮助类 |
|
|
|
|
* Created by Young's on 2017/1/19. |
|
|
|
|
*/ |
|
|
|
|
!(function () { |
|
|
|
|
BI.shortcut("bi.down_list_popup", BI.DownListPopup);!(function () { |
|
|
|
|
BI.DynamicDateHelper = {}; |
|
|
|
|
BI.extend(BI.DynamicDateHelper, { |
|
|
|
|
getCalculation: function (obj) { |
|
|
|
@ -68568,7 +68544,8 @@ BI.MultiLayerSelectTreeCombo = BI.inherit(BI.Widget, {
|
|
|
|
|
}] |
|
|
|
|
}, |
|
|
|
|
value: o.value, |
|
|
|
|
maxHeight: 400 |
|
|
|
|
maxHeight: 400, |
|
|
|
|
minHeight: 240 |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
@ -68664,7 +68641,7 @@ BI.shortcut("bi.multilayer_select_tree_combo", BI.MultiLayerSelectTreeCombo);/**
|
|
|
|
|
* guy |
|
|
|
|
* 二级树 |
|
|
|
|
* @class BI.MultiLayerSelectLevelTree |
|
|
|
|
* @extends BI.Select |
|
|
|
|
* @extends BI.Pane |
|
|
|
|
*/ |
|
|
|
|
BI.MultiLayerSelectLevelTree = BI.inherit(BI.Pane, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
@ -68773,9 +68750,9 @@ BI.MultiLayerSelectLevelTree = BI.inherit(BI.Pane, {
|
|
|
|
|
el: { |
|
|
|
|
type: "bi.loader", |
|
|
|
|
isDefaultInit: o.itemsCreator !== BI.emptyFn, |
|
|
|
|
chooseType: o.chooseType, |
|
|
|
|
el: { |
|
|
|
|
type: "bi.button_tree", |
|
|
|
|
chooseType: o.chooseType, |
|
|
|
|
behaviors: o.behaviors, |
|
|
|
|
layouts: [{ |
|
|
|
|
type: "bi.vertical" |
|
|
|
@ -68812,8 +68789,12 @@ BI.MultiLayerSelectLevelTree = BI.inherit(BI.Pane, {
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
setValue: function (v) { |
|
|
|
|
// getValue依赖于storeValue, 那么不选的时候就不要更新storeValue了
|
|
|
|
|
if(this.options.chooseType === BI.Selection.None) { |
|
|
|
|
} else { |
|
|
|
|
this.storeValue = v; |
|
|
|
|
this.tree.setValue(v); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
getValue: function () { |
|
|
|
@ -69537,7 +69518,8 @@ BI.MultiLayerSingleTreeCombo = BI.inherit(BI.Widget, {
|
|
|
|
|
}] |
|
|
|
|
}, |
|
|
|
|
value: o.value, |
|
|
|
|
maxHeight: 400 |
|
|
|
|
maxHeight: 400, |
|
|
|
|
minHeight: 240 |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
@ -69741,9 +69723,9 @@ BI.MultiLayerSingleLevelTree = BI.inherit(BI.Pane, {
|
|
|
|
|
el: { |
|
|
|
|
type: "bi.loader", |
|
|
|
|
isDefaultInit: o.itemsCreator !== BI.emptyFn, |
|
|
|
|
chooseType: o.chooseType, |
|
|
|
|
el: { |
|
|
|
|
type: "bi.button_tree", |
|
|
|
|
chooseType: o.chooseType, |
|
|
|
|
behaviors: o.behaviors, |
|
|
|
|
layouts: [{ |
|
|
|
|
type: "bi.vertical" |
|
|
|
@ -69780,8 +69762,12 @@ BI.MultiLayerSingleLevelTree = BI.inherit(BI.Pane, {
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
setValue: function (v) { |
|
|
|
|
// getValue依赖于storeValue, 那么不选的时候就不要更新storeValue了
|
|
|
|
|
if(this.options.chooseType === BI.Selection.None) { |
|
|
|
|
} else { |
|
|
|
|
this.storeValue = v; |
|
|
|
|
this.tree.setValue(v); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
getValue: function () { |
|
|
|
@ -71031,7 +71017,9 @@ BI.MultiSelectCombo = BI.inherit(BI.Single, {
|
|
|
|
|
self.fireEvent(BI.MultiSelectCombo.EVENT_CLICK_ITEM); |
|
|
|
|
}); |
|
|
|
|
this.trigger.on(BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW, function () { |
|
|
|
|
this.getCounter().setValue(self.storeValue); |
|
|
|
|
// counter的值随点击项的改变而改变, 点击counter的时候不需要setValue(counter会请求刷新计数)
|
|
|
|
|
// 只需要更新查看面板的selectedValue用以请求已选数据
|
|
|
|
|
this.getCounter().updateSelectedValue(self.storeValue); |
|
|
|
|
}); |
|
|
|
|
this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK, function () { |
|
|
|
|
if (!self.combo.isViewVisible()) { |
|
|
|
@ -71409,7 +71397,9 @@ BI.MultiSelectInsertCombo = BI.inherit(BI.Single, {
|
|
|
|
|
self.fireEvent(BI.MultiSelectInsertCombo.EVENT_CLICK_ITEM); |
|
|
|
|
}); |
|
|
|
|
this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW, function () { |
|
|
|
|
this.getCounter().setValue(self.storeValue); |
|
|
|
|
// counter的值随点击项的改变而改变, 点击counter的时候不需要setValue(counter会请求刷新计数)
|
|
|
|
|
// 只需要更新查看面板的selectedValue用以请求已选数据
|
|
|
|
|
this.getCounter().updateSelectedValue(self.storeValue); |
|
|
|
|
}); |
|
|
|
|
this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_COUNTER_CLICK, function () { |
|
|
|
|
if (!self.combo.isViewVisible()) { |
|
|
|
@ -71804,7 +71794,9 @@ BI.MultiSelectInsertNoBarCombo = BI.inherit(BI.Single, {
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW, function () { |
|
|
|
|
this.getCounter().setValue(self.storeValue); |
|
|
|
|
// counter的值随点击项的改变而改变, 点击counter的时候不需要setValue(counter会请求刷新计数)
|
|
|
|
|
// 只需要更新查看面板的selectedValue用以请求已选数据
|
|
|
|
|
this.getCounter().updateSelectedValue(self.storeValue); |
|
|
|
|
}); |
|
|
|
|
this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_COUNTER_CLICK, function () { |
|
|
|
|
if (!self.combo.isViewVisible()) { |
|
|
|
@ -73955,6 +73947,9 @@ BI.MultiSelectCheckSelectedSwitcher = BI.inherit(BI.Widget, {
|
|
|
|
|
onClickContinueSelect: function () { |
|
|
|
|
self.switcher.hideView(); |
|
|
|
|
}, |
|
|
|
|
ref: function (_ref) { |
|
|
|
|
self.checkPane = _ref; |
|
|
|
|
}, |
|
|
|
|
value: o.value |
|
|
|
|
}, o.popup), |
|
|
|
|
adapter: o.adapter, |
|
|
|
@ -73995,6 +73990,11 @@ BI.MultiSelectCheckSelectedSwitcher = BI.inherit(BI.Widget, {
|
|
|
|
|
this.switcher.setValue(v); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
// 与setValue的区别是只更新查看已选面板的的selectedValue, 不会更新按钮的计数
|
|
|
|
|
updateSelectedValue: function (v) { |
|
|
|
|
this.checkPane.setValue(v); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
setButtonChecked: function (v) { |
|
|
|
|
this.button.setValue(v); |
|
|
|
|
}, |
|
|
|
@ -80644,12 +80644,7 @@ BI.SingleSelectInsertCombo.EVENT_SEARCHING = "EVENT_SEARCHING";
|
|
|
|
|
BI.SingleSelectInsertCombo.EVENT_CLICK_ITEM = "EVENT_CLICK_ITEM"; |
|
|
|
|
BI.SingleSelectInsertCombo.EVENT_CONFIRM = "EVENT_CONFIRM"; |
|
|
|
|
|
|
|
|
|
BI.shortcut("bi.single_select_insert_combo", BI.SingleSelectInsertCombo);/** |
|
|
|
|
* guy |
|
|
|
|
* 单选框item |
|
|
|
|
* @type {*|void|Object} |
|
|
|
|
*/ |
|
|
|
|
BI.SingleSelectComboItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
BI.shortcut("bi.single_select_insert_combo", BI.SingleSelectInsertCombo);BI.SingleSelectComboItem = BI.inherit(BI.BasicButton, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
return BI.extend(BI.SingleSelectComboItem.superclass._defaultConfig.apply(this, arguments), { |
|
|
|
|
extraCls: "bi-single-select-radio-item", |
|
|
|
@ -81724,9 +81719,6 @@ BI.SingleSelectSearcher.EVENT_STOP = "EVENT_STOP";
|
|
|
|
|
BI.SingleSelectSearcher.EVENT_PAUSE = "EVENT_PAUSE"; |
|
|
|
|
BI.SingleSelectSearcher.EVENT_SEARCHING = "EVENT_SEARCHING"; |
|
|
|
|
BI.shortcut("bi.single_select_searcher", BI.SingleSelectSearcher); |
|
|
|
|
/** |
|
|
|
|
* Created by User on 2017/11/16. |
|
|
|
|
*/ |
|
|
|
|
BI.SignTextEditor = BI.inherit(BI.Widget, { |
|
|
|
|
_defaultConfig: function () { |
|
|
|
|
var conf = BI.SignTextEditor.superclass._defaultConfig.apply(this, arguments); |
|
|
|
@ -84806,7 +84798,7 @@ BI.DynamicYearTrigger.EVENT_START = "EVENT_START";
|
|
|
|
|
BI.DynamicYearTrigger.EVENT_CONFIRM = "EVENT_CONFIRM"; |
|
|
|
|
BI.DynamicYearTrigger.EVENT_STOP = "EVENT_STOP"; |
|
|
|
|
BI.shortcut("bi.dynamic_year_trigger", BI.DynamicYearTrigger);/** |
|
|
|
|
* 年份展示面板 |
|
|
|
|
* 年月展示面板 |
|
|
|
|
* |
|
|
|
|
* Created by GUY on 2015/9/2. |
|
|
|
|
* @class BI.YearCard |
|
|
|
@ -85842,7 +85834,7 @@ BI.YearMonthInterval.EVENT_CHANGE = "EVENT_CHANGE";
|
|
|
|
|
BI.YearMonthInterval.EVENT_BEFORE_POPUPVIEW = "EVENT_BEFORE_POPUPVIEW"; |
|
|
|
|
BI.shortcut("bi.year_month_interval", BI.YearMonthInterval); |
|
|
|
|
/** |
|
|
|
|
* 年份展示面板 |
|
|
|
|
* 年季度展示面板 |
|
|
|
|
* |
|
|
|
|
* Created by GUY on 2015/9/2. |
|
|
|
|
* @class BI.YearCard |
|
|
|
@ -86669,30 +86661,33 @@ BI.AbstractAllValueChooser = BI.inherit(BI.Widget, {
|
|
|
|
|
if (options.keyword) { |
|
|
|
|
keywords.push(options.keyword); |
|
|
|
|
} |
|
|
|
|
var resultItems = []; |
|
|
|
|
var resultItems = items; |
|
|
|
|
if(BI.isNotEmptyArray(keywords)) { |
|
|
|
|
resultItems = []; |
|
|
|
|
BI.each(keywords, function (i, kw) { |
|
|
|
|
var search = BI.Func.getSearchResult(items, kw); |
|
|
|
|
resultItems = resultItems.concat(search.match).concat(search.find); |
|
|
|
|
}); |
|
|
|
|
resultItems = BI.uniq(resultItems); |
|
|
|
|
} |
|
|
|
|
if (options.selectedValues) {// 过滤
|
|
|
|
|
var filter = BI.makeObject(options.selectedValues, true); |
|
|
|
|
items = BI.filter(items, function (i, ob) { |
|
|
|
|
resultItems = BI.filter(resultItems, function (i, ob) { |
|
|
|
|
return !filter[ob.value]; |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
if (options.type === BI.MultiSelectCombo.REQ_GET_ALL_DATA) { |
|
|
|
|
callback({ |
|
|
|
|
items: items |
|
|
|
|
items: resultItems |
|
|
|
|
}); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
if (options.type === BI.MultiSelectCombo.REQ_GET_DATA_LENGTH) { |
|
|
|
|
callback({count: items.length}); |
|
|
|
|
callback({count: resultItems.length}); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
callback({ |
|
|
|
|
items: items, |
|
|
|
|
items: resultItems, |
|
|
|
|
hasNext: false |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
@ -86766,7 +86761,7 @@ BI.AllValueChooserCombo = BI.inherit(BI.AbstractAllValueChooser, {
|
|
|
|
|
}); |
|
|
|
|
BI.AllValueChooserCombo.EVENT_CONFIRM = "EVENT_CONFIRM"; |
|
|
|
|
BI.shortcut("bi.all_value_chooser_combo", BI.AllValueChooserCombo);/** |
|
|
|
|
* 简单的复选下拉框控件, 适用于数据量少的情况, 与valuechooser的区别是allvaluechooser setValue和getValue返回的是所有值 |
|
|
|
|
* 简单的复选面板, 适用于数据量少的情况, 与valuechooser的区别是allvaluechooser setValue和getValue返回的是所有值 |
|
|
|
|
* 封装了字段处理逻辑 |
|
|
|
|
* |
|
|
|
|
* Created by GUY on 2015/10/29. |
|
|
|
@ -88025,7 +88020,7 @@ BI.TreeValueChooserCombo = BI.inherit(BI.AbstractTreeValueChooser, {
|
|
|
|
|
}); |
|
|
|
|
BI.TreeValueChooserCombo.EVENT_CONFIRM = "EVENT_CONFIRM"; |
|
|
|
|
BI.shortcut("bi.tree_value_chooser_combo", BI.TreeValueChooserCombo);/** |
|
|
|
|
* 简单的复选下拉树控件, 适用于数据量少的情况 |
|
|
|
|
* 简单的树面板, 适用于数据量少的情况 |
|
|
|
|
* |
|
|
|
|
* Created by GUY on 2015/10/29. |
|
|
|
|
* @class BI.TreeValueChooserPane |
|
|
|
@ -88136,29 +88131,34 @@ BI.AbstractValueChooser = BI.inherit(BI.Widget, {
|
|
|
|
|
} |
|
|
|
|
function call (items) { |
|
|
|
|
var keywords = (options.keywords || []).slice(); |
|
|
|
|
var resultItems = items; |
|
|
|
|
if(BI.isNotEmptyArray(keywords)) { |
|
|
|
|
resultItems = []; |
|
|
|
|
BI.each(keywords, function (i, kw) { |
|
|
|
|
var search = BI.Func.getSearchResult(items, kw); |
|
|
|
|
items = search.match.concat(search.find); |
|
|
|
|
resultItems = resultItems.concat(search.match).concat(search.find); |
|
|
|
|
}); |
|
|
|
|
resultItems = BI.uniq(resultItems); |
|
|
|
|
} |
|
|
|
|
if (options.selectedValues) {// 过滤
|
|
|
|
|
var filter = BI.makeObject(options.selectedValues, true); |
|
|
|
|
items = BI.filter(items, function (i, ob) { |
|
|
|
|
resultItems = BI.filter(resultItems, function (i, ob) { |
|
|
|
|
return !filter[ob.value]; |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
if (options.type === BI.MultiSelectCombo.REQ_GET_ALL_DATA) { |
|
|
|
|
callback({ |
|
|
|
|
items: items |
|
|
|
|
items: resultItems |
|
|
|
|
}); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
if (options.type === BI.MultiSelectCombo.REQ_GET_DATA_LENGTH) { |
|
|
|
|
callback({count: items.length}); |
|
|
|
|
callback({count: resultItems.length}); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
callback({ |
|
|
|
|
items: self._getItemsByTimes(items, options.times), |
|
|
|
|
hasNext: self._hasNextByTimes(items, options.times) |
|
|
|
|
items: self._getItemsByTimes(resultItems, options.times), |
|
|
|
|
hasNext: self._hasNextByTimes(resultItems, options.times) |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
@ -88224,7 +88224,7 @@ BI.ValueChooserCombo = BI.inherit(BI.AbstractValueChooser, {
|
|
|
|
|
}); |
|
|
|
|
BI.ValueChooserCombo.EVENT_CONFIRM = "EVENT_CONFIRM"; |
|
|
|
|
BI.shortcut("bi.value_chooser_combo", BI.ValueChooserCombo);/** |
|
|
|
|
* 简单的复选下拉框控件, 适用于数据量少的情况 |
|
|
|
|
* 简单的复选面板, 适用于数据量少的情况 |
|
|
|
|
* 封装了字段处理逻辑 |
|
|
|
|
* |
|
|
|
|
* Created by GUY on 2015/10/29. |
|
|
|
@ -88411,18 +88411,12 @@ BI.shortcut("bi.value_chooser_pane", BI.ValueChooserPane);;(function () {
|
|
|
|
|
return needPop; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
BI.Widget.prototype._init = function () { |
|
|
|
|
BI.Widget.superclass._init.apply(this, arguments); |
|
|
|
|
this._initRoot(); |
|
|
|
|
this._initElementWidth(); |
|
|
|
|
this._initElementHeight(); |
|
|
|
|
this._initVisual(); |
|
|
|
|
this._initState(); |
|
|
|
|
BI.Widget.prototype._initRender = function () { |
|
|
|
|
if (this.beforeInit) { |
|
|
|
|
this.__asking = true; |
|
|
|
|
this.beforeInit(BI.bind(function () { |
|
|
|
|
if (this.model && this.model.$vm) { |
|
|
|
|
this.model.$vm.$digest() |
|
|
|
|
this.model.$vm.$digest(); |
|
|
|
|
} |
|
|
|
|
this._render(); |
|
|
|
|
}, this)); |
|
|
|
@ -88432,7 +88426,7 @@ BI.shortcut("bi.value_chooser_pane", BI.ValueChooserPane);;(function () {
|
|
|
|
|
} else { |
|
|
|
|
this._render(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
var _init = BI.Widget.prototype._init; |
|
|
|
|
BI.Widget.prototype._init = function () { |
|
|
|
|