olifolkerd / tabulator

Interactive Tables and Data Grids for JavaScript
http://tabulator.info
MIT License
6.6k stars 811 forks source link

Impossible download multiple data for nested tabulator tables #2932

Closed andrewittorio closed 4 years ago

andrewittorio commented 4 years ago

Describe the bug It seems that when we add a tabulator control as nested table it is not possible download its data in excel.

Tabulator Info 4.7.2

Working Example https://codepen.io/andrewittorio/pen/gOrPoNR

To Reproduce Try to download the xlsx file. --> An exception is thrown. If you try to comment the line 94: "Accounts Data": "#tableEl", //first tab with table set using a query selector

the file will be downloaded

Expected behavior Having multiple tabulator objects in my page, I would be able to use all of their data to create an excel file.

Desktop (please complete the following information):

Thank you.

olifolkerd commented 4 years ago

This is because you are trying to reference a table by its ID when it is inside of a virtual DOM, this means that the table may not exist at the point you call the function (only the visible table rows actually exist at any point in time)

andrewittorio commented 4 years ago

Hi Oli, first of all, thank you for your reply.

This means that if I disable the virtual dom it should work?

I tried setting the virtualDom attribute to false, but the result is always the same. Please refer to the next link to find the example.

https://codepen.io/andrewittorio/pen/qBZXEJd

Thank you,