XTemplates allows you ho handle your data just enclosing this kind of operations between {[ .. ]} brackets.
So, just to explain better what I mean, suppose your model has two fields (numberA and number.
To sum these values inside your template you should code it in something like: