MicroDroid/vue-materialize-datatable

If Paginate set to false, printing raise an error : "TypeError: can't access property "remove", clonedTable.querySelector(...) is null"

Opened this issue · 0 comments

When paginate is set to false, the table footer containing pagination controls is removed. Then, when printing the table from the table button, a null null error is raised :
"TypeError: can't access property "remove", clonedTable.querySelector(...) is null"
and :
"TypeError: can't access property "remove", clonedTable.querySelector(...) is null
-> print DataTable.vue:345"
When checking the code line 345, I noticed a query selector targeting the non-existing HTML element '.material-pagination' in the footer and the method .remove being applied, which cause the error.
To reproduce the bug, you just need to take the basic example, set paginate to false in the template, then try to print.