/**
* 某行置灰
* @see zhihui
* @param td 某行的一个td
* @param flag true置灰,false不置灰
* @author liuyang
* @date 2019.12.12
*/
function trDisable( td, flag) {
var tr = td.parentNode.parentNode;
var child = tr.children;
$(child).each(function (index, element) {
$(element).find('input').each(function (i, e) {
$(e).attr("disabled", flag)
});
$(element).find('span').each(function (i, e) {
$(e).attr("class", flag == true ? "buttoun-submit" : "buttoun-default");
if (!flag) {
$(e).removeAttr("onclick");
}
});
});
}
/**
* 某行置灰 调用服务端
* @param td 某行的一个td
* @author liuyang
* @date 2019.12.17
*/
function trDisable2(td) {
var tr = td.parentNode.parentNode;
var child = tr.children;
//判断bt_disabled功能
if (child.length > 4 && child[4].className == "bt_disabled") {
var bt = child[4].children[0];
bt.click();
}
}