标签:seo use trap sel 无法 get tle lse ons
//删除
function del() {
var id = "";
var row = $.map($("#DataList").bootstrapTable(‘getSelections‘), function (row) {
id = row.Id;
return row;
});
if (row == null || row.length <= 0) {
swal("提示信息", "请选择要删除的记录!", IconMsg.WARNING);
return false;
}
swal({
title: "确定删除选中的记录?",
text: "删除之后无法恢复该数据!",
type: IconMsg.WARNING,
showCancelButton: true,
confirmButtonColor: "#DD6B55",
confirmButtonText: "确定",
closeOnConfirm: false
},
function () {
$.ajax({
type: ‘post‘,
url: ‘/Users/DelUserById‘,
dataType: "json",
data: { id: id },
success: function (data) {
if (data.Result) {
$("#DataList").bootstrapTable(‘refresh‘);
swal("提示信息", data.Msg, data.IconMsg);
} else {
swal("提示信息", data.Msg, data.IconMsg);
}
}
});
});
前台页面上显示:
closeOnConfirm: false / true
关闭确认
标签:seo use trap sel 无法 get tle lse ons
原文地址:https://www.cnblogs.com/oyw911/p/10094917.html