Bug in detail template with html table.

2 posts, 1 answers
  1. Alanm
    Alanm avatar
    18 posts
    Member since:
    Mar 2007

    Posted 01 Feb 2012 Link to this post

    There seems to be a bug with the details row in a Kenodo Grid when it is created using an existing html <table>.  If fails to create a column header for the expand/collapse marker and uses the first data column instead (in the example "One").  This gives me 3 column headers, but 4 data columns for each row, my 3 plus the expand/collapse column.

    One --> Two --> Three
     >    -->  1 -> 2 -> 3

    <table id="grid">
        <thead>
            <tr>
                <th data-field="one">One</th>
                <th data-field="two">Two</th>
                <th data-field="three">Three</th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td>1</td><td>2</td><td>3</td>
            </tr>
            <tr>
                <td>1</td><td>2</td><td>3</td>
            </tr>
        </tbody>
    </table>
      
    <script>
        $(document).ready(function() {
            var element = $("#grid").kendoGrid({
                height: 450,
                sortable: true,
                detailInit: detailInit
            });
        });
      
        function detailInit(e) {
        }
    </script>
  2. Answer
    Nikolay Rusev
    Admin
    Nikolay Rusev avatar
    2284 posts

    Posted 03 Feb 2012 Link to this post

    Hello Alanm,

    I can confirm that such issue exist. It can be only observed when the table have header defined. As a workaround currently you can use the approach demonstrated on the following jsFiddle:
    http://jsfiddle.net/rusev/wGmxT/

    All the best,
    Nikolay Rusev
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Kendo UI is VS 2017 Ready
Back to Top