I’m changing my heating rules to a, be simpler, and b, use a time picker. In changing them over I want them both to be running, but only one will use the active switch, the other will use a fake switch.
In a single rule I’m setting:
var heaterItem = zwave_switch_central_heating
var heaterItem = pretend_central_heating
In my new rule, I’m running a single rule in a single file, this is fine.
But my old rules I have about 4 rules, and have to set heaterItem each time.
Is there a way at the top of the rule file that I can set heater item equal either item once?
I tired putting the assignment all by itself, but it complained it was set before assignment.
Even a single function that I can re-use at the top of each rule? As long as it goes to one place, when I can make the necessary change once.