Refactoring and templates
Merge branch 'index_view'