Dear visitor, despite all the challenges, our team continues operating at full speed.

We are ready to help with any questions you may have. Please fill out this quick form and we'll get back to you.

Fill the form
Get Free Trial

How to input some conditions Flexmonster version 2.2

Bortolotti asked on November 10, 2016

I need to put conditions in my data grid. See my code: I am use a 2.2 version here.

flexmonster.embedPivotComponent(
"flexmonster/",
"pivotContainer",
"100%",
"500",
{
dataSourceType: "ocsv",
filename: "http://localhost/to/pages/ajaxCarregaDados.php",
flatView: true,
showTotals: false,
showGrandTotals: false,
licenseKey: "XXXX-XXX-XXXX-XXXX"
},
false, // toolbar Labels
);

tks!
 
I have a column “Scored Probabilities” and I need to put a diferente color when its value is >= 0.05.
 
How can I do it?
 
Thanks!

1 answer

Public
Dmytro Zvazhii Flexmonster November 11, 2016

Hello Eduardo,
Thank you for your question. You should just add the conditions object to your report. It will look smth like that:

{ 
dataSourceType: "ocsv",
...,
conditions: [{
"formula": "if(#value > 0.05, 'trueStyle')",
"measure": "Amount",
"trueStyle": {
"backgroundColor": "#FFFFFF",
"color": "#CC0000",
"fontFamily": "Arial",
"fontSize": 12
},
"falseStyle": {}
}]
}

Please, let us know if there are any questions here.
Best regards,
Dmytro.

Please login or Register to Submit Answer