This fixes a display issue where non global users (admin/read only) who have access to devices or ports weren't being displayed.
Also fixed an issue where the device link was incorrect.
Fixed user preference page to show devices allowed access
Fix getVisibleParent when no parent is visible. Add tests for getVisi…
…bleParent. Fixes #265