Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-24989

Restrict the possible selection made through the UDW

    Details

      Description

      Right now, the UDW allows to select any readable content in the repository. When firing the contentDiscover event, it should be possible to pass a isSelectable function so that the UDW can check if the chosen content would make sense in the context where it's run.

      For instance, to fix EZP-24973, the UDW would restrict the selection to container content.

        Issue Links

          Activity

          Hide
          Damien Pobel (Inactive) added a comment - - edited

          If provided the isSelectable function should receive the content struct (ie the Location + ContentInfo + ContentType). Depending on the

          {multiple}

          parameter the behaviour will a bit different:

          • if multiple is set to true, the result of isSelectable will change the state of the Choose this content button in the selected item view
          • if multiple is set to false, the result of isSelectable will change the state of Confirm selection button.
          Show
          Damien Pobel (Inactive) added a comment - - edited If provided the isSelectable function should receive the content struct (ie the Location + ContentInfo + ContentType). Depending on the {multiple} parameter the behaviour will a bit different: if multiple is set to true, the result of isSelectable will change the state of the Choose this content button in the selected item view if multiple is set to false, the result of isSelectable will change the state of Confirm selection button.
          Show
          Mateusz Hyndle (Inactive) added a comment - PR: https://github.com/ezsystems/PlatformUIBundle/pull/412
          Show
          Mateusz Hyndle (Inactive) added a comment - Merged in master: https://github.com/ezsystems/PlatformUIBundle/commit/6a25e851dc91fbbd1be9eea44cb5e8adbcfbbba5
          Hide
          Mateusz Hyndle (Inactive) added a comment -

          Testing this story can be difficult as it's starting point for other bug fixes. So I guess for tests it will be enough to check if nothing is broken with UDW (in multiple selection mode - for example when adding location, and in single selection mode - for example when moving or copying the conten).

          Show
          Mateusz Hyndle (Inactive) added a comment - Testing this story can be difficult as it's starting point for other bug fixes. So I guess for tests it will be enough to check if nothing is broken with UDW (in multiple selection mode - for example when adding location, and in single selection mode - for example when moving or copying the conten).
          Hide
          Rui Silva (Inactive) added a comment -

          Tested and approved by QA for master, with sanity testing on the UDW.
          The related issues and the active restriction on the UDW are outside of the scope of testing this issue.

          Show
          Rui Silva (Inactive) added a comment - Tested and approved by QA for master, with sanity testing on the UDW. The related issues and the active restriction on the UDW are outside of the scope of testing this issue.

            People

            • Assignee:
              Unassigned
              Reporter:
              Damien Pobel (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 3 days, 3 hours
                3d 3h