Refactori home page view use a template