last day (14 days later) » 

12:19
0
Q: Duplicated Result In ng-repeat

Kamel Milihey everyone am trying to display data inside my table and tun out i have duplicated result i read about track by $index and your item id when i use $index nothing seem to change but when i track by item.id in my case dev.idsome result aren't displayed so the actual question Why is ng-repeat is d...

your dev.validationdvd[0].etatvalid will throw an index error for your first data item (that has validationdvd: []. Can you provide a working plunker/fiddle with your problem?
take a look i just edited the answer
could you post your itemsPerPage filter code?
I've copied your code in this plunker. It works correctly. Check your data or create another plunker where your error is reproduced.
12:19
I changed my code the dir-paginate with ng-repeat and it worked correctly ? i can't open pluker could you please copied in fiddle thank you
You can create a fiddle and then I could look on what's wrong in it.
hey am sorry to bother you i found out the issue and i feel stupid my sql was missing a distinct hope you are not mad ps one more time and a mgoing to delete the question ps can i ask you another question
no prob. It happens with all of us sometimes ;)
yes, you can
thank you how can i display tow items in tool tip when add this in my code <div ng-repeat="xx in dev.validationdvd"> <a href="" rel="tooltip" tooltip="xx.vehid.model">Validé </a></div>
i have duplicated validé
in my case i only need one with the result of 2
and here's my directive code
app.directive('tooltip', function () {
return {
restrict:'A',
link: function(scope, element, attrs)
{
$(element)
.attr('title',scope.$eval(attrs.tooltip))
.tooltip({placement: "right"});
}
}
})
thank you
very much iulian
12:56
do not use ng-repeat on a div, because it will create as many elements as there are elements in the array.
instead, pass the dev.validationdvd into the tooltip directive and then display them as you like
Thank you one more time iulian i'll work on it have a good day
The same to you, Kamel!

last day (14 days later) »