Disabled rows in the table

Disabled rows in the table

Josh_BrooksJosh_Brooks Posts: 11Questions: 4Answers: 0

How can I display rows in the table so they are disabled, that is, grayed out?

Answers

  • jLinuxjLinux Posts: 981Questions: 73Answers: 75

    What I would do, is just use the createdRow, and parse the data for the row, and if its a row you wish to disable, just add a class to the row, then use the CSS to style any row with that class....

    $('#data-table').DataTable({
        createdRow: function( row, data, dataIndex ) {
            if(/* Put your logic in here..*/ )
                $( row ).addClass('row-disabled');
        }
    });
    
This discussion has been closed.