From 3d6b24b42d536418e9538280c48b4338f43a5748 Mon Sep 17 00:00:00 2001 From: windy <1374721899@qq.com> Date: Wed, 20 Jan 2021 09:17:01 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=97=A0JIRA=E4=BB=BB=E5=8A=A1=20export=20?= =?UTF-8?q?Tree=20Node?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- typescript/index.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/typescript/index.ts b/typescript/index.ts index dfc63d328..6d968018e 100644 --- a/typescript/index.ts +++ b/typescript/index.ts @@ -148,6 +148,7 @@ import { _utils } from './core/utils'; import { Controller } from "./core/controller/controller"; import { LayerController } from "./core/controller/controller.layer"; import { DateCalendarPopup } from "./widget/date/calendar/popup.calendar.date"; +import { Tree, Node } from "./core/utils/tree"; export interface BI extends _func, _i18n, _base, _inject, _var, _web, _utils { @@ -456,4 +457,6 @@ export { FloatCenterLayout, DynamicYearMonthPopup, DateCalendarPopup, + Tree, + Node, }; From 8bd6603934d6b692af05b8586224106459181d9f Mon Sep 17 00:00:00 2001 From: windy <1374721899@qq.com> Date: Wed, 20 Jan 2021 11:14:23 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=97=A0JIRA=E4=BB=BB=E5=8A=A1=20=E5=88=A0?= =?UTF-8?q?=E7=81=B0=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/widget/date/calendar/popup.year.js | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/src/widget/date/calendar/popup.year.js b/src/widget/date/calendar/popup.year.js index 39cac5621..7480c9d4d 100644 --- a/src/widget/date/calendar/popup.year.js +++ b/src/widget/date/calendar/popup.year.js @@ -70,9 +70,6 @@ BI.YearPopup = BI.inherit(BI.Widget, { cardCreator: BI.bind(this._createYearCalendar, this), afterCardCreated: function () { this.setValue(self.selectedYear); - var calendar = this.getSelectedCard(); - calendar && self.backBtn.setEnable(self._checkMinYearValid()); - calendar && self.preBtn.setEnable(self._checkMaxYearValid()); } }); @@ -87,22 +84,10 @@ BI.YearPopup = BI.inherit(BI.Widget, { } }, - _checkMinYearValid: function () { - var o = this.options; - return this.selectedYear > BI.parseDateTime(o.min, "%Y-%X-%d").getFullYear(); - }, - - _checkMaxYearValid: function () { - var o = this.options; - return this.selectedYear < BI.parseDateTime(o.max, "%Y-%X-%d").getFullYear(); - }, - _checkMin: function () { var calendar = this.navigation.getSelectedCard(); if (BI.isNotNull(calendar)) { calendar.setMinDate(this.options.min); - this.backBtn.setEnable(this._checkMinYearValid()); - this.preBtn.setEnable(this._checkMaxYearValid()); } }, @@ -110,8 +95,6 @@ BI.YearPopup = BI.inherit(BI.Widget, { var calendar = this.navigation.getSelectedCard(); if (BI.isNotNull(calendar)) { calendar.setMaxDate(this.options.max); - this.backBtn.setEnable(this._checkMinYearValid()); - this.preBtn.setEnable(this._checkMaxYearValid()); } },