Responsive and colReorder when Order specified Broken?

Responsive and colReorder when Order specified Broken?

JoeCJoeC Posts: 1Questions: 1Answers: 0

Here is an example of the two not playing well together. Am I using it incorrectly?

Using: https://cdn.datatables.net/v/dt/jqc-1.12.3/dt-1.10.12/cr-1.3.2/r-2.1.0/datatables.js

https://jsfiddle.net/j6w7ekdo/

Thanks

Answers

  • allanallan Posts: 63,195Questions: 1Answers: 10,412 Site admin

    Thanks for the test case. It does sound like there is a but there.

    I'm afraid I've got quite a support backlog so it will probably be a while until I can get to this, but I will keep this tab open until I can.

    Allan

  • allanallan Posts: 63,195Questions: 1Answers: 10,412 Site admin

    The reason Example 2 isn't working is the way Responsive shows the show / hide icons by default. It uses :first-child, but in that example the first column is actually hidden.

    It is kind of possible to select the first visible child, but its really quite ugly and it won't work in IE8 (which Responsive still supports).

    I'm not sure how to address that one yet.

    Example 1 appears to be more complicated. Responsive is hiding some columns, but it looks like it is calculating which ones to hide before the reorder, and then hiding them after the reorder, which really messes everything up. Compounding that the details view appears to be getting confused by the reorder.

    Its going to take a little while to untangle this I'm afraid. I suspect a new event will be required from ColReorder at a minimum.

    Allan

This discussion has been closed.