PUBLIC - Liferay Portal Community Edition
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-34286

Alerts portlet distribution scope does not function with Custom Role defined permissions

    Details

    • Type: Bug Bug
    • Status: Closed
    • Resolution: Fixed
    • Affects Version/s: 6.1.1 CE GA2, 6.1.20 EE GA2
    • Fix Version/s: 6.1.30 EE GA3, 6.2.0 CE M6
    • Labels:
    • Environment:
      LIFERAY VERSION: 6.1 GA2
      OPERATING SYSTEM: Red Hat Enterprise 5
      APPLICATION SERVER: Tomcat 7.0
      JAVA VIRTUAL MACHINE: Java 6
      DATABASE: SQL Server 2008 R2
    • Branch Version/s:
      6.1.x
    • Backported to Branch:
      Committed
    • Story Points:
      3
    • Similar Issues:
      Show 5 results 

      Description

      Description

      When creating a custom role with Defined Permissions specifically for the Alerts Portlet, the distribution-scope drop down menu will not work for the non-admin user who is assigned to the custom role. As a result, if an entry has been made for a site, i.e. Liferay, this user will not be able to mange it or add an entry to that site via the distribution-scope drop down menu.

      Steps to Reproduce

      1) Create a Role (Priority Coordinators) and add a non-administrator user.
      2) In the Role 'Define Permissions' add Alerts permissions for 'Add Entry, View'
      3) As an Administrator, add the Alerts portlet to a page, but do not add any alerts. You should be able to see the 'Entries and Manage Entries' buttons.
      4) Now, sign in as the user added in step one. The user doesn't see the buttons to manage the entries.
      5) Now, go back in as the Administrator and add an alert. Verify you can see it.
      6) Now, sign in again as the user added in step one, and you should be able to see the alert. Select the Distribution Scope Drop-down menu. Notice it only shows Roles and if you click it, it does not do anything.

      Expected Behavior: Having the Permissions to Add Entry and to View, should allow a non-admin user assigned to this custom role to Add and Manage entries on all the Distribution scopes. The user should also be able to see the Add Entry and Manage Entry buttons of the portlet since he has been assigned the permission to do so, not only when there is an alert made.

        Activity

        Hide
        Raymond Auge added a comment -

        There is a flaw in the steps to reproduce. Nowhere have you assigned "Manage Announcements" permission.

        In order for some "scope" to appear in the "Distribution Scope" list the current user must have "Manage Announcements" permission on some scope.

        For example, if you want the "Priority Coordinators" role to be able to create alerts for "User" role:

        • go to the Roles Admin
        • select User -> Actions -> Permissions
        • for the "Priority Coordinators" role, check "Manage Announcements"
        • login as user created
        • go to the Alerts portlet -> Manage Announcements
        • click "Distribution Scope"
        • should find "User" under "Roles"

        Each possible scope must be configured in a similar fashion.

        Every entity which is supported as a "Distribution Scope" has the "Manage Announcements" permission on it.

        Following these steps, I do not need the suggested fix.

        Show
        Raymond Auge added a comment - There is a flaw in the steps to reproduce. Nowhere have you assigned "Manage Announcements" permission. In order for some "scope" to appear in the "Distribution Scope" list the current user must have "Manage Announcements" permission on some scope. For example, if you want the "Priority Coordinators" role to be able to create alerts for "User" role: go to the Roles Admin select User -> Actions -> Permissions for the "Priority Coordinators" role, check "Manage Announcements" login as user created go to the Alerts portlet -> Manage Announcements click "Distribution Scope" should find "User" under "Roles" Each possible scope must be configured in a similar fashion. Every entity which is supported as a "Distribution Scope" has the "Manage Announcements" permission on it. Following these steps, I do not need the suggested fix.
        Hide
        Raymond Auge added a comment -
        Show
        Raymond Auge added a comment - https://github.com/rotty3000/liferay-portal/pull/197 was closed.
        Hide
        Pani Gui (Inactive) added a comment -

        PASSED Manual Testing following the steps in the description.

        Reproduced on:
        Tomcat 7.0 + MySQL 5. Portal 6.1.20 EE GA2.

        The user does not see Alerts portlet even though the user has add entry and view permissions for Alerts portlet.

        Fixed on:
        Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: 5597a2e6cb89180878b267c184280db8f9486f78.

        The user who has add entry and view permissions for Alerts portlet is able to see Alerts portlet. To create an alerts scoped with user role, check "Manage Announcements" on the corresponding role.

        Show
        Pani Gui (Inactive) added a comment - PASSED Manual Testing following the steps in the description. Reproduced on: Tomcat 7.0 + MySQL 5. Portal 6.1.20 EE GA2. The user does not see Alerts portlet even though the user has add entry and view permissions for Alerts portlet. Fixed on: Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: 5597a2e6cb89180878b267c184280db8f9486f78. The user who has add entry and view permissions for Alerts portlet is able to see Alerts portlet. To create an alerts scoped with user role, check "Manage Announcements" on the corresponding role.
        Hide
        Pani Gui (Inactive) added a comment - - edited

        PASSED Manual Testing following the steps in the description.

        Fixed on:
        Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 5e3b39a1fd7bc3443d3263cfedb871bdceafe04c.

        The user who has add entry and view permissions for Alerts portlet is able to see Alerts portlet.

        Show
        Pani Gui (Inactive) added a comment - - edited PASSED Manual Testing following the steps in the description. Fixed on: Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 5e3b39a1fd7bc3443d3263cfedb871bdceafe04c. The user who has add entry and view permissions for Alerts portlet is able to see Alerts portlet.

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:
              Days since last comment:
              1 year, 46 weeks ago

              Development

                Structure Helper Panel