Issues with HA/Z2M repercussions on Tuya integration

Since my English is not really good, I translated the text from German with Google Translate. I hope you can still see my problem.

I have a problem, the cause of which I can’t find out. But maybe one of you has the right tip for me.
It’s about Zigbee radiator thermostats and window sensors, which I have connected to SmartLife and also the automation for reducing the temperature when the windows are open. I have such a combination here, once in the kitchen and once in the living room. So far no problem that seems to have anything to do with HA, but unfortunately HA straddles me via the Tuya integration there, because the “switch.open_windows” of the thermostats is also created as an entity in HA (via the Tuya integration).
The problem: If the automation is to set the thermostat to a lowered temperature when the window is open, according to the logbook in HA, the “switch.open_windows” is activated within a second by the “homeassistant.turn_on” service (yes, that’s right turn_on), immediately switched to “Off” again and therefore the lowering of the temperature with the window open naturally does not work.
The switch entity provided by the thermostats (TRV02G/TS0601 from Moes) is used to tell the TRV that the window is open and can therefore be lowered to the set temperature.
The problem is the same in both rooms, but I can’t find any reason for this automatic switch-off.
The reason why I disconnected the TRV from Z2M and connected it to SmartLife is that I could not properly maintain the schedules in the thermostats from HA/Z2M (for Auto-Mode of the TRV) and the Thermostat internal clock was not changed by Z2M (DST).