PDA

View Full Version : Selected row's id?



darkhorni
6 Sep 2012, 12:58 AM
I have

listeners : {
itemdblclick : function(dv, record, item, index, e) {
console.log(record.id);
}
}
However it seems that the record.id is not the row's id because when I use it some other place (animateTarget) it says that the I'm trying to regiser dublicate ids.

Farish
6 Sep 2012, 1:00 AM
you should use the get method.

console.log(record.get('id'));

OR

console.log(record.data.id);

darkhorni
6 Sep 2012, 1:11 AM
you should use the get method.

console.log(record.get('id'));

OR

console.log(record.data.id);
Sadly both of the them are not defined.

Farish
6 Sep 2012, 1:15 AM
i thought you were trying to access the id field of the record. but i guess you want to do something else.

darkhorni
6 Sep 2012, 1:19 AM
i thought you were trying to access the id field of the record. but i guess you want to do something else.
Sorry. By id I mean id property. But the rows's ids must be self assigned..