I can't find a simple method to add css to my module. Do you have a clear guide?
My goal is simple, invert the colors of a progress bar (red for 0 and green for 100%)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello Guillaume,
Yes it's on backoffice and iTop 3.1.1-1-12561.
I managed to load my css, but cannot add the class to the element.
The following setting does not seem to work:
<style><br>
<css_class>compliance-percentage</css_class><br>
</style>
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I can't find a simple method to add css to my module. Do you have a clear guide?
My goal is simple, invert the colors of a progress bar (red for 0 and green for 100%)
Hello Xavier,
As your are talking about the percentage attribute, I'm guessing you want to add your stylesheet in the backoffice, not the end-user portal.
If you are running iTop 3.0+, you can use the
\iBackofficeLinkedStylesheetsExtension
interface. You can find an example here.If you are running iTop 2.7, then there is no dedicated API, but you can proceed like in this example.
Hope it helps :)
Guillaume
Last edit: Guillaume Lajarige 2024-06-29
Hello Guillaume,
Yes it's on backoffice and iTop 3.1.1-1-12561.
I managed to load my css, but cannot add the class to the element.
The following setting does not seem to work:
<style><br> <css_class>compliance-percentage</css_class><br> </style>