1👍
✅
You have the same id on the 2 loops for your li.
You should use a prefixe on each one, depending on your loops.
The first one :
<li id="a-{{ac.id}}">
The second one :
<li id="ver-{{ac.id}}">
And change in you “” accordingly
An id, must be unique as its name suppose it 😛
Additionaly, I don’t understand why you are using the closest method ?
$('#'+cid).remove();
should be enough.
Source:stackexchange.com