Vaadin Grid - Declarative desing - colspan

Hi,

I tried to create a vaadin-grid with the following content:

<table>
    <colgroup>
        <col column-id="name" sortable="false">
        <col column-id="status" sortable="false">
        <col column-id="actions" sortable="false">
    </colgroup>

    <thead>
        <tr>
            <th plain-text colspan="2" column-ids="name,status">Hello</th>
            <th plain-text column-ids="actions">Actions</th>
        </tr>
    </thead>

    <tbody>
        <tr>
            <td>Customer Project 1</td>
            <td>OK</td>
            <td>OK</td>
        </tr>
    </tbody>
    <tfoot>
        <tr>
        </tr>
    </tfoot>
</table>

I expected that the first 2 cells would be merged, however the result is not what I expected. (The cells are not merged)

Isn’t this the right way of merging two cells?

Regards,
Bela

39426.png

Hi,

no, I don’t think that will work. You need to combine the headers in Java code.

-Olli