Commit 97a1df01 authored by Luc Didry's avatar Luc Didry
Browse files

Fix bug: confirmation modal didn't had all updated infos

If you modify a subnet, and then try to delete it, the infos in
confirmation modal are not updated from modification.

If you modify the CIDR of a subnet, then re-modify it, the CIDR in the
modal wasn't the new CIDR.
parent 3f9434e9
......@@ -162,8 +162,12 @@ function modNetwork() {
communities.push(value+' ('+com[value]+')');
});
$("#mod-"+id).attr('data-communities', data.msg.communities.join());
$('#mod-'+id).attr('data-cidr', data.msg.cidr);
$("#com-"+id).html(communities.join('<br>'));
$('#delete-'+data.msg.id).unbind('click');
$('#delete-'+data.msg.id).click(function() {showConfirmModal('delete', data.msg);});
// Clear modification modal
$('#modModal').modal('hide');
$('#mod-alerts').empty();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment