From ddcaf7c874809ba67547213ebd3e3c668e77ec6a Mon Sep 17 00:00:00 2001 From: Martin Date: Tue, 14 May 2024 09:23:20 +0300 Subject: [PATCH] fix: system / user setting for display name not respected in Org Unit tree (DHIS2-15000) (#3051) --- package.json | 2 +- src/components/DimensionsPanel/Dialogs/DialogManager.js | 8 ++++++-- yarn.lock | 8 ++++---- 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/package.json b/package.json index d0f56dd4f2..ccca4937cd 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "typescript": "^4.8.4" }, "dependencies": { - "@dhis2/analytics": "^26.6.8", + "@dhis2/analytics": "^26.6.9", "@dhis2/app-runtime": "^3.7.0", "@dhis2/app-runtime-adapter-d2": "^1.1.0", "@dhis2/app-service-datastore": "^1.0.0-beta.3", diff --git a/src/components/DimensionsPanel/Dialogs/DialogManager.js b/src/components/DimensionsPanel/Dialogs/DialogManager.js index e3844578d0..a7f59bbea4 100644 --- a/src/components/DimensionsPanel/Dialogs/DialogManager.js +++ b/src/components/DimensionsPanel/Dialogs/DialogManager.js @@ -234,7 +234,7 @@ export class DialogManager extends Component { // The OU content is persisted as mounted in order // to cache the org unit tree data - renderPersistedContent = (dimensionProps) => { + renderPersistedContent = (dimensionProps, displayNameProperty) => { const { ouIds, metadata, parentGraphMap, dialogId } = this.props if (this.state.ouMounted) { @@ -253,6 +253,7 @@ export class DialogManager extends Component { roots={this.props.rootOrgUnits.map( (rootOrgUnit) => rootOrgUnit.id )} + displayNameProp={displayNameProperty} {...dimensionProps} /> @@ -455,7 +456,10 @@ export class DialogManager extends Component { return ( - {this.renderPersistedContent(dimensionProps)} + {this.renderPersistedContent( + dimensionProps, + displayNameProperty + )} {dialogId && dynamicContent()} ) diff --git a/yarn.lock b/yarn.lock index 4b576076b7..6e2a7e522a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2028,10 +2028,10 @@ classnames "^2.3.1" prop-types "^15.7.2" -"@dhis2/analytics@^26.6.8": - version "26.6.8" - resolved "https://registry.yarnpkg.com/@dhis2/analytics/-/analytics-26.6.8.tgz#859f8086198664a9ea14cea149ce7bdf449a19a2" - integrity sha512-9l8001MAx+q8K1Qklui8pfF0rrv3MSLA1dEtM93rBODSsQwRE9pbt5wN44i9+n7nAgc7iItBehAQ1hMJ8j7yHg== +"@dhis2/analytics@^26.6.9": + version "26.6.9" + resolved "https://registry.yarnpkg.com/@dhis2/analytics/-/analytics-26.6.9.tgz#932847c4bee3dd720d5d0b872c6b11eeae8b260c" + integrity sha512-AcU5FKH1Rmi8GdgqdJ1aOPqTKhztLafhzKNvGBdb5rSNR8/KS2djyTxxPhL0fdusu+1Rc04RFSkOLajq3ChVrQ== dependencies: "@dhis2/d2-ui-rich-text" "^7.4.1" "@dhis2/multi-calendar-dates" "1.0.0"