Browse Source

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

* commit '357f5cef05ffce8447c740156bf985d9b6e7dab0':
  无jira editor自适应
  无JIRA: sign_editor自适应
  BI-107080 fix: 【6.0三轮回归】只有时间过滤组件无限制的时候悬浮无tooltip
master
superman 2 years ago
parent
commit
314510c598
  1. 24
      src/case/editor/editor.shelter.js
  2. 24
      src/case/editor/editor.sign.js
  3. 24
      src/case/editor/editor.state.js
  4. 3
      src/widget/dynamicdate/dynamicdate.trigger.js
  5. 12
      src/widget/dynamicdatetime/dynamicdatetime.trigger.js
  6. 3
      src/widget/time/time.trigger.js
  7. 2
      src/widget/yearquarter/trigger.yearquarter.js

24
src/case/editor/editor.shelter.js

@ -58,17 +58,6 @@ BI.ShelterEditor = BI.inherit(BI.Widget, {
height: o.height,
hgap: o.hgap + 2
});
BI.createWidget({
type: "bi.absolute",
element: this,
items: [{
el: this.text,
left: 0,
right: 0,
top: 0,
bottom: 0
}]
});
this.text.on(BI.Controller.EVENT_CHANGE, function () {
arguments[2] = self;
self.fireEvent(BI.Controller.EVENT_CHANGE, arguments);
@ -134,10 +123,17 @@ BI.ShelterEditor = BI.inherit(BI.Widget, {
self.fireEvent(BI.ShelterEditor.EVENT_EMPTY, arguments);
});
BI.createWidget({
type: "bi.vertical",
scrolly: false,
type: "bi.absolute",
element: this,
items: [this.editor]
items: [
{
el: this.text,
inset: 0,
}, {
el: this.editor,
inset: 0,
}
]
});
this._showHint();
self._checkText();

24
src/case/editor/editor.sign.js

@ -68,17 +68,6 @@ BI.SignEditor = BI.inherit(BI.Widget, {
self.fireEvent(BI.SignEditor.EVENT_CLICK_LABEL);
});
});
BI.createWidget({
type: "bi.absolute",
element: this,
items: [{
el: this.text,
left: 0,
right: 0,
top: 0,
bottom: 0
}]
});
this.editor.on(BI.Controller.EVENT_CHANGE, function () {
self.fireEvent(BI.Controller.EVENT_CHANGE, arguments);
});
@ -137,10 +126,17 @@ BI.SignEditor = BI.inherit(BI.Widget, {
self.fireEvent(BI.SignEditor.EVENT_EMPTY, arguments);
});
BI.createWidget({
type: "bi.vertical",
scrolly: false,
type: "bi.absolute",
element: this,
items: [this.editor]
items: [
{
el: this.text,
inset: 0,
}, {
el: this.editor,
inset: 0,
}
]
});
this._showHint();
self._checkText();

24
src/case/editor/editor.state.js

@ -77,17 +77,6 @@ BI.StateEditor = BI.inherit(BI.Widget, {
self.fireEvent(BI.StateEditor.EVENT_CLICK_LABEL);
});
});
BI.createWidget({
type: "bi.absolute",
element: this,
items: [{
el: this.text,
left: 0,
right: 0,
top: 0,
bottom: 0
}]
});
this.editor.on(BI.Controller.EVENT_CHANGE, function () {
self.fireEvent(BI.Controller.EVENT_CHANGE, arguments);
});
@ -143,10 +132,17 @@ BI.StateEditor = BI.inherit(BI.Widget, {
self.fireEvent(BI.StateEditor.EVENT_EMPTY, arguments);
});
BI.createWidget({
type: "bi.vertical",
scrolly: false,
type: "bi.absolute",
element: this,
items: [this.editor]
items: [
{
el: this.text,
inset: 0,
}, {
el: this.editor,
inset: 0,
}
]
});
this._showHint();
if (BI.isNotNull(o.text)) {

3
src/widget/dynamicdate/dynamicdate.trigger.js

@ -152,6 +152,9 @@ BI.DynamicDateTrigger = BI.inherit(BI.Trigger, {
_getTitle: function () {
var storeValue = this.storeValue || {};
if (BI.isEmptyObject(storeValue)) {
return this.options.watermark;
}
var type = storeValue.type || BI.DynamicDateCombo.Static;
var value = storeValue.value;
switch (type) {

12
src/widget/dynamicdatetime/dynamicdatetime.trigger.js

@ -9,7 +9,7 @@ BI.DynamicDateTimeTrigger = BI.inherit(BI.Trigger, {
iconWidth: 24
},
props: {
props: () => ({
extraCls: "bi-date-time-trigger",
min: "1900-01-01", // 最小日期
max: "2099-12-31", // 最大日期
@ -17,8 +17,8 @@ BI.DynamicDateTimeTrigger = BI.inherit(BI.Trigger, {
iconWidth: 24,
format: "", // 显示的日期格式化方式
allowEdit: true, // 是否允许编辑
watermark: ""
},
watermark: BI.i18nText("BI-Basic_Unrestricted"),
}),
_init: function () {
BI.DynamicDateTimeTrigger.superclass._init.apply(this, arguments);
@ -44,7 +44,7 @@ BI.DynamicDateTimeTrigger = BI.inherit(BI.Trigger, {
hgap: c.hgap,
vgap: c.vgap,
allowBlank: true,
watermark: BI.isKey(o.watermark) ? o.watermark : BI.i18nText("BI-Basic_Unrestricted"),
watermark: o.watermark,
errorText: function (v) {
var str = "";
if (!BI.isKey(o.format)) {
@ -149,7 +149,11 @@ BI.DynamicDateTimeTrigger = BI.inherit(BI.Trigger, {
},
_getTitle: function () {
var o = this.options;
var storeValue = this.storeValue || {};
if (BI.isEmptyObject(storeValue)) {
return o.watermark;
}
var type = storeValue.type || BI.DynamicDateCombo.Static;
var value = storeValue.value;
switch (type) {

3
src/widget/time/time.trigger.js

@ -157,6 +157,9 @@
_getTitle: function () {
var storeValue = this.storeValue || {};
if (BI.isEmptyObject(storeValue)) {
return this.options.watermark;
}
var date = BI.getDate();
return BI.print(BI.getDate(date.getFullYear(), 0, 1, storeValue.hour, storeValue.minute, storeValue.second), this._getFormatString());
},

2
src/widget/yearquarter/trigger.yearquarter.js

@ -249,9 +249,7 @@ BI.DynamicYearQuarterTrigger = BI.inherit(BI.Trigger, {
value = value || {};
var quarter = BI.isNull(value.quarter) ? null : value.quarter;
this.yearEditor.setValue(value.year);
this.yearEditor.setTitle(value.year);
this.quarterEditor.setValue(quarter);
this.quarterEditor.setTitle(quarter);
this.setTitle(this._getStaticTitle(value));
break;
}

Loading…
Cancel
Save