extjs 可编辑numberfield 控制小数位数

Ext.create( 'Ext.form.Panel' , {
     renderTo: Ext.getBody(),
     items: [{
         xtype:  'numberfield' ,
         allowDecimals:  true ,
         //这里允许保留3位小数,所以你输入11.996就不会进位了
         decimalPrecision: 3
     }]
});

猜你喜欢

转载自blog.csdn.net/phperguan/article/details/47807017