conditional formatting - is it possible to replace CASE-structure by code that gets the background-color from the TEAM-form ?

conditional formatting - is it possible to replace CASE-structure by code that gets the background-color from the TEAM-form ?

Hi,

I'm creating a calendar view.  The background-color of the appointment depends on the team being assiged to the appointment.

1 attachment

Instead of HARD-CODING the conditional formatting case i.e.
    conditional formatting
    (
        "Kris"
        {
            condition = (Team.Team == "1 Kris")
            format = "color:#ffffff;background-color:#009933;"
        }
        
        "Christopher"
        {
            condition = (Team.Team == "1 Christopher")
            format = "color:#ffffff;background-color:#33AD5C;"
        }

I'd rather use      code       i.e.
            condition = (Team.Team == Planning.Team)    

    selected_Team  =  Team_add  [ID == selected_Planning.Team];
    selected_Team.background-color  

            format = "color:#ffffff;background-color:selected_Team.background-color  ;"


Is this possible ?
What is the syntax ? html ? deluge ?

Many thanks

Kind regards 
Paul