Function variable in template node

I’m implementing a new sprinkler system based on “Node-red to the rescue (controll sprinkler and HVAC systems)” and the big template block within the sensors I placed in a template node. Since I have 4 zones I need to repeat it, I’m wondering can variables be used to have more maintainable solution?

The idea would be that based on 3 input a new date can be determined.