Thermostat card setpoint temperature dependent on system_mode

Hi,

I have multiple Silvercrest (Tuya) ZigBee enabled thermostat radiator valves installed (these to be precise) and use the thermostat card to control them. The TRV’s are integrated through Zigbee2MQTT.

These TRV’s support schedules programmed to them itself and will regulate the temperature accordingly.
However, the thermostat card uses the current_heating_setpoint attribute of the climate entity to display the target temperature regardless of the current mode of operation. As long as the TRV is not operated in scheduled mode this target temperature is correct. But, if in scheduled mode the correct target temperature is given in the current_heating_setpoint_auto attribute.

Is there a way to choose the displayed value for the target temperature according to mode the TRV is currently operated? Templating would be easy, if possible:

{{ state_attr('climate.trv','current_heating_setpoint') if state_attr('climate.trv','system_mode') != 'auto' else state_attr('climate.trv','current_heating_setpoint_auto') }}

thank in advance