FixedHeader and FixedColumn with multirow header and colspan

FixedHeader and FixedColumn with multirow header and colspan

jceciljcecil Posts: 2Questions: 1Answers: 0
edited October 2022 in Free community support

Hi all,

I have a datatable that has two header rows, with the first row using colspan to span groups of headers in the second row. I am trying have the table display with both fixed headers and 3 fixed columns at the left, but can't seem to get this working.

I've created a test case here:
live.datatables.net/fajesawo/1/edit

Using the test case the FixedColumns does not appear to work at all, but using the same config in a test application I see different behaviour.

In the screenshot below the left 3 columns are fixed, but the topmost header row scrolls along with the table data. Also there is what looks like the background for a scrollbar at the right side of the header.

The test application uses the following:
* jquery 3.4.1
* DataTables 1.12.1
* FixedColumns 4.1.0
* FixedHeader 3.2.4

Kind regards,

James Cecil

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 63,535Questions: 1Answers: 10,475 Site admin
    Answer ✓

    FixedColumns wasn't included in the test case. With it, I can see the issue: http://live.datatables.net/fajesawo/3/edit .

    Unfortunately, FixedColumns does not currently support multi-row headers. That is a limitation I'm aware of, but don't currently have a fix for - sorry. It is something that will be fixed along with DataTables 2 which has a lot of work on column headers, but that is still likely some time off.

    Allan

  • jceciljcecil Posts: 2Questions: 1Answers: 0

    Hi Allan,

    Many thanks for your reply!

    Ah, I'd not realised I needed to explicitly add the reference to FixedColumns in the test case.

    Thank you for looking into the issue and confirming the limitation. For the time being we'll rethink the design of the table and reassess when DataTables 2 is available.

    Kind regards,

    James

Sign In or Register to comment.