From ba884c00b9df062232d81cd47bd9a42e7e84bb27 Mon Sep 17 00:00:00 2001 From: zsmj Date: Tue, 6 Sep 2022 10:11:03 +0800 Subject: [PATCH 1/5] =?UTF-8?q?=E6=97=A0JIRA=20=E5=8E=BB=E6=8E=89sameroute?= =?UTF-8?q?=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/router/router.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/router/router.js b/src/router/router.js index 40ca8f3c4..4a2cf0c2f 100644 --- a/src/router/router.js +++ b/src/router/router.js @@ -2326,7 +2326,7 @@ route.matched[lastRouteIndex] === current.matched[lastCurrentIndex] ) { this.ensureURL(); - return abort(createNavigationDuplicatedError(current, route)) + return; } var ref = resolveQueue( From 221e254ea1ef33cea55bace31557b239d18635d6 Mon Sep 17 00:00:00 2001 From: zsmj Date: Tue, 6 Sep 2022 13:41:38 +0800 Subject: [PATCH 2/5] =?UTF-8?q?KERNEL-12683=20feat:=20=E6=96=87=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E6=94=AF=E6=8C=81=E8=87=AA=E5=AE=9A=E4=B9=89?= =?UTF-8?q?=E6=A0=A1=E9=AA=8C=20,=20bi.file=20reset=E6=96=B9=E6=B3=95?= =?UTF-8?q?=E6=B8=85=E7=A9=BA=E5=89=8D=E4=B8=80=E6=AC=A1=E4=B8=8A=E4=BC=A0?= =?UTF-8?q?=E7=9A=84files?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/base/single/editor/editor.multifile.js | 3 ++- src/base/single/input/file.js | 13 +++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/base/single/editor/editor.multifile.js b/src/base/single/editor/editor.multifile.js index 21765474d..2be8de9d2 100644 --- a/src/base/single/editor/editor.multifile.js +++ b/src/base/single/editor/editor.multifile.js @@ -43,12 +43,14 @@ BI.MultifileEditor = BI.inherit(BI.Widget, { }); this.file.on(BI.File.EVENT_ERROR, function () { self.fireEvent(BI.MultifileEditor.EVENT_ERROR, arguments); + self._reset(); }); this.file.on(BI.File.EVENT_PROGRESS, function () { self.fireEvent(BI.MultifileEditor.EVENT_PROGRESS, arguments); }); this.file.on(BI.File.EVENT_UPLOADED, function () { self.fireEvent(BI.MultifileEditor.EVENT_UPLOADED, arguments); + self._reset(); }); BI.createWidget({ @@ -93,7 +95,6 @@ BI.MultifileEditor = BI.inherit(BI.Widget, { }, upload: function () { - this._reset(); this.file.upload(); }, diff --git a/src/base/single/input/file.js b/src/base/single/input/file.js index 290970141..a17bb4955 100644 --- a/src/base/single/input/file.js +++ b/src/base/single/input/file.js @@ -56,7 +56,7 @@ del: document.removeEventListener ? function (node, name, callback) { node.removeEventListener(name, callback, false); - + return this; } : function (node, name, callback) { @@ -113,8 +113,8 @@ if (isFunction(handler.onerror)) { handler.onerror(); } - - return; + + return; } for (var xhr = new XMLHttpRequest, upload = xhr.upload || { @@ -245,7 +245,7 @@ form.append("FileData", handler.file); xhr.send(form); } - + return handler; }; } else { @@ -298,7 +298,7 @@ handler.onload(rpe, { responseText: responseText }); } } - + try { // IE < 8 does not accept enctype attribute ... var form = document.createElement("
"), iframe = handler.iframe || (handler.iframe = document.createElement("")); @@ -353,7 +353,7 @@ }; } xhr = null; - + return sendFile; }(Object.prototype.toString)); @@ -705,6 +705,7 @@ reset: function () { if (this.wrap) { + this.wrap.files = []; this.wrap.attach_array = []; this.wrap.attach_names = []; this.wrap.attachNum = 0; From 2877f5f7c086b72a67ae9bfe94826df870158bd7 Mon Sep 17 00:00:00 2001 From: zsmj Date: Tue, 6 Sep 2022 14:02:33 +0800 Subject: [PATCH 3/5] =?UTF-8?q?Revert=20"KERNEL-12609=20fix:=20From=20FDL?= =?UTF-8?q?=20=E6=98=BE=E7=A4=BA=E6=97=A5=E5=BF=97=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E5=9C=BA=E6=99=AF,label=E9=BB=98=E8=AE=A4=E5=B8=A6=E6=9C=89too?= =?UTF-8?q?ltip=E9=80=BB=E8=BE=91=E5=AF=BC=E8=87=B4=E5=8D=A1=E9=A1=BF"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit d09bd2e3d936a884169937a69631f9b8d1b54f9d. --- src/base/single/tip/tip.tooltip.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/base/single/tip/tip.tooltip.js b/src/base/single/tip/tip.tooltip.js index 0357530e8..70c710497 100644 --- a/src/base/single/tip/tip.tooltip.js +++ b/src/base/single/tip/tip.tooltip.js @@ -25,12 +25,10 @@ BI.Tooltip = BI.inherit(BI.Tip, { render: function () { var o = this.options; this.element.addClass("tooltip-" + o.level); - function fn(e) { o.stopPropagation && e.stopPropagation(); o.stopEvent && e.stopEvent(); } - this.element.bind({ click: fn, mousedown: fn, @@ -50,7 +48,7 @@ BI.Tooltip = BI.inherit(BI.Tip, { innerVgap: this._const.vgap, items: BI.map(texts, function (i, text) { return { - type: "bi.text", + type: "bi.label", textAlign: o.textAlign, whiteSpace: "normal", text: text, @@ -60,7 +58,7 @@ BI.Tooltip = BI.inherit(BI.Tip, { }); } else { this.text = BI.createWidget({ - type: "bi.text", + type: "bi.label", element: this, textAlign: o.textAlign, whiteSpace: "normal", From 19cf7ccc1ebd5043c5ad3af12965ac82e7dbc79e Mon Sep 17 00:00:00 2001 From: zsmj Date: Tue, 6 Sep 2022 14:04:13 +0800 Subject: [PATCH 4/5] =?UTF-8?q?KERNEL-12609=20fix:=20From=20FDL=20?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E6=97=A5=E5=BF=97=E4=BF=A1=E6=81=AF=E5=9C=BA?= =?UTF-8?q?=E6=99=AF,label=E9=BB=98=E8=AE=A4=E5=B8=A6=E6=9C=89tooltip?= =?UTF-8?q?=E9=80=BB=E8=BE=91=E5=AF=BC=E8=87=B4=E5=8D=A1=E9=A1=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/base/single/tip/tip.tooltip.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/base/single/tip/tip.tooltip.js b/src/base/single/tip/tip.tooltip.js index 70c710497..eadbd05e9 100644 --- a/src/base/single/tip/tip.tooltip.js +++ b/src/base/single/tip/tip.tooltip.js @@ -53,6 +53,7 @@ BI.Tooltip = BI.inherit(BI.Tip, { whiteSpace: "normal", text: text, textHeight: 18, + title: null, }; }), }); @@ -63,6 +64,7 @@ BI.Tooltip = BI.inherit(BI.Tip, { textAlign: o.textAlign, whiteSpace: "normal", text: o.text, + title: null, textHeight: 18, hgap: this._const.hgap, vgap: this._const.vgap, From 1bd7c58af00cd72a770ab5e36fe8c2aa12e9c086 Mon Sep 17 00:00:00 2001 From: zsmj Date: Tue, 6 Sep 2022 14:18:40 +0800 Subject: [PATCH 5/5] =?UTF-8?q?KERNEL-11911=20feat:=20label=E7=BB=84?= =?UTF-8?q?=E4=BB=B6=E9=BB=98=E8=AE=A4=E4=BD=BF=E7=94=A8text=E4=BD=9C?= =?UTF-8?q?=E4=B8=BAtooltip,=E4=BB=85=E5=AF=B9label=E7=94=9F=E6=95=88,?= =?UTF-8?q?=E4=B8=8D=E5=BD=B1=E5=93=8Dhtml=5Flabel?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/base/single/label/abstract.label.js | 17 ----------------- src/base/single/label/label.js | 17 +++++++++++++++++ 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/src/base/single/label/abstract.label.js b/src/base/single/label/abstract.label.js index c0443b39d..ab67a671a 100644 --- a/src/base/single/label/abstract.label.js +++ b/src/base/single/label/abstract.label.js @@ -24,23 +24,6 @@ }); }, - getTitle: function () { - var title = this.options.title; - var text = this.options.text; - if (BI.isFunction(title)) { - return title(); - } - if (BI.isNotNull(title)) { - return title; - } - - if (BI.isFunction(text)) { - return text(); - } - - return text; - }, - _createJson: function () { var o = this.options; diff --git a/src/base/single/label/label.js b/src/base/single/label/label.js index 98bfa3707..905efd29a 100644 --- a/src/base/single/label/label.js +++ b/src/base/single/label/label.js @@ -10,6 +10,23 @@ BI.Label = BI.inherit(BI.AbstractLabel, { keyword: "", }, + getTitle: function () { + var title = this.options.title; + var text = this.options.text; + if (BI.isFunction(title)) { + return title(); + } + if (BI.isNotNull(title)) { + return title; + } + + if (BI.isFunction(text)) { + return text(); + } + + return text; + }, + doRedMark: function () { this.text.doRedMark.apply(this.text, arguments); },