I have:
mouseOver: function () {
var catId = this.category_id;
$('#expenditureSummaryGrid .k-grid-content tr').each(function() {
if($('td span', this).data('id') == catId) {
this.addClass('grid-hover');
}
})
},
But it's giving me:
Uncaught TypeError: undefined is not a function
Which isn't making much sense since "this" is the expected DOM element I'm trying to add a class too.
What is going wrong?
Since
.addClass()
is a jQuery function, you likely need to changeto
The error of "this" is with the condition inside the for each loop. Can u try