Change controller to template