一個增加數,一個減少數,隨便輸入其中一個另外一個都會自動輸入
{
xtype: 'textfield',
id: 'IncreaseId',
fieldLabel: '增?加¨®數ºy<span style="color: red;" >*</span>',
regex: /^[0-9]*$/,
regexText: '請?輸º?入¨?整?數ºy',
width: 400,
name: 'IncreaseNumber',
allowBlank: false,
maxLength: 10,
maxLengthText: '輸º?入¨?過y長¡è',
onBlur: function () {
var thisForm = this.up('form');
var increaseNumberValue = thisForm.getForm().findField('IncreaseId').getValue();
thisForm.getForm().findField('ReduceId').setValue(increaseNumberValue);
}
}
, {
xtype: 'textfield',
fieldLabel: '減?少¦¨´數ºy<span style="color: red;" >*</span>',
id: 'ReduceId',
regex: /^[0-9]*$/,
regexText: '請?輸º?入¨?整?數ºy',
width: 400,
name: 'ReduceNumber',
allowBlank: false,
maxLength: 10,
maxLengthText: '輸º?入¨?過y長¡è',
onBlur: function () {
var thisForm = this.up('form');
var reduceNumberValue = thisForm.getForm().findField('ReduceId').getValue();
thisForm.getForm().findField('IncreaseId').setValue(reduceNumberValue);
}
},