[英]Kendo ui empty textbox
I would like to have specific validation for kendo mumeric textbox. 我想对剑道mumeric文本框进行特定的验证。
It should be something like "amount line" on telerik demo page with a little upgrade: In demo can user completely delete amount. 稍作升级,它应该类似于telerik演示页面上的 “金额行”:在演示中,用户可以完全删除金额。 After that, if user click somewhere else, I would like to fill default value in this line - zero for example.
之后,如果用户单击其他位置,我想在此行中填充默认值-例如零。
Is there any way to do it? 有什么办法吗?
In the past, I've leveraged the change event of the numeric text box to check for this case. 过去,我利用数字文本框的change事件来检查这种情况。 Like this:
像这样:
function onChange() {
// If user clears, default to 0
if (!this.value()) {
this.value(0);
}
}
$("#numerictextbox").kendoNumericTextBox({
change: onChange,
spin: onSpin
});
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.