Prevent edit on rowgroup

Prevent edit on rowgroup Posts: 9Questions: 3Answers: 0

I'm using Editor and Rowgroup.

This is my event:
$('#dataTablesEditor').on( 'click', 'tbody td:not(:first-child)', function (e) {
editor.inline( table.cell( this ).index(), {
onBlur: 'submit'
} );
} );

How can i disable edit when clicking on the rowGroup tr?
Now i got an error:
ught Error: Cannot edit more than one row inline at a time

This question has an accepted answers - jump to answer


  • allanallan Posts: 61,669Questions: 1Answers: 10,096 Site admin
    edited January 2023 Answer ✓

    You need to have your selector not be able to pick the cell inside the grouping row. For example you might use:

    'tbody tr:not(.dtrg-group) td:not(:first-child)'


    • From the tbody
    • Select rows which do not have the class dtrg-group
    • Then select the cells which are not first child.


  • Posts: 9Questions: 3Answers: 0
    edited January 2023

    @allan Thank you for your reply.

    That worked great ;D

Sign In or Register to comment.