Uploaded image for project: 'Camunda Optimize'
  1. Camunda Optimize
  2. OPT-2558 I can filter by rolling date on date variables
  3. OPT-3519

Allow filtering by relative date variables via REST API

    XMLWordPrintable

Details

    Description

      Currently, date variable filters look like this:

      {
        "name" : "variable_Name",
        "type" : "Date",
        "filterForUndefined" : false,
        "data" : {
          "start": "2020-04-15T00:00:00",
          "end": "2020-05-20T23:59:59"
        }
      }
      

      To allow rolling and relative filters for date variables, this structure is adjusted to look like the start- and end-date filter. For that, an additional `data.type` field with the values "fixed", "relative" and "rolling" is introduced.

      In case data.type is "relative" or "rolling", data.end must be null and data.start must be an object with value and unit fields. The value field is numeric. The unit field value must be one of the values minutes, hours, days, weeks, months, quarters, or years. In case data.type is relative, "quarters" is no valid value for the unit field.

      Here is an example for a new filter:

      {
        "name" : "variable_Name",
        "type" : "Date",
        "filterForUndefined" : false,
        "data" : {
          "type" : "rolling",
          "start": {
            "value" : 0, // 0 for 'current' or >0 for 'last n completed'.
            "unit" : "days" // minutes, hours, days, weeks, months, quarters, years
          },
          "end" : null
        }
      }

      AT:

      • the backend API is adjusted as described above
      • the new API is documented on Confluence
      • There is a migration script converting old Reports to the new structure

      mgm-controller-panel

        This is the controller panel for Smart Panels app

        Attachments

          Issue Links

            Activity

              People

                Unassigned Unassigned
                sebastian.stamm Sebastian Stamm
                Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  Salesforce