Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-20075

Add API to manipulate the scope notification filters for a user in the notifications filters API

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Major
    • None
    • 13.4.7
    • Notifications
    • None
    • Unknown

    Description

      The notifications filters API exposed in $services.notifications.filters (https://extensions.xwiki.org/xwiki/bin/view/Extension/Notifications%20API/Notification%20Filters%20API/) is very generic and looks incomplete.

      Its functions are far from the UI, especially as modified for XWIKI-18406 .

      The generic concept of filter & filter preference is rather hard to grasp and use.

      This issue is about adding clear and easy to use APIs to manipulate that list is displayed on the UI as 'Custom filters'. IIUC the documentation, these would be the filter preferences of the scopeNotificationFilter.

      For XWIKI-18406 I think, there was a function added to add a new scope notification filter for a user (a new custom filter), but there are no functions to:

      • list all of them
      • easily check if there is any filter for a location
      • remove a filter - actually, the function exists but the caller needs to provide an ID to this function which is hard to get because the listing functions don't exist.

      Globally, this API should be more geared towards the concepts that are presented on the UI so that first and foremost it provides the possibility to programatically manipulate the config, just as one would do it from the UI, and then it can have additional functions that give access to more complex things.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              lucaa Anca Luca
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: