Arslan Farooq
Arslan Farooq

Reputation: 21

Indeterminate select all checkbox in datatables is not rendering correctly after updating chrome to latest version(83.0.4103.61)

I am using gyrocode plugin for checkboxes implementation with selection in datatables.

Details are here https://www.gyrocode.com/projects/jquery-datatables-checkboxes/

JSFiddle implementation https://jsfiddle.net/gyrocode/snqw56dw/

when we select any row to get indeterminate state for select all checkbox, it will not render correctly. You can try even on above link.

enter image description here

Upvotes: 0

Views: 663

Answers (1)

Arslan Farooq
Arslan Farooq

Reputation: 21

i have found a solution for this, just posting here so someone can get help if facing same.

so the solution is that we cannot set the "checked" value to true if we want to set "indeterminate" true. so i enhance the gyrocode checkbox library to set "checked" to false whenever i want to set it to indeterminate state.

Always do following,

$checkboxesSelectAll.prop({
    "indeterminate": true,
    "checked": false
});

Upvotes: 1

Related Questions