标签:激活 fun rem function sele == back 不可点击 remove
//判断button是否为不可点击状态
if($("#buyButton").prop("disabled") == true){}
//判断button是否为不可点击状态
if($("#buyButton").prop(‘disabled‘) != true){}
/**
* 购买按钮失效
*/
that.disableBuyButton = function(){
if($("#buyButton").prop(‘disabled‘) != true){
$("#buyButton").prop(‘disabled‘, ‘disabled‘);
$("#buyButton").css("background", "#8f8f96");
}
}
/**
* 购买按钮激活
*/
that.ableBuyButton = function(){
if($("#buyButton").prop("disabled") == true){
$("#buyButton").removeProp("disabled");
$("#buyButton").css("background","#52a9e9");
}
}
标签:激活 fun rem function sele == back 不可点击 remove
原文地址:https://www.cnblogs.com/alisleepy/p/9982296.html