Topic
2 replies Latest Post - ‏2014-02-11T08:04:35Z by John.fred
John.fred
John.fred
8 Posts
ACCEPTED ANSWER

Pinned topic customizing TBSM score card

‏2014-02-09T08:26:58Z |

Hi,

I have a score card having some columns with some numeric values, i want to change the color of the text it it crosses some threshold like under the policy editor i did the below:

 

if (columnName = 'Network Availability (%)' && value < 100)
{
      VALUE = '<font color="red"> <b> ' + value + '</b></font>';
}

 

after the changes i restarted the services still it is not taking any effect. any help/guidance will be appreciated.

 

  • randybrown
    randybrown
    59 Posts
    ACCEPTED ANSWER

    Re: customizing TBSM score card

    ‏2014-02-10T16:34:05Z  in response to John.fred

    Hi,

    The syntax for your policy code looks correct, and in fact I tried this in my system (using the same column name) and was successful.

    To confirm, this is the policy called GetTreeColumnValue.ipl, which is updated using the Edit Policy... button from the Tree Template editor.

    So the only suggestions that come to mind are:

    • Ensure the column name is an exact, case sensitive match to what you defined as the column name in the tree template editor.
    • Make sure the attribute mapped to the column is returning a numeric value. For example, a TBSM text rule will produce a string value, so the comparison <100 may not be valid.
    • The policy must return the variable VALUE, so be sure nothing else sets VALUE later in the policy. For example, the default policy content simply has the one statement "VALUE=value;" Make sure your policy code comes after this statement.

    I hope this helps...

     

    Randy Brown

  • John.fred
    John.fred
    8 Posts
    ACCEPTED ANSWER

    Re: customizing TBSM score card

    ‏2014-02-11T08:04:35Z  in response to John.fred

    Hi Randy,

    thanks for the reply, its working now , "Make sure your policy code comes after this statement."  thanks