FixedHeader 2.1.0 plugin and invisible columns - not working :(

FixedHeader 2.1.0 plugin and invisible columns - not working :(

phaxphax Posts: 16Questions: 4Answers: 0
edited February 2014 in FixedHeader
Hi!
I want to make the FixedHeaderPlugin work with invisible columns:
[code]$('#any').dataTable({... aoColumnDefs:[{
aTargets:[0],
bSortable:false
},{
aTargets:[1]
},{
aTargets:[2],
bVisible:false
},{
aTargets:[3]
}], ...]);[/code]

but the clone thead always contains 4 columns and not just 3.
I was browsing through the code but found no note on handling invisible columns.
Does anyone have a hint for me?

Thanks, Philip

Replies

  • allanallan Posts: 61,972Questions: 1Answers: 10,160 Site admin
    That looks like a bug to me.

    This line should have the elements update in fixed header: https://github.com/DataTables/FixedHeader/blob/master/js/dataTables.fixedHeader.js#L221

    But it needs a `.dt` namespace... oops :-(

    Fix here: https://github.com/DataTables/FixedHeader/commit/90265f9

    Example: http://live.datatables.net/numojoz/1/edit

    The fix is int the 2.1.1-dev nightly for FixedHeader.

    Thanks for the heads up!

    Allan
  • phaxphax Posts: 16Questions: 4Answers: 0
    Hi Allan!
    Thanks for the fix!
    Keep up the good work :)

    // Philip
This discussion has been closed.