Improved routing and applied code-behind model