我有一张桌子,里面有行。当我单击一个按钮时,它会删除它之前的行。我正在使用最接近()函数来确定行。我想删除按钮所在的同一行。
function DeletClick(id, date) {
var e = window.event; \
if (confirm('Are you sure you want to delete the record from ' + date + '?')) {
DisplayInformation.Delete(id,
function (result) {
if (result) {
jQuery('#' + e.srcElement.id).closest('tr').remove(); //Delete Row here!
} else {
alert('You Do not have permssion to delete record.');
}
});
}
}