refactor view logic into controllers