Added views routes.

Added tests for view routes.
Added missed user/:id route for api and view and added tests for them.