update template of resource