Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
Issues when renderCheckboxes and templates on a boolean column.


I'd like some advice, I use the iggrid with the renderCheckboxes which is fine when all the cells in the column are editable or not (we use a different css class to indicate that the column is editable or not) . But for one of my grid I need to do that on a cell level for example in the same column:

- Editable cells: checkboxes are blue

- Readonly cells : checkboxes are grey.

I tried to use a template in that column, cloning the html of the standard ui-checkbox and adding some CSS class to indicate the read-only aspect of the cell. But I need to use the value of the cell itself to get the check state and that doesn't seem to work:

the jsrenderer template: 

"{{if MakeFlag == false}}KO{{else}}OK{{/if}}"

doesn't work and I think it's because of the value of the cell itself because if I change that to another boolean value without template : 

{{if FinishedGoodsFlag == false}}KO{{else}}OK{{/if}}

then the column template is working but with the FinishedGoodsFlag value.

If I turn off renderCheckboxes it's working (but I don't wan't that), my guess is that the templating engine is getting something else maybe the html value of the checkbox or the template instead of the value.

It says in the API under "renderCheckboxes" that : "Checkboxes are not rendered for boolean values in columns with a column template." so it shouldn't ?

So I don't see how we can achieve to use a template on a boolean column if we can't use its value inside the template with renderCheckboxes enable for other boolean column.

Is there any work around or other way to do that? shall I create a ticket? By the way we are using jsrenderer but I tried infragistics engine and it's not working either.

Best regards