gpt4 book ai didi

javascript - Extjs : Validation for Integers

转载 作者:行者123 更新时间:2023-12-03 10:05:35 24 4
gpt4 key购买 nike

我想添加一个只能接受整数而不是小数的字段。

我尝试使用 numberfield 作为

{
xtype : 'numberfield',
fieldLabel : 'number',
}

我不想使其不可编辑

有什么办法可以做到吗?

最佳答案

请尝试设置allowDecimals在数字字段上进行配置,使其看起来像:

{
xtype : 'numberfield',
fieldLabel : 'number',
allowDecimals: false
}

关于javascript - Extjs : Validation for Integers,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30374656/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com