|
|
@ -1,9 +1,7 @@ |
|
|
|
BI.DynamicYearTrigger = BI.inherit(BI.Trigger, { |
|
|
|
BI.DynamicYearTrigger = BI.inherit(BI.Trigger, { |
|
|
|
_const: { |
|
|
|
_const: { |
|
|
|
hgap: 4, |
|
|
|
hgap: 4, |
|
|
|
vgap: 2, |
|
|
|
vgap: 2 |
|
|
|
errorText: BI.i18nText("BI-Please_Input_Positive_Integer"), |
|
|
|
|
|
|
|
errorTextInvalid: BI.i18nText("BI-Year_Trigger_Invalid_Text") |
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_defaultConfig: function () { |
|
|
|
_defaultConfig: function () { |
|
|
@ -31,7 +29,7 @@ BI.DynamicYearTrigger = BI.inherit(BI.Trigger, { |
|
|
|
watermark: BI.i18nText("BI-Basic_Unrestricted"), |
|
|
|
watermark: BI.i18nText("BI-Basic_Unrestricted"), |
|
|
|
allowBlank: true, |
|
|
|
allowBlank: true, |
|
|
|
errorText: function (v) { |
|
|
|
errorText: function (v) { |
|
|
|
return !BI.isPositiveInteger(v) ? c.errorText : c.errorTextInvalid; |
|
|
|
return !BI.isPositiveInteger(v) ? BI.i18nText("BI-Please_Input_Positive_Integer") : BI.i18nText("BI-Year_Trigger_Invalid_Text"); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.editor.on(BI.SignEditor.EVENT_FOCUS, function () { |
|
|
|
this.editor.on(BI.SignEditor.EVENT_FOCUS, function () { |
|
|
@ -105,7 +103,7 @@ BI.DynamicYearTrigger = BI.inherit(BI.Trigger, { |
|
|
|
this.editor.setValue(dateStr); |
|
|
|
this.editor.setValue(dateStr); |
|
|
|
this.setTitle(BI.isEmptyString(text) ? dateStr : (text + ":" + dateStr)); |
|
|
|
this.setTitle(BI.isEmptyString(text) ? dateStr : (text + ":" + dateStr)); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
setValue: function (v) { |
|
|
|
setValue: function (v) { |
|
|
|
var type, value; |
|
|
|
var type, value; |
|
|
|
var date = BI.getDate(); |
|
|
|
var date = BI.getDate(); |
|
|
|