Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: new visualization plugin #15

Merged
merged 4 commits into from
Dec 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 14 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,18 @@ Check the example script, entry `"script-example"`in `package.json`->scripts and

### About Plugins

Right now the application support 5 different plugins:
There are two ways to include visualizations:

- Using iframes: Supported by newer features of the app platform
- Using JavaScript plugins (Legacy): Maintained for backward compatibility

The reference implementation for iframes can be found in the `VisualizationContents` component. In the future, the [App Runtime Plugin component](https://developers.dhis2.org/docs/app-runtime/components/plugin/) may replace this component.

Legacy visualizations are implemented in the `LegacyVisualizationContents` component. This approach is retained for backwards compatibility and to support visualizations not yet compatible with the iframe plugin architecture.

#### Legacy Plugins

Right now the application support 5 different legacy plugins:

| Report | plugin filename |
| ------------- | --------------- |
Expand Down Expand Up @@ -117,9 +128,9 @@ You can see within the **public** folder the following folder structure:
# all the other plugins
```

Plugins have different functionality depending on the DHIS2 version, so we first get the version and then load all the scripts from the specific folder.
Plugins have different functionality depending on the DHIS2 version, so we first get the version and load the scripts from the corresponding folder.

### Adding a new version
#### Adding a new Legacy Plugin version

If you want to add a new version the first thing to do is download the .war file from the [releases page](https://releases.dhis2.org/). Pick the version you want.

Expand Down
5 changes: 4 additions & 1 deletion i18n/ar.po
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
msgid ""
msgstr ""
"Project-Id-Version: i18next-conv\n"
"POT-Creation-Date: 2023-07-14T16:28:01.835Z\n"
"POT-Creation-Date: 2024-12-16T17:57:18.316Z\n"
"PO-Revision-Date: 2018-10-25T09:02:35.143Z\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -47,6 +47,9 @@ msgstr ""
msgid "Help"
msgstr ""

msgid "Legacy plugin \"{{legacyReportType}}\" not found"
msgstr ""

msgid "Templates not found"
msgstr ""

Expand Down
7 changes: 5 additions & 2 deletions i18n/en.pot
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"POT-Creation-Date: 2023-07-14T16:28:01.835Z\n"
"PO-Revision-Date: 2023-07-14T16:28:01.835Z\n"
"POT-Creation-Date: 2024-12-16T17:57:18.316Z\n"
"PO-Revision-Date: 2024-12-16T17:57:18.316Z\n"

msgid "Select Dashboard"
msgstr ""
Expand Down Expand Up @@ -47,6 +47,9 @@ msgstr ""
msgid "Help"
msgstr ""

msgid "Legacy plugin \"{{legacyReportType}}\" not found"
msgstr ""

msgid "Templates not found"
msgstr ""

Expand Down
5 changes: 4 additions & 1 deletion i18n/es.po
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
msgid ""
msgstr ""
"Project-Id-Version: i18next-conv\n"
"POT-Creation-Date: 2023-07-14T16:28:01.835Z\n"
"POT-Creation-Date: 2024-12-16T17:57:18.316Z\n"
"PO-Revision-Date: 2018-10-25T09:02:35.143Z\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -47,6 +47,9 @@ msgstr "Volver"
msgid "Help"
msgstr "Ayuda"

msgid "Legacy plugin \"{{legacyReportType}}\" not found"
msgstr ""

msgid "Templates not found"
msgstr ""

Expand Down
5 changes: 4 additions & 1 deletion i18n/fr.po
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
msgid ""
msgstr ""
"Project-Id-Version: i18next-conv\n"
"POT-Creation-Date: 2023-07-14T16:28:01.835Z\n"
"POT-Creation-Date: 2024-12-16T17:57:18.316Z\n"
"PO-Revision-Date: 2018-10-25T09:02:35.143Z\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -47,6 +47,9 @@ msgstr ""
msgid "Help"
msgstr ""

msgid "Legacy plugin \"{{legacyReportType}}\" not found"
msgstr ""

msgid "Templates not found"
msgstr ""

Expand Down
5 changes: 4 additions & 1 deletion i18n/pt.po
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
msgid ""
msgstr ""
"Project-Id-Version: i18next-conv\n"
"POT-Creation-Date: 2023-07-14T16:28:01.835Z\n"
"POT-Creation-Date: 2024-12-16T17:57:18.316Z\n"
"PO-Revision-Date: 2018-10-25T09:02:35.143Z\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -47,6 +47,9 @@ msgstr ""
msgid "Help"
msgstr ""

msgid "Legacy plugin \"{{legacyReportType}}\" not found"
msgstr ""

msgid "Templates not found"
msgstr ""

Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"@eyeseetea/d2-api": "1.13.1",
"@eyeseetea/d2-ui-components": "2.6.11",
"@eyeseetea/feedback-component": "0.0.3",
"@krakenjs/post-robot": "^11.0.0",
"@material-ui/core": "4.12.4",
"@material-ui/icons": "4.11.3",
"@material-ui/lab": "4.0.0-alpha.60",
Expand Down
Loading
Loading