Boolean grid configuration to add a conditional class
Howdy!
I've been messing around with the Grid datatype a bit, trying to make it more controllable.
I would like to add a boolean to the configuration of the rows, so that the editor may choose to make the row fluid.
Basically what i want in my custom grid is this:
var cssClass = (row.fluid) ? "container-fluid" : "container";
I have tried adding it in the JSON config as a boolean, but unfortunately that only returns either a 0 or a 1. The radiobuttonlist is no good either, as i want -nothing- to be returned unless it's similar to above.
Boolean grid configuration to add a conditional class
Howdy!
I've been messing around with the Grid datatype a bit, trying to make it more controllable.
I would like to add a boolean to the configuration of the rows, so that the editor may choose to make the row fluid. Basically what i want in my custom grid is this:
I have tried adding it in the JSON config as a boolean, but unfortunately that only returns either a 0 or a 1. The radiobuttonlist is no good either, as i want -nothing- to be returned unless it's similar to above.
I am open to suggestions. :-) Thanks!
// Thomas
Maybe missing the issue.. but
var cssClass = (row.fluid == "1") ? "container-fluid" : "container";
Thanks for the reply! :-) A little bit yes - the issue is getting the actual data out of the row, the above was just an example.
is working on a reply...