Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting Error Uncaught TypeError: Cannot read properties of undefined (reading '0') on data update #31

Open
mangenayan opened this issue Jan 24, 2024 · 1 comment

Comments

@mangenayan
Copy link

Hi,

I am fetching data from api and assigning it to nested data table by using following function.
function createTree(data)
{
var settigns = {
iDisplayLength: 5,
bLengthChange: true,
bFilter: true,
bSort: true,
bInfo: true,
};

  var table = new nestedTables.TableHierarchy(
    "treetable",
    ajaxData,
    settigns
  );
  table.initializeTableHierarchy();

}

So for the first time I am able to see the nested data table and all rows are getting expanded but after 30 Sec I want to update the nested table so I am calling the same function with new data. At that time I am getting below error.

Uncaught TypeError: Cannot read properties of undefined (reading '0')
at DataTable.fnOpen (jquery.dataTables.js:667:1)
at HTMLTableRowElement.eval (NestedTables.js:151:1)
at HTMLDivElement.dispatch (jquery.js:5206:1)
at elemData.handle (jquery.js:5014:1)

Please let me know how can i fix this error.

@frigoni
Copy link

frigoni commented Jul 26, 2024

Hi, did you solve this error?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants