Fix permissions
Move some view macros into ResourceBundle to reduce code duplication