Quantcast
Channel: JavaScriptMVC Forum
Viewing all articles
Browse latest Browse all 3491

Re : Help With An Error Please

$
0
0
Here's what I "think" is the root of my issues.

I am using a jQuery plugin for datagrids called DataTables. The way it works is you generate the HTML for the table and then call the plugin on the table DOM element. 

I am generating the table HTML using EJS by iterating over a the results of a findAll, creating a row in the table for each model. I am using .attr() when writing model properties into table cells, so this is setting up live binding. 
  1. <td><%= player.attr( "team" ) %></td> 

Next I instantiate DataTables on the table. This plugin modifies the HTML for the table, adding classes and wrapping some of the table DOM elements.

Is this modification of the HTML screwing up live binding?

When the page loads, the grid loads fine. But if I destroy a model that is being displayed in the grid any subsequent calls to a live binded field still in the grid produces the error

Uncaught TypeError: undefined is not a function render.js:227


Help me Obi-tovi you're my only hope...

Viewing all articles
Browse latest Browse all 3491

Trending Articles