Browse Source

Merge pull request #214881 in DEC/fineui from master to feature/x

* commit 'f66d2f4430acbedd45265631c134e0423b4389e5':
  auto upgrade version to 2.0.20221230161545
  ESIGN-110 feat: 反馈-tooltip
  BI-119217 fix: 【6.0.6冒烟】等比自适应-高清屏-宽度自适应预览,下拉树查看已选展示异常
  JSY-25726 fix: 【冒烟】年季度/年月/年月区间筛选器,输入非法值后清空,设置框仍然标红
master
superman 2 years ago
parent
commit
eb1ee79c3b
  1. 3
      bi.lessconfig.json
  2. 2
      package.json
  3. 2
      src/core/platform/web/dom.js
  4. 120
      src/widget/yearmonth/combo.yearmonth.js
  5. 122
      src/widget/yearquarter/combo.yearquarter.js

3
bi.lessconfig.json

@ -29,7 +29,8 @@
"@color-bi-background-disabled-active-radio-content-theme-dark": "#606479",
"@color-bi-background-disabled-active-checkbox-content": "#FFFFFF",
"@color-bi-background-disabled-active-checkbox-content-theme-dark": "#606479",
"@color-bi-background-tooltip-success": "#2E3A4D",
"@color-bi-background-tooltip-success": "#3F506A",
"@color-bi-background-tooltip-failure": "#E65251",
"@color-bi-border-tooltip-success": "#2E3A4D",
"@color-bi-background-toast-success": "#FFFFFF",
"@color-bi-background-toast-warning": "#FFFFFF",

2
package.json

@ -1,6 +1,6 @@
{
"name": "fineui",
"version": "2.0.20221230101648",
"version": "2.0.20221230161545",
"description": "fineui",
"main": "dist/fineui_without_conflict.min.js",
"types": "dist/lib/index.d.ts",

2
src/core/platform/web/dom.js

@ -710,7 +710,7 @@
break;
}
if (needAdaptHeight === true) {
popup.resetHeight && popup.resetHeight(Math.min(viewportBounds.height - position.top + (positionRelativeElement ? positionRelativeElement.getBoundingClientRect().top : 0), maxHeight));
popup.resetHeight && popup.resetHeight(Math.min(viewportBounds.height - position.top - (positionRelativeElement ? positionRelativeElement.getBoundingClientRect().top : 0), maxHeight));
}
return position;
},

120
src/widget/yearmonth/combo.yearmonth.js

@ -80,39 +80,45 @@ BI.DynamicYearMonthCombo = BI.inherit(BI.Single, {
ref: function () {
self.popup = this;
},
listeners: [{
eventName: BI.DynamicYearMonthPopup.EVENT_CHANGE,
action: function () {
self.setValue(self.popup.getValue());
self.combo.hideView();
self.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearMonthPopup.BUTTON_CLEAR_EVENT_CHANGE,
action: function () {
self.setValue();
self.combo.hideView();
self.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearMonthPopup.BUTTON_lABEL_EVENT_CHANGE,
action: function () {
var date = BI.getDate();
self.setValue({ type: BI.DynamicYearMonthCombo.Static, value: { year: date.getFullYear(), month: date.getMonth() + 1 } });
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE,
action: function () {
var value = self.popup.getValue();
if (self._checkValue(value)) {
self.setValue(value);
listeners: [
{
eventName: BI.DynamicYearMonthPopup.EVENT_CHANGE,
action: function () {
self.setValue(self.popup.getValue());
self.combo.hideView();
self.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearMonthPopup.BUTTON_CLEAR_EVENT_CHANGE,
action: function () {
self.setValue();
self.comboWrapper.element.removeClass("error");
self.combo.hideView();
self.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearMonthPopup.BUTTON_lABEL_EVENT_CHANGE,
action: function () {
var date = BI.getDate();
self.setValue({
type: BI.DynamicYearMonthCombo.Static,
value: { year: date.getFullYear(), month: date.getMonth() + 1 }
});
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE,
action: function () {
var value = self.popup.getValue();
if (self._checkValue(value)) {
self.setValue(value);
}
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
}],
],
behaviors: o.behaviors,
min: o.minDate,
max: o.maxDate
@ -130,31 +136,35 @@ BI.DynamicYearMonthCombo = BI.inherit(BI.Single, {
BI.createWidget({
type: "bi.absolute",
element: this,
items: [{
el: {
type: "bi.horizontal_fill",
columnSize: ["", "fill"],
cls: (o.simple ? "bi-border-bottom" : "bi-border bi-border-radius") + " bi-focus-shadow",
ref: function () {
self.comboWrapper = this;
items: [
{
el: {
type: "bi.horizontal_fill",
columnSize: ["", "fill"],
cls: (o.simple ? "bi-border-bottom" : "bi-border bi-border-radius") + " bi-focus-shadow",
ref: function () {
self.comboWrapper = this;
},
items: [
{
el: {
type: "bi.icon_button",
cls: "bi-trigger-icon-button date-change-h-font",
width: BI.toPix(o.height, border),
height: BI.toPix(o.height, border),
ref: function () {
self.changeIcon = this;
}
}
}, this.combo
]
},
items: [{
el: {
type: "bi.icon_button",
cls: "bi-trigger-icon-button date-change-h-font",
width: BI.toPix(o.height, border),
height: BI.toPix(o.height, border),
ref: function () {
self.changeIcon = this;
}
}
}, this.combo]
},
top: 0,
left: 0,
right: 0,
bottom: 0
}]
top: 0,
left: 0,
right: 0,
bottom: 0
}
]
});
this._checkDynamicValue(o.value);
},

122
src/widget/yearquarter/combo.yearquarter.js

@ -1,6 +1,6 @@
BI.DynamicYearQuarterCombo = BI.inherit(BI.Widget, {
_consts:{
_consts: {
iconWidth: 24
},
props: {
@ -83,39 +83,45 @@ BI.DynamicYearQuarterCombo = BI.inherit(BI.Widget, {
ref: function () {
self.popup = this;
},
listeners: [{
eventName: BI.DynamicYearQuarterPopup.EVENT_CHANGE,
action: function () {
self.setValue(self.popup.getValue());
self.combo.hideView();
self.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearQuarterPopup.BUTTON_CLEAR_EVENT_CHANGE,
action: function () {
self.setValue();
self.combo.hideView();
self.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearQuarterPopup.BUTTON_lABEL_EVENT_CHANGE,
action: function () {
var date = BI.getDate();
self.setValue({ type: BI.DynamicYearMonthCombo.Static, value: { year: date.getFullYear(), quarter: BI.getQuarter(date) } });
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearQuarterPopup.BUTTON_OK_EVENT_CHANGE,
action: function () {
var value = self.popup.getValue();
if (self._checkValue(value)) {
self.setValue(value);
listeners: [
{
eventName: BI.DynamicYearQuarterPopup.EVENT_CHANGE,
action: function () {
self.setValue(self.popup.getValue());
self.combo.hideView();
self.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearQuarterPopup.BUTTON_CLEAR_EVENT_CHANGE,
action: function () {
self.setValue();
self.comboWrapper.element.removeClass("error");
self.combo.hideView();
self.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearQuarterPopup.BUTTON_lABEL_EVENT_CHANGE,
action: function () {
var date = BI.getDate();
self.setValue({
type: BI.DynamicYearMonthCombo.Static,
value: { year: date.getFullYear(), quarter: BI.getQuarter(date) }
});
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
}, {
eventName: BI.DynamicYearQuarterPopup.BUTTON_OK_EVENT_CHANGE,
action: function () {
var value = self.popup.getValue();
if (self._checkValue(value)) {
self.setValue(value);
}
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
self.combo.hideView();
self.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM);
}
}],
],
behaviors: o.behaviors,
min: o.minDate,
max: o.maxDate
@ -133,31 +139,35 @@ BI.DynamicYearQuarterCombo = BI.inherit(BI.Widget, {
BI.createWidget({
type: "bi.absolute",
element: this,
items: [{
el: {
type: "bi.horizontal_fill",
columnSize: ["", "fill"],
cls: (o.simple ? "bi-border-bottom" : "bi-border bi-border-radius") + " bi-focus-shadow",
ref: function () {
self.comboWrapper = this;
items: [
{
el: {
type: "bi.horizontal_fill",
columnSize: ["", "fill"],
cls: (o.simple ? "bi-border-bottom" : "bi-border bi-border-radius") + " bi-focus-shadow",
ref: function () {
self.comboWrapper = this;
},
items: [
{
el: {
type: "bi.icon_button",
cls: "bi-trigger-icon-button date-change-h-font",
width: this._consts.iconWidth,
height: BI.toPix(o.height, border),
ref: function () {
self.changeIcon = this;
}
}
}, this.combo
]
},
items: [{
el: {
type: "bi.icon_button",
cls: "bi-trigger-icon-button date-change-h-font",
width: this._consts.iconWidth,
height: BI.toPix(o.height, border),
ref: function () {
self.changeIcon = this;
}
}
}, this.combo]
},
top: 0,
left: 0,
right: 0,
bottom: 0
}]
top: 0,
left: 0,
right: 0,
bottom: 0
}
]
});
this._checkDynamicValue(o.value);
},

Loading…
Cancel
Save