Skip to content

feat: add support for EVER plugin in 43+ [DHIS2-21962] - #3344

Draft
edoardo wants to merge 8 commits into
masterfrom
feat/ever-plugin-support-DHIS2-21962
Draft

edoardo wants to merge 8 commits into
masterfrom
feat/ever-plugin-support-DHIS2-21962

Conversation

@edoardo

@edoardo edoardo commented Sep 17, 2026

Copy link
Copy Markdown
Member

Implements DHIS2-21962

Description

The new EVER app replaces Line Listing as the editor and dashboard plugin for event visualizations, and it handles both LINE_LIST and PIVOT_TABLE types.

The EVER app is only available from v43, which means we need to still use the LL app in supported previous versions.
This is done using version toggles around the code, as setting a minDHIS2Version to 2.43 in the dashboard app means we loose the ability to ship fixes for older versions.

Key differences:

  • below 2.43 — LL plugin, search result group titled "Line lists", dashboard fetches the visualization and shows its own "filters not applied" notice
  • 2.43 and above — EVER plugin, search result group titled "Event visualizations" and using different icons based on the visType, no fetch and no "filters not applied" notice since the plugin takes care of all that

For this to work, many parts needed to access apiVersion.

New specs have been added for parts previously untested.

Notes on related fixes required

  • Backend: dashboards/search currently only returns event visualization of type LINE_LIST, it should return PIVOT_TABLE ones too in 43+ (see )
  • EVER app key: with this PR the dashboard expects individual-data-visualizer as app key; this needs to be finalised and changed in EVER's d2.config.js
  • EVER plugin props: for "standalone" plugins, dashboard now sendsvisualizationId instead of a visualization object, so the EVER plugin props needs to be changed accordingly

Quality checklist

Add N/A to items that are not applicable.

  • Tested with and without global shell
  • Cypress and/or Jest tests added/updated
  • Docs added N/A
  • d2-ci dependency replaced (requires https://github.com/dhis2/analytics/pull/XXX) N/A
  • Small screen tested
  • Offline tested
  • Tester approved (name)

Screenshots

Search dropdown now shows a "Event visualizations" section in place of "Line lists":
Screenshot 2026-09-17 at 14 33 49

LL visualization rendered with the EVER plugin:
Screenshot 2026-09-17 at 11 24 25

Choose between EVER and LL app for event visualization items by version.
2.43+ uses EVER, 2.42 and lower uses LL.
This means:
- do not fetch the visualization (the plugin does it)
- always pass all filters (the plugin knows what to do with them)
- skip code that requires a visualization object (ie. errors)
Similarly to VISUALIZATION items this is to reflect the visualization type via the
icon in the list of visualizations.
Needed now that EVENT_VISUALIZATION can be both LL and PT.
@dhis2-bot

Copy link
Copy Markdown
Contributor

🚀 Deployed on https://pr-3344.dashboard.netlify.dhis2.org

@dhis2-bot
dhis2-bot temporarily deployed to netlify September 17, 2026 12:51 Inactive

@HendrikThePendric HendrikThePendric left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The quality of the code and test coverage is looking great. I left one short comment in the code but it is actually quite a fundamental point. Do we need to concern ourselves with API versions etc? I can imagine that for some older apps/plugins it is relevant to concern ourselves with app-versions and/or backend versions. But for this new app/plugin I was hoping we could just assume all is well if the app was allowed to get installed....

Comment thread src/modules/isAppVersionCompatible.js Outdated
@@ -1,4 +1,9 @@
// Minimum DHIS2 api version that returns PIVOT_TABLE event visualizations and bundles the EVER app
export const MIN_API_VERSION_FOR_EVER = 43

@HendrikThePendric HendrikThePendric Sep 17, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure about this part. I was hoping we could "outsource this part to the app-hub / d2.config file". My thoughts were:

  1. The EVER app declares its own min version and this prevents it from being installed onto an unsuitable backend
  2. So here in the dashboard-app we can assume that when the app is found, the backend version must be OK

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 The only exception I just came up with is when neither LL nor EVER is installed and we prompt the user to install an app (or get the sys admin to do so I guess). In this case the backend version is the only way to figure out which app is the best fit for the current instance.

But actually the best you could do is:

  1. If backend is below the EVER release version, the prompt for LL
  2. If backend supports EVER, then it's actually possible to install LL or EVER, so the prompt should maybe suggest both

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And if both LL and EVER are installed on an instance we agreed we'd use EVER in the dashboard-app... But still you wouldn't need a version for it....

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The MIN_API_VERSION_FOR_EVER is still needed for the parts where we want to verify the current version to decide what to show, for example in the search results list where we want to show "Event visualizations" instead of "Line lists".
This doesn't depend on the fact that the EVER app is installed, but solely on the backend version that returns PT visualizations (43+).

This actually made me think that the constant's name is confusing and perhaps is what triggered you comment.
I now dropped the constant and use the plain api version directly, since it's also unlikely we need to update the constant with a different version.

About point 2: relying on installed app to choose what to do, we don't do that for LL either.
It's always been based on api version and now is not different.
If we are on a 43+ instance, the list will contain PT visualizations regardless of wether the EVER app is installed.
There is already a mechanism in place that tells the user to install a certain version of an app to open a certain visualization.

Happy to discuss this further.

The constant is confusing because it mentions EVER and seem to indicate
you need the EVER app present.
The places where the constant is used do not care about the presence of
the EVER app, they only check against the api version.
@dhis2-bot
dhis2-bot temporarily deployed to netlify September 18, 2026 09:53 Inactive
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants