Web Interface Report - css

134 views
Skip to first unread message

Luigi

unread,
Jan 22, 2018, 10:43:10 AM1/22/18
to Fujitsu RunMyProcess Developer Community
Hello,
I created a Post Loaded Script in a WI report that assign 2 related styles to array row, based on 2 conditions.

Then I added a Custom Stylesheet in the WI Report (Stylesheet tab) , i.e. :

-----------------------------------------
.hi_waiting {
font-weight: bold;
background-color: yellow;
}

.hi_rejected {
font-weight: bold;
background-color: orange;
}
-----------------------------------------

The Post Loaded Script works but it seems the custom style css is not applied to the page.

Did I miss anything ?
What should I check ?

Thank you!


Prachi Chandak

unread,
Jan 22, 2018, 12:14:32 PM1/22/18
to Luigi Cichella, Fujitsu RunMyProcess Developer Community
Hello Luigi,

I as per your requirement it seems you want to apply CSS to row of report based on the status.
For that you can use two methods in java-script as follows-

1. addRowStyle(rowId,className)Sets an additional css class name to the given row
2. addCssRule(cssRule)allows you to add a given css to your web interface

Please refer this link for more details - http://docs.runmyprocess.com/API_Reference/JS/RMP_Report.html

E.g :-

if(id_report.getRowValue(i, 'status') == "New")
{
id_report.addRowStyle(i, 'newcss');
id_report.addCssRule(".newcss { background: red; }")
}

You can set this script into Post Load Script section in WI report. 
Hope this solution works out for you. Please revert us back for any other query.


Thanks & Regards,
Prachi Chandak
Fujitsu RunMyProcess Support



--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum+unsubscribe@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at https://groups.google.com/a/runmyprocess.com/group/supportforum/.
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/c05f2c4e-0430-4f24-b1cf-62a6352468ae%40runmyprocess.com.
For more options, visit https://groups.google.com/a/runmyprocess.com/d/optout.

ciche...@fatergroup.com

unread,
Jan 23, 2018, 4:34:26 AM1/23/18
to Fujitsu RunMyProcess Developer Community, ciche...@fatergroup.com
Hello Prachi,
I used "addRowStyle" in my script but the css loaded in the report was not applied.
I just solved by validating the uploaded css in the "stylesheet" tab and saving again the report.

Thank you.
> To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
Reply all
Reply to author
Forward
0 new messages