diff --git a/changelog.md b/changelog.md index f690ea64ec..cf06f448c7 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,6 @@ # 更新日志 2.0(2020-12) +- 规范了下拉树trigger中显示值的显示顺序 - bi.editor支持传入autocomplete - [视觉]editor水印间距统一与文本域水印不可选中 - 修复bi.file的url参数拼接问题 diff --git a/src/case/trigger/trigger.text.js b/src/case/trigger/trigger.text.js index 81815e2496..c1b4bdfeb4 100644 --- a/src/case/trigger/trigger.text.js +++ b/src/case/trigger/trigger.text.js @@ -7,7 +7,7 @@ */ BI.TextTrigger = BI.inherit(BI.Trigger, { _const: { - hgap: 4 + hgap: 6 }, _defaultConfig: function () { diff --git a/src/case/trigger/trigger.text.small.js b/src/case/trigger/trigger.text.small.js index cae070cfa3..1ddc3907f2 100644 --- a/src/case/trigger/trigger.text.small.js +++ b/src/case/trigger/trigger.text.small.js @@ -6,7 +6,7 @@ */ BI.SmallTextTrigger = BI.inherit(BI.Trigger, { _const: { - hgap: 4 + hgap: 6 }, _defaultConfig: function () { diff --git a/src/widget/multitree/trigger/searcher.multi.tree.js b/src/widget/multitree/trigger/searcher.multi.tree.js index 8616b10ba7..d0b9afac92 100644 --- a/src/widget/multitree/trigger/searcher.multi.tree.js +++ b/src/widget/multitree/trigger/searcher.multi.tree.js @@ -150,9 +150,10 @@ BI.MultiTreeSearcher = BI.inherit(BI.Widget, { function getChildrenNode (ob) { var text = ""; var index = 0, size = BI.size(ob); - BI.each(ob, function (name, children) { + var names = BI.Func.getSortedResult(BI.keys(ob)); + BI.each(names, function (idx, name) { index++; - var childNodes = getChildrenNode(children); + var childNodes = getChildrenNode(ob[name]); text += (o.valueFormatter(name + "") || name) + (childNodes === "" ? "" : (":" + childNodes)) + (index === size ? "" : ","); if (childNodes === "") { count++;