Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines
Sorry for my late reply, if you use the DataTables in DataGrid package, you can use the "formatValue" to return an html that you want, for example:
DataTables::create(array(
"columns"=>array(
"myColumn"=>array(
"formatValue"=>function($value,$row)
{
if($value=="pos")
return "<center><img src='...' /></center>";
}
)
)
))
What I am missing is the possibility to tell the formatter to only format for type == display:
"render": function (data, type, row, meta) {
if (type === 'display') {
For example if I have numbers for days. And I want to use the formatter to color all numbers from 0 - 30 in green, all in 30 - 90 in yellow and all above in red. With the original DataTables I use the type === display comparison to ensure that sorting is still possible based on the integer value. If I use DataGrid I could not find an option to avoid a miss functional sorting.
Do you have any solution for this issue?
Thanks!
Let KoolReport help you to make great reports. It's free & open-source released under MIT license.
Download KoolReport View demo