Affects Version/s: 7.0.X, Master
Component/s: Sites Administration > Sites
When there is a scope select for content, if the single portlet available to the user in the content section of the site scope is not scopeable, that portlet (panel app) is not shown and a NPE is thrown. When another portlet is also available to the user, both portlets are shown.
I cannot reproduce this behavior in master because Asset Tags now have their own separate Categorization and deploying the test module from LPP-31278 onto master results in a missing dependency. However, examining the code, that because master's code is identical the same errors are possible and need to be addressed.
Steps to reproduce:
- Add a web content display portlet to a page
- Add a scope using that portlet (Configuration > Scope > Scope Dropdown: Welcome (Create New) > Save)
- On the Product Menu, click Liferay DXP (site) > Content, and assert that Default Scope is displayed.
- Go into Users > Roles > Regular Roles > User > Click the tricolon/options button > Define Permissions
- In Define Permissions for User, in the tree go to Site Administration > Content > Web Content > select Access and View
- In Define Permissions for User, in the tree go to Site Administration > Categorization > Tags > select Access and View
- Create new User
- Log in with the user to confirm whether the Web Content and test portlet panels show under site > Content > "Default Scope"
- Log in as admin and remove User permissions granted in #7 for web content.
- Repeat step 10 and see that neither portlet is shown on the navigation menu
The navigation menu would not show empty scopes
When the user is granted view/access permission to only the test portlet, it does not show in the menu and a NullPointerException is thrown.