try to apply a template to data - not work :s

working in progress at line 221