user1021167
user1021167

Reputation:

default selected row color in kendo grid doesn't effect

Am setting the row background color Ondatabound event based on some condition

               $('tr[data-uid="' + row.uid + '"] ').css("background-color", "green");

when the row is selected the default row selection color doesn't appear, the above new style is overriding the default behavior. Even when i explicitly set the row color on

    .k-grid table tr.k-state-selected
    {
     background: #22B99F;
     border-color:#22B99F;
    }

the above doesn't effect. When user clicked on the row want change the row color to above what is the best way to achieve it ?

Upvotes: 0

Views: 682

Answers (1)

Hoang Nguyen
Hoang Nguyen

Reputation: 1358

Try with below code

 $('tr[data-uid="' + row.uid + '"] ').addClass("green-row")

and add new css

.green-row td{
    background: green!important;
}

Upvotes: 1

Related Questions