From 45265ea8c10999632d62c27e9408aa66e8e63295 Mon Sep 17 00:00:00 2001 From: windy <1374721899@qq.com> Date: Tue, 8 Dec 2020 17:27:44 +0800 Subject: [PATCH] =?UTF-8?q?BI-64182=20=E6=A0=91=E6=8E=A7=E4=BB=B6trigger?= =?UTF-8?q?=E4=B8=AD=E6=98=BE=E7=A4=BA=E5=80=BC=E6=8C=89=E7=BB=9F=E4=B8=80?= =?UTF-8?q?=E7=88=B6=E8=8A=82=E7=82=B9=E4=B8=8B=E7=9A=84=E5=AD=90=E8=8A=82?= =?UTF-8?q?=E7=82=B9=E5=8D=87=E5=BA=8F=E6=8E=92=E5=88=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- changelog.md | 1 + src/case/trigger/trigger.text.js | 2 +- src/case/trigger/trigger.text.small.js | 2 +- src/widget/multitree/trigger/searcher.multi.tree.js | 5 +++-- 4 files changed, 6 insertions(+), 4 deletions(-) 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++;