Change dashboard 2.0 UI-Group Background color based on bool in the payload

I am new to node red. I am trying to change the UI-Group background color to green it the device is on and red if it is off. I am not sure if i need to use UI-control or UI-templet nodes?