WebPortal_TongZhou/02.UI/script/jquery-easyui-1.2.4/plugins/jquery.numberbox.js
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
/**
* jQuery EasyUI 1.2.4
*
* Licensed under the GPL terms
* To use it on other terms please contact us
*
* Copyright(c) 2009-2011 stworthy [ stworthy@gmail.com ]
*
*/
(function($){
function _1(_2){
var _3=$.data(_2,"numberbox").options;
var _4=parseFloat($(_2).val()).toFixed(_3.precision);
if(isNaN(_4)){
$(_2).val("");
return;
}
if(typeof (_3.min)=="number"&&_4<_3.min){
$(_2).val(_3.min.toFixed(_3.precision));
}else{
if(typeof (_3.max)=="number"&&_4>_3.max){
$(_2).val(_3.max.toFixed(_3.precision));
}else{
$(_2).val(_4);
}
}
};
function _5(_6){
$(_6).unbind(".numberbox");
$(_6).bind("keypress.numberbox",function(e){
if(e.which==45){
return true;
}
if(e.which==46){
return true;
}else{
if((e.which>=48&&e.which<=57&&e.ctrlKey==false&&e.shiftKey==false)||e.which==0||e.which==8){
return true;
}else{
if(e.ctrlKey==true&&(e.which==99||e.which==118)){
return true;
}else{
return false;
}
}
}
}).bind("paste.numberbox",function(){
if(window.clipboardData){
var s=clipboardData.getData("text");
if(!/\D/.test(s)){
return true;
}else{
return false;
}
}else{
return false;
}
}).bind("dragenter.numberbox",function(){
return false;
}).bind("blur.numberbox",function(){
后面还有 63 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。