view layout refactoring and templates added.