jQuery启用禁用按钮防止重复提交、layer.confirm确定按钮锁定防止重复触发事件
< a class = " btn btn-warning " id = " releaseBtn " onclick = " ShipPlanManager.release() " > < i class = " fa fa-pencil " > </ i > 计划下发 </ a > /** * 计划下发 */ ShipPlanManager . release = function ( ) { if ( this . check ( ) ) { //禁用按钮 $ ( "#releaseBtn" ) . attr ( "disabled" , true ) ; $ ( "#releaseBtn" ) . removeAttr ( "onclick" ) ; var data = $ ( '#' + this . id ) . bootstrapTable ( 'getSelections' ) ; var ids = "" ; for ( var i = 0 ; i < data . length ; i ++ ) { ids = ids + data [ i ] . id + "," ; } ids = ids . substring ( 0 , ids . length - 1 ) ; var lock = false ; //默认未锁定 parent . layer .