mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-05 17:30:30 +00:00
@@ -173,14 +173,14 @@ function APIUpdateAttr(props) {
|
||||
}
|
||||
if (typeof props.success === 'function') {
|
||||
return props.success(data);
|
||||
}
|
||||
}
|
||||
}).fail(function(jqXHR, textStatus, errorThrown) {
|
||||
if (flash_message) {
|
||||
toastr.error(fail_message);
|
||||
}
|
||||
if (typeof props.error === 'function') {
|
||||
return props.error(jqXHR.responseText);
|
||||
}
|
||||
}
|
||||
});
|
||||
// return true;
|
||||
}
|
||||
@@ -198,7 +198,8 @@ function objectDelete(obj, name, url, redirectTo) {
|
||||
}
|
||||
};
|
||||
var fail = function() {
|
||||
swal("错误", "删除"+"[ "+name+" ]"+"遇到错误", "error");
|
||||
// swal("错误", "删除"+"[ "+name+" ]"+"遇到错误", "error");
|
||||
swal("错误", "[ "+name+" ]"+"正在被资产使用中,请先解除资产绑定", "error");
|
||||
};
|
||||
APIUpdateAttr({
|
||||
url: url,
|
||||
@@ -219,7 +220,7 @@ function objectDelete(obj, name, url, redirectTo) {
|
||||
confirmButtonText: '确认',
|
||||
closeOnConfirm: true,
|
||||
}, function () {
|
||||
doDelete()
|
||||
doDelete()
|
||||
});
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user