Refactoring & view fixes