CLOUDSTACK-1908:Specified event isn't removed from the list after deletion

This commit is contained in:
Isaac Chiang 2013-04-03 22:51:01 +05:30 committed by Pranav Saxena
parent 8ff24fcb18
commit 7b0b2cdc84
2 changed files with 10 additions and 3 deletions

View File

@ -257,8 +257,6 @@
} }
}); });
$(window).trigger('cloudStack.fullRefresh');
} }
}, },

View File

@ -304,7 +304,16 @@
} }
if($detailView.data("list-view-row") != null) { if($detailView.data("list-view-row") != null) {
$detailView.data("list-view-row").remove(); var $row = $detailView.data('list-view-row');
var $tbody = $row.closest('tbody');
$row.remove();
if(!$tbody.find('tr').size()) {
$("<tr>").addClass('empty').append(
$("<td>").html(_l('label.no.data'))
).appendTo($tbody);
}
$tbody.closest('table').dataTable('refresh');
} }
} }
}); });