标签:fun data nbsp new url ESS checked 全选 this
<th>全选<input id="ckAll" type="checkbox" onclick="QuanXuan()"/></th>
<td><input class="ckc" type="checkbox" value="@item.PId"/></td>
<script>
//全选
function QuanXuan()
{
$(".ckc").prop("checked",$("#ckAll").prop("checked"))
}
//批量删除
function PLDelete()
{
var arry = new Array();
$(".ckc:checked").each(function () {
arry.push(this.value);
})
if (confirm("确定要删除吗?"))
{
$.ajax({
url: "/ErShi/PLDelete/"+arry.toString(),
type: "post",
success: function (data)
{
if (data>0) {
alert("删除成功!");
location.href = "/ErShi/Index";
}
}
})
}
}
</script>
标签:fun data nbsp new url ESS checked 全选 this
原文地址:https://www.cnblogs.com/xiaochao1996/p/9387523.html