Skip to content

Commit

Permalink
feat: custom calculations (DHIS2-13871) (#1370)
Browse files Browse the repository at this point in the history
BREAKING CHANGE: requires metadata to be provided for the new EDI dimension type
  • Loading branch information
martinkrulltott authored Apr 24, 2023
1 parent 16ef1f6 commit d174e3e
Show file tree
Hide file tree
Showing 43 changed files with 3,504 additions and 167 deletions.
125 changes: 104 additions & 21 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-03-10T10:41:22.719Z\n"
"PO-Revision-Date: 2023-03-10T10:41:22.719Z\n"
"POT-Creation-Date: 2023-04-18T08:41:27.838Z\n"
"PO-Revision-Date: 2023-04-18T08:41:27.838Z\n"

msgid "view only"
msgstr "view only"
Expand Down Expand Up @@ -73,27 +73,92 @@ msgstr "This app could not retrieve required data."
msgid "Network error"
msgstr "Network error"

msgid "Data Type"
msgstr "Data Type"
msgid "Data / Edit calculation"
msgstr "Data / Edit calculation"

msgid "All types"
msgstr "All types"
msgid "Data / New calculation"
msgstr "Data / New calculation"

msgid "Remove item"
msgstr "Remove item"

msgid "Check formula"
msgstr "Check formula"

msgid "Calculation name"
msgstr "Calculation name"

msgid "Shown in table headers and chart axes/legends"
msgstr "Shown in table headers and chart axes/legends"

msgid "Delete calculation"
msgstr "Delete calculation"

msgid "Cancel"
msgstr "Cancel"

msgid "The calculation can only be saved with a valid formula"
msgstr "The calculation can only be saved with a valid formula"

msgid "Add a name to save this calculation"
msgstr "Add a name to save this calculation"

msgid "Save calculation"
msgstr "Save calculation"

msgid ""
"Are you sure you want to delete this calculation? It may be used by other "
"visualizations."
msgstr ""
"Are you sure you want to delete this calculation? It may be used by other "
"visualizations."

msgid "Yes, delete"
msgstr "Yes, delete"

msgid "Totals only"
msgstr "Totals only"

msgid "Details only"
msgstr "Details only"

msgid "Loading"
msgstr "Loading"

msgid "Data elements"
msgstr "Data elements"

msgid "Search by data element name"
msgstr "Search by data element name"

msgid "No data elements found for \"{{- searchTerm}}\""
msgstr "No data elements found for \"{{- searchTerm}}\""

msgid "No data elements found"
msgstr "No data elements found"

msgid ""
"Drag items here, or double click in the list, to start building a "
"calculation formula"
msgstr ""
"Drag items here, or double click in the list, to start building a "
"calculation formula"

msgid "Math operators"
msgstr "Math operators"

msgid "Data Type"
msgstr "Data Type"

msgid "All types"
msgstr "All types"

msgid "Disaggregation"
msgstr "Disaggregation"

msgid "No data"
msgstr "No data"

msgid "Loading"
msgstr "Loading"

msgid "Search by data item name"
msgstr "Search by data item name"

Expand All @@ -106,9 +171,6 @@ msgstr "Selected Items"
msgid "No indicators found"
msgstr "No indicators found"

msgid "No data elements found"
msgstr "No data elements found"

msgid "No data sets found"
msgstr "No data sets found"

Expand All @@ -121,9 +183,6 @@ msgstr "No program indicators found"
msgid "No indicators found for \"{{- searchTerm}}\""
msgstr "No indicators found for \"{{- searchTerm}}\""

msgid "No data elements found for \"{{- searchTerm}}\""
msgstr "No data elements found for \"{{- searchTerm}}\""

msgid "No data sets found for \"{{- searchTerm}}\""
msgstr "No data sets found for \"{{- searchTerm}}\""

Expand All @@ -136,6 +195,9 @@ msgstr "No program indicators found for \"{{- searchTerm}}\""
msgid "Nothing found for \"{{- searchTerm}}\""
msgstr "Nothing found for \"{{- searchTerm}}\""

msgid "Calculation"
msgstr "Calculation"

msgid "Metric type"
msgstr "Metric type"

Expand Down Expand Up @@ -203,9 +265,6 @@ msgstr "Delete {{fileType}}"
msgid "This {{fileType}} and related interpretations will be deleted. Continue?"
msgstr "This {{fileType}} and related interpretations will be deleted. Continue?"

msgid "Cancel"
msgstr "Cancel"

msgid "Delete"
msgstr "Delete"

Expand Down Expand Up @@ -881,9 +940,6 @@ msgstr "No indicator groups found"
msgid "Loading indicator groups"
msgstr "Loading indicator groups"

msgid "Data elements"
msgstr "Data elements"

msgid "Data element group"
msgstr "Data element group"

Expand Down Expand Up @@ -929,6 +985,33 @@ msgstr "Program indicators"
msgid "Program indicator"
msgstr "Program indicator"

msgid "Calculations"
msgstr "Calculations"

msgid "Number"
msgstr "Number"

msgid "Formula is empty. Add items to the formula from the lists on the left."
msgstr "Formula is empty. Add items to the formula from the lists on the left."

msgid "Consecutive math operators"
msgstr "Consecutive math operators"

msgid "Consecutive data elements"
msgstr "Consecutive data elements"

msgid "Starts or ends with a math operator"
msgstr "Starts or ends with a math operator"

msgid "Empty parentheses"
msgstr "Empty parentheses"

msgid "Missing right parenthesis )"
msgstr "Missing right parenthesis )"

msgid "Missing left parenthesis ("
msgstr "Missing left parenthesis ("

msgid "Extra Small"
msgstr "Extra Small"

Expand Down
5 changes: 5 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,12 @@
"dependencies": {
"@dhis2/d2-ui-rich-text": "^7.4.0",
"@dhis2/multi-calendar-dates": "1.0.0",
"@dnd-kit/core": "^6.0.7",
"@dnd-kit/sortable": "^7.0.2",
"@dnd-kit/utilities": "^3.2.1",
"@react-hook/debounce": "^4.0.0",
"classnames": "^2.3.1",
"crypto-js": "^4.1.1",
"d2-utilizr": "^0.2.16",
"d3-color": "^1.2.3",
"highcharts": "^10.2.0",
Expand Down
Loading

0 comments on commit d174e3e

Please sign in to comment.