From e032d5004de91ee30fff89a53e273faf52bea234 Mon Sep 17 00:00:00 2001 From: Simona Domnisoru Date: Wed, 9 Oct 2024 14:24:40 +0200 Subject: [PATCH 01/45] feat: [DHIS2-15238] show and filter on assigned user in program stage WL (#3821) --- .../EventWorkingListsDev.js | 2 +- .../EventWorkingListsUser.js | 2 +- .../EventWorkingLists/sharedSteps.js | 18 +++++ .../TeiWorkingListsDev.feature | 4 +- .../TeiWorkingListsDev/TeiWorkingListsDev.js | 2 +- .../TeiWorkingListsUser.feature | 38 +++++++++- .../TeiWorkingListsUser.js | 63 ++++++++++++----- .../TeiWorkingLists/sharedSteps.js | 18 +++++ cypress/e2e/WorkingLists/sharedSteps.js | 32 --------- docs/user/using-the-capture-app.md | 4 +- .../Setup/TeiWorkingListsSetup.component.js | 2 +- .../Setup/hooks/useDefaultColumnConfig.js | 16 ++++- .../Setup/hooks/useFiltersOnly.js | 21 ++++-- .../Setup/hooks/useProgramStageFilters.js | 27 ++++++- .../additionalFiltersConvertor.js | 3 + .../templates/buildArgumentsForTemplate.js | 70 +++++++++++++++---- 16 files changed, 234 insertions(+), 88 deletions(-) create mode 100644 cypress/e2e/WorkingLists/EventWorkingLists/sharedSteps.js create mode 100644 cypress/e2e/WorkingLists/TeiWorkingLists/sharedSteps.js diff --git a/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsDev/EventWorkingListsDev.js b/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsDev/EventWorkingListsDev.js index 0b507921ea..c633a34430 100644 --- a/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsDev/EventWorkingListsDev.js +++ b/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsDev/EventWorkingListsDev.js @@ -1,5 +1,5 @@ import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'; -import '../../sharedSteps'; +import '../sharedSteps'; beforeEach(() => { // Disable cache for chromium browsers to force the api to be called diff --git a/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsUser/EventWorkingListsUser.js b/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsUser/EventWorkingListsUser.js index c5cb9fc63b..b1a6158642 100644 --- a/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsUser/EventWorkingListsUser.js +++ b/cypress/e2e/WorkingLists/EventWorkingLists/EventWorkingListsUser/EventWorkingListsUser.js @@ -1,6 +1,6 @@ import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'; import { v4 as uuid } from 'uuid'; -import '../../sharedSteps'; +import '../sharedSteps'; import { getCurrentYear, combineDataAndYear } from '../../../../support/date'; Given('you open the main page with Ngelehun and malaria case context', () => { diff --git a/cypress/e2e/WorkingLists/EventWorkingLists/sharedSteps.js b/cypress/e2e/WorkingLists/EventWorkingLists/sharedSteps.js new file mode 100644 index 0000000000..f2fdb84848 --- /dev/null +++ b/cypress/e2e/WorkingLists/EventWorkingLists/sharedSteps.js @@ -0,0 +1,18 @@ +import { When, Then } from '@badeball/cypress-cucumber-preprocessor'; +import '../sharedSteps'; + +When('you set the assignee filter to anyone', () => { + cy.get('[data-test="event-working-lists"]') + .contains('Assigned to') + .click(); + + cy.get('[data-test="list-view-filter-contents"]') + .contains('Anyone') + .click(); +}); + +Then('the assigned to filter button should show that the anyone filter is in effect', () => { + cy.get('[data-test="event-working-lists"]') + .contains('Assigned to: Anyone') + .should('exist'); +}); diff --git a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.feature b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.feature index 1e0857292e..981ef03ca1 100644 --- a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.feature +++ b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.feature @@ -27,10 +27,10 @@ Scenario: Show only teis with active enrollments and unassinged events using the Given you open the main page with Ngelehun and Malaria focus investigation context When you set the enrollment status filter to active And you apply the enrollment status filter -And you set the assginee filter to none +And you set the assginee filter to None And you apply the assignee filter Then the enrollment status filter button should show that the active filter is in effect -And the assignee filter button should show that unassigned filter is in effect +And the assignee filter button should show that None filter is in effect And teis with active enrollments and unassigned events should be retrieved from the api And the list should display the teis retrieved from the api And for a tracker program the page navigation should show that you are on the first page diff --git a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.js b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.js index 5a0dd69651..050be8508b 100644 --- a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.js +++ b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsDev/TeiWorkingListsDev.js @@ -1,5 +1,5 @@ import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'; -import '../../sharedSteps'; +import '../sharedSteps'; beforeEach(() => { // Disable cache for chromium browsers to force the api to be called diff --git a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature index a80e857fcd..3bf9fbfaf8 100644 --- a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature +++ b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature @@ -37,10 +37,10 @@ Scenario: Show only teis with active enrollments and unassinged events using the Given you open the main page with Ngelehun and Malaria focus investigation context When you set the enrollment status filter to active And you apply the current filter -And you set the assginee filter to none +And you set the assginee filter to None And you apply the current filter Then the enrollment status filter button should show that the active filter is in effect -And the assignee filter button should show that unassigned filter is in effect +And the assignee filter button should show that None filter is in effect And the list should display teis with an active enrollment and unassinged events And rows per page should be set to 15 And for a tracker program the page navigation should show that you are on the first page @@ -201,6 +201,40 @@ And you set the event visit date to Today And you apply the current filter Then the working list is empty +Scenario: The user can filter the Foci response assigned events +Given you open the main page with Ngelehun and Malaria focus investigation context +When you open the program stage filters from the more filters dropdown menu +And you select the Foci response program stage +And you apply the current filter +And you set the assginee filter to Anyone +And you apply the current filter +Then the assignee filter button should show that Anyone filter is in effect +And the assignee column is displayed + +Scenario: The assigned user data is kept when switching between working list types +Given you open the main page with Ngelehun and Malaria focus investigation context +And you filter by assigned Foci investigation & classification events +And the assignee filter button should show that Anyone filter is in effect +When you remove the program stage filter +Then you don't see program stage working list events +And the assignee filter button should show that Anyone filter is in effect +When you set the assginee filter to None +And you apply the current filter +Then the assignee filter button should show that None filter is in effect +When you open the program stage filters from the more filters dropdown menu +And you select the Foci response program stage +And you apply the current filter +Then the assignee filter button should show that None filter is in effect + +@v>=40 +Scenario: The user can create and delete a program stage working list for Foci investigation & classification assigned events +Given you open the main page with Ngelehun and Malaria focus investigation context +And you filter by assigned Foci investigation & classification events +When you save the list with the name Custom Program stage list +Then the new Custom Program stage list is created +And you delete the name Custom Program stage list +Then the Custom Program stage list is deleted + @v>=40 Scenario: The user creates, updates and deletes a Program stage custom working list Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context diff --git a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js index 9026a15f3d..260e312422 100644 --- a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js +++ b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js @@ -1,6 +1,6 @@ import { Given, When, Then, defineStep as And } from '@badeball/cypress-cucumber-preprocessor'; import { v4 as uuid } from 'uuid'; -import '../../sharedSteps'; +import '../sharedSteps'; const cleanUpIfApplicable = (programId) => { cy.buildApiUrl(`programStageWorkingLists?filter=program.id:eq:${programId}&fields=id,displayName`) @@ -198,22 +198,6 @@ When('you set the WHOMCH Smoking filter to No', () => { .click(); }); -When('you set the assginee filter to none', () => { - cy.get('[data-test="tei-working-lists"]') - .contains('Assigned to') - .click(); - - cy.get('[data-test="list-view-filter-contents"]') - .contains('None') - .click(); -}); - -Then('the assignee filter button should show that unassigned filter is in effect', () => { - cy.get('[data-test="tei-working-lists"]') - .contains('Assigned to: None') - .should('exist'); -}); - Then('the list should display teis with an active enrollment and unassinged events', () => { const ids = [ 'ZDA984904', @@ -627,7 +611,7 @@ When('you select a data element columns and save from the column selector', () = }); Then('you see data elements specific filters and columns', () => { - cy.get('[data-test="filter-button-container-DX4LVYeP7bw"]') + cy.get('[data-test="filter-button-container-assignee"]') .should('exist'); cy.get('[data-test="tei-working-lists"]') .should('exist'); @@ -866,3 +850,46 @@ Then('the working list is empty', () => { .contains('No items to display') .click(); }); + +Then('the assignee column is displayed', () => { + cy.get('[data-test="dhis2-uicore-tablehead"]') + .contains('Assigned to') + .should('exist'); + + cy.get('[data-test="dhis2-uicore-tablebody"]') + .contains('Tracker demo User (tracker)') + .should('exist'); + + cy.get('[data-test="tei-working-lists"]') + .find('tr') + .should('have.length', 2); +}); + +And('you filter by assigned Foci investigation & classification events', () => { + cy.get('[data-test="tei-working-lists"]') + .within(() => { + cy.contains('More filters') + .click(); + }); + + cy.get('[data-test="more-filters-menu"]') + .within(() => cy.contains('Program stage').click()); + + cy.get('[data-test="list-view-filter-contents"]') + .contains('Foci investigation & classification') + .click(); + + cy.get('[data-test="list-view-filter-apply-button"]') + .click(); + + cy.get('[data-test="tei-working-lists"]') + .contains('Assigned to') + .click(); + + cy.get('[data-test="list-view-filter-contents"]') + .contains('Anyone') + .click(); + + cy.get('[data-test="list-view-filter-apply-button"]') + .click(); +}); diff --git a/cypress/e2e/WorkingLists/TeiWorkingLists/sharedSteps.js b/cypress/e2e/WorkingLists/TeiWorkingLists/sharedSteps.js new file mode 100644 index 0000000000..190c14624b --- /dev/null +++ b/cypress/e2e/WorkingLists/TeiWorkingLists/sharedSteps.js @@ -0,0 +1,18 @@ +import { When, Then } from '@badeball/cypress-cucumber-preprocessor'; +import '../sharedSteps'; + +When(/^you set the assginee filter to (.*)$/, (assignedUser) => { + cy.get('[data-test="tei-working-lists"]') + .contains('Assigned to') + .click(); + + cy.get('[data-test="list-view-filter-contents"]') + .contains(assignedUser) + .click(); +}); + +Then(/^the assignee filter button should show that (.*) filter is in effect/, (assignedUser) => { + cy.get('[data-test="tei-working-lists"]') + .contains(`Assigned to: ${assignedUser}`) + .should('exist'); +}); diff --git a/cypress/e2e/WorkingLists/sharedSteps.js b/cypress/e2e/WorkingLists/sharedSteps.js index c28bdb5ccb..dbe0bb9928 100644 --- a/cypress/e2e/WorkingLists/sharedSteps.js +++ b/cypress/e2e/WorkingLists/sharedSteps.js @@ -12,22 +12,6 @@ Then('for a tracker program the page navigation should show that you are on the .should('exist'); }); -Then('the assigned to filter button should show that the anyone filter is in effect', () => { - cy.get('[data-test="event-working-lists"]') - .contains('Assigned to: Anyone') - .should('exist'); -}); - -When('you set the assignee filter to anyone', () => { - cy.get('[data-test="event-working-lists"]') - .contains('Assigned to') - .click(); - - cy.get('[data-test="list-view-filter-contents"]') - .contains('Anyone') - .click(); -}); - When('you set the status filter to active', () => { cy.get('[data-test="event-working-lists"]') .contains('Status') @@ -98,16 +82,6 @@ When('you set the enrollment status filter to active', () => { .click(); }); -When('you set the assginee filter to none', () => { - cy.get('[data-test="tei-working-lists"]') - .contains('Assigned to') - .click(); - - cy.get('[data-test="list-view-filter-contents"]') - .contains('None') - .click(); -}); - When(/^you set the first name filter to (.*)$/, (name) => { cy.get('[data-test="tei-working-lists"]') .contains('First name') @@ -147,12 +121,6 @@ Then('rows per page should be set to 15', () => { .should('exist'); }); -Then('the assignee filter button should show that unassigned filter is in effect', () => { - cy.get('[data-test="tei-working-lists"]') - .contains('Assigned to: None') - .should('exist'); -}); - When('you change rows per page to 10', () => { cy.get('div[data-test="rows-per-page-selector"]') .click() diff --git a/docs/user/using-the-capture-app.md b/docs/user/using-the-capture-app.md index 1d64b1a4e2..651e9f7eb0 100644 --- a/docs/user/using-the-capture-app.md +++ b/docs/user/using-the-capture-app.md @@ -594,7 +594,7 @@ Events can be assigned to users. This feature must be enabled per program. 5. Search for and select the user you would like to reassign the event to. Click the **Save** button. -### Assignee in the event list { #capture_user_assignment_event_list } +### Assignee in the event list In the event list you will be able to view the assignee per event. Moreover, you can sort and filter the list by the assignee. @@ -804,7 +804,7 @@ You can show data elements from a single stage in a working list. Select the "Pr ![](resources/images/program_stage_working_list.png) -The tracker program stage list can be [filtered](#filter-the-list), [sorted](#sort-the-list), [modified](#modify-the-list-layout), [saved](#capture_view_save), [updated](#capture_view_update), [deleted](#capture_view_delete) and [shared](#capture_view_share) in the same way as other working lists. +The tracker program stage list can be [filtered](#filter-the-list), [sorted](#sort-the-list), [modified](#modify-the-list-layout), [saved](#capture_view_save), [updated](#capture_view_update), [deleted](#capture_view_delete) and [shared](#capture_view_share) in the same way as other working lists. Additionally, the program stage list can be [filtered by assignee](#assignee-in-the-event-list), just like an event program list. ## Implementer / administrator info { #implementer_info } diff --git a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/TeiWorkingListsSetup.component.js b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/TeiWorkingListsSetup.component.js index f2dfe2809b..b59d0233cd 100644 --- a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/TeiWorkingListsSetup.component.js +++ b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/TeiWorkingListsSetup.component.js @@ -61,7 +61,7 @@ export const TeiWorkingListsSetup = ({ const prevTemplateId = useRef(currentTemplateId); const defaultColumns = useDefaultColumnConfig(program, orgUnitId, programStageId); const columns = useColumns(customColumnOrder, defaultColumns); - const filtersOnly = useFiltersOnly(program); + const filtersOnly = useFiltersOnly(program, programStageId); const programStageFiltersOnly = useProgramStageFilters(program, programStageId); const staticTemplates = useStaticTemplates( storedTemplates?.find(storedTemplate => storedTemplate.isDefault && storedTemplate.isAltered), diff --git a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useDefaultColumnConfig.js b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useDefaultColumnConfig.js index 3f6b926761..f15ade1d0e 100644 --- a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useDefaultColumnConfig.js +++ b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useDefaultColumnConfig.js @@ -36,13 +36,13 @@ const getProgramStageMainConfig = (programStage): Array => [ { id: ADDITIONAL_FILTERS.status, - visible: false, + visible: true, type: dataElementTypes.TEXT, header: i18n.t(ADDITIONAL_FILTERS_LABELS.status), }, { id: ADDITIONAL_FILTERS.occurredAt, - visible: false, + visible: true, type: dataElementTypes.DATE, header: programStage.stageForm.getLabel('occurredAt') || i18n.t(ADDITIONAL_FILTERS_LABELS.occurredAt), }, @@ -50,7 +50,7 @@ const getProgramStageMainConfig = (programStage): Array => ? [ { id: ADDITIONAL_FILTERS.scheduledAt, - visible: false, + visible: true, type: dataElementTypes.DATE, header: programStage.stageForm.getLabel('scheduledAt') || @@ -58,6 +58,16 @@ const getProgramStageMainConfig = (programStage): Array => }, ] : []), + ...(programStage.enableUserAssignment + ? [ + { + id: ADDITIONAL_FILTERS.assignedUser, + visible: true, + type: dataElementTypes.ASSIGNEE, + header: i18n.t(ADDITIONAL_FILTERS_LABELS.assignee), + }, + ] + : []), ].map(field => ({ ...field, mainProperty: true, diff --git a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useFiltersOnly.js b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useFiltersOnly.js index 155d6b9775..76c4ef14db 100644 --- a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useFiltersOnly.js +++ b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useFiltersOnly.js @@ -4,12 +4,13 @@ import i18n from '@dhis2/d2-i18n'; import { dataElementTypes, type TrackerProgram } from '../../../../../metaData'; import { MAIN_FILTERS } from '../../constants'; -export const useFiltersOnly = ({ - enrollment: { enrollmentDateLabel, incidentDateLabel, showIncidentDate }, - stages, -}: TrackerProgram) => +export const useFiltersOnly = ( + { enrollment: { enrollmentDateLabel, incidentDateLabel, showIncidentDate }, stages }: TrackerProgram, + programStageId?: string, +) => useMemo(() => { - const enableUserAssignment = Array.from(stages.values()).find(stage => stage.enableUserAssignment); + const enableUserAssignment = + !programStageId && Array.from(stages.values()).find(stage => stage.enableUserAssignment); return [ { id: MAIN_FILTERS.PROGRAM_STATUS, @@ -80,9 +81,15 @@ export const useFiltersOnly = ({ id: MAIN_FILTERS.ASSIGNEE, type: dataElementTypes.ASSIGNEE, header: i18n.t('Assigned to'), - transformRecordsFilter: (rawFilter: Object) => rawFilter, + transformRecordsFilter: (rawFilter: Object) => { + const { assignedUser, assignedUserMode } = rawFilter; + return { + assignedUserMode, + ...(assignedUser && { assignedUser }), + }; + }, }, ] : []), ]; - }, [enrollmentDateLabel, incidentDateLabel, showIncidentDate, stages]); + }, [enrollmentDateLabel, incidentDateLabel, showIncidentDate, stages, programStageId]); diff --git a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useProgramStageFilters.js b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useProgramStageFilters.js index d17f1be4b1..108f76bc0e 100644 --- a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useProgramStageFilters.js +++ b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/Setup/hooks/useProgramStageFilters.js @@ -2,7 +2,7 @@ import { useMemo } from 'react'; import i18n from '@dhis2/d2-i18n'; import { statusTypes, translatedStatusTypes } from 'capture-core/events/statusTypes'; -import { type TrackerProgram, type ProgramStage } from '../../../../../metaData'; +import { type TrackerProgram, type ProgramStage, dataElementTypes } from '../../../../../metaData'; import { ADDITIONAL_FILTERS, ADDITIONAL_FILTERS_LABELS } from '../../helpers'; const useProgramStageData = (programStageId, stages) => @@ -13,12 +13,14 @@ const useProgramStageData = (programStageId, stages) => hideDueDate: programStage.hideDueDate, occurredAtLabel: programStage.stageForm.getLabel('occurredAt'), scheduledAtLabel: programStage.stageForm.getLabel('scheduledAt'), + enableUserAssignment: programStage.enableUserAssignment, }; } return { occurredAtLabel: i18n.t(ADDITIONAL_FILTERS_LABELS.occurredAt), scheduledAtLabel: i18n.t(ADDITIONAL_FILTERS_LABELS.scheduledAt), hideDueDate: undefined, + enableUserAssignment: false, }; }, [programStageId, stages]); @@ -33,7 +35,10 @@ const useProgramStageDropdowOptions = stages => ); export const useProgramStageFilters = ({ stages }: TrackerProgram, programStageId?: string) => { - const { hideDueDate, occurredAtLabel, scheduledAtLabel } = useProgramStageData(programStageId, stages); + const { hideDueDate, occurredAtLabel, scheduledAtLabel, enableUserAssignment } = useProgramStageData( + programStageId, + stages, + ); const options: Array<{ text: string, value: string }> = useProgramStageDropdowOptions(stages); return useMemo(() => { @@ -117,6 +122,22 @@ export const useProgramStageFilters = ({ stages }: TrackerProgram, programStageI }, ] : []), + ...(enableUserAssignment + ? [ + { + id: ADDITIONAL_FILTERS.assignedUser, + type: dataElementTypes.ASSIGNEE, + header: ADDITIONAL_FILTERS_LABELS.assignee, + transformRecordsFilter: (rawFilter: Object) => { + const { assignedUser, assignedUserMode } = rawFilter; + return { + assignedUserMode, + ...(assignedUser && { assignedUser }), + }; + }, + }, + ] + : []), ]; - }, [programStageId, occurredAtLabel, scheduledAtLabel, hideDueDate, options]); + }, [programStageId, occurredAtLabel, scheduledAtLabel, hideDueDate, options, enableUserAssignment]); }; diff --git a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/eventFilters/additionalFiltersConvertor.js b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/eventFilters/additionalFiltersConvertor.js index 72350fbdf3..ac209da460 100644 --- a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/eventFilters/additionalFiltersConvertor.js +++ b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/eventFilters/additionalFiltersConvertor.js @@ -4,6 +4,7 @@ export const ADDITIONAL_FILTERS = { occurredAt: 'eventOccurredAt', scheduledAt: 'scheduledAt', status: 'status', + assignedUser: 'assignee', }; export const ADDITIONAL_FILTERS_LABELS = { @@ -11,10 +12,12 @@ export const ADDITIONAL_FILTERS_LABELS = { occurredAt: 'Report date', scheduledAt: 'Scheduled date', status: 'Event status', + assignee: 'Assigned to', }; export const ADDITIONAL_FILTERS_API_NAME = { [ADDITIONAL_FILTERS.occurredAt]: 'occurredAt', + [ADDITIONAL_FILTERS.assignedUser]: 'assignedUser', }; export const getFilterApiName = (clientFilter: string) => ADDITIONAL_FILTERS_API_NAME[clientFilter] || clientFilter; diff --git a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/templates/buildArgumentsForTemplate.js b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/templates/buildArgumentsForTemplate.js index 9d16721c2e..8f8014a1a1 100644 --- a/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/templates/buildArgumentsForTemplate.js +++ b/src/core_modules/capture-core/components/WorkingLists/TeiWorkingLists/helpers/templates/buildArgumentsForTemplate.js @@ -9,6 +9,51 @@ import type { TeiWorkingListsColumnConfigs, ApiTrackerQueryCriteria } from '../. import type { FiltersData } from '../../../WorkingListsBase'; import { getOrderQueryArgs } from '../../epics'; +const buildArguments = ({ + filters, + programStageFiltersOnly, + columns, + programStageId, + mainFiltersConverted, +}: { + filters?: FiltersData, + programStageFiltersOnly: Array<{ id: string, type: string }>, + columns: TeiWorkingListsColumnConfigs, + programStageId?: string, + mainFiltersConverted: Object, +}) => { + if (!programStageId) { + return { + assignedUserMode: mainFiltersConverted.assignedUserMode, + assignedUsers: mainFiltersConverted.assignedUsers, + attributesColumns: columns, + dataFilters: [], + status: undefined, + eventOccurredAt: undefined, + scheduledAt: undefined, + }; + } + + const additionalFiltersConverted = convertMainFilters({ + filters, + mainFilters: programStageFiltersOnly, + }); + const { status, eventOccurredAt, scheduledAt } = additionalFiltersConverted; + return { + status, + eventOccurredAt, + scheduledAt, + assignedUserMode: additionalFiltersConverted.assignedUserMode, + assignedUsers: additionalFiltersConverted.assignedUsers, + attributesColumns: columns.filter(column => !column.additionalColumn), + dataFilters: convertToEventFilterQuery({ + filters, + mainFilters: programStageFiltersOnly, + dataElementsValueFilters: columns.filter(column => column.additionalColumn), + }), + }; +}; + export const buildArgumentsForTemplate = ({ filters, filtersOnly, @@ -28,25 +73,20 @@ export const buildArgumentsForTemplate = ({ programId: string, programStageId?: string, }) => { - const { programStatus, occurredAt, enrolledAt, assignedUserMode, assignedUsers, followUp } = convertMainFilters({ + const mainFiltersConverted = convertMainFilters({ filters, mainFilters: filtersOnly, }); - const { status, eventOccurredAt, scheduledAt } = convertMainFilters({ - filters, - mainFilters: programStageFiltersOnly, - }); - const attributeValueFilters = convertToTEIFilterAttributes({ - filters, - attributeValueFilters: programStageId ? columns.filter(column => !column.additionalColumn) : columns, - }); - const dataFilters = programStageId - ? convertToEventFilterQuery({ + const { programStatus, occurredAt, enrolledAt, followUp } = mainFiltersConverted; + const { assignedUserMode, assignedUsers, attributesColumns, dataFilters, status, eventOccurredAt, scheduledAt } = + buildArguments({ filters, - mainFilters: programStageFiltersOnly, - dataElementsValueFilters: columns.filter(column => column.additionalColumn), - }) - : []; + programStageFiltersOnly, + columns, + programStageId, + mainFiltersConverted, + }); + const attributeValueFilters = convertToTEIFilterAttributes({ filters, attributeValueFilters: attributesColumns }); const visibleColumnIds: Array = columns.filter(({ visible }) => visible).map(({ id }) => id); const criteria: ApiTrackerQueryCriteria = { programStatus, From 06d5603dcb621521d7e70eb02dea92fea1eec2da Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Wed, 9 Oct 2024 12:29:05 +0000 Subject: [PATCH 02/45] chore(release): cut 101.9.0 [skip release] # [101.9.0](https://github.com/dhis2/capture-app/compare/v101.8.0...v101.9.0) (2024-10-09) ### Features * [DHIS2-15238] show and filter on assigned user in program stage WL ([#3821](https://github.com/dhis2/capture-app/issues/3821)) ([e032d50](https://github.com/dhis2/capture-app/commit/e032d5004de91ee30fff89a53e273faf52bea234)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 89d693d458..07ffe6de6b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +# [101.9.0](https://github.com/dhis2/capture-app/compare/v101.8.0...v101.9.0) (2024-10-09) + + +### Features + +* [DHIS2-15238] show and filter on assigned user in program stage WL ([#3821](https://github.com/dhis2/capture-app/issues/3821)) ([e032d50](https://github.com/dhis2/capture-app/commit/e032d5004de91ee30fff89a53e273faf52bea234)) + # [101.8.0](https://github.com/dhis2/capture-app/compare/v101.7.4...v101.8.0) (2024-10-08) diff --git a/package.json b/package.json index a96b8b1864..adcf77dda8 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.8.0", + "version": "101.9.0", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.8.0", + "@dhis2/rules-engine-javascript": "101.9.0", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index a3ef56b41b..736c8ceabc 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.8.0", + "version": "101.9.0", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From 2603f342d3e34e1f4ac631797c60b93e2aa3606a Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Sun, 13 Oct 2024 03:44:44 +0200 Subject: [PATCH 03/45] fix(translations): sync translations from transifex (master) Automatically merged. --- i18n/ar_IQ.po | 34 ++++++++++++++++++---------------- i18n/ckb.po | 34 ++++++++++++++++++---------------- i18n/es_419.po | 17 +---------------- i18n/km.po | 34 ++++++++++++++++++---------------- i18n/prs.po | 17 +---------------- i18n/ps.po | 17 +---------------- i18n/pt.po | 14 +++----------- i18n/pt_BR.po | 17 +---------------- i18n/ro.po | 9 --------- i18n/ru.po | 9 --------- i18n/sv.po | 34 ++++++++++++++++++---------------- i18n/tet.po | 34 ++++++++++++++++++---------------- i18n/tg.po | 34 ++++++++++++++++++---------------- i18n/uk.po | 17 +---------------- i18n/ur.po | 17 +---------------- i18n/uz_UZ_Cyrl.po | 9 --------- i18n/uz_UZ_Latn.po | 17 +---------------- i18n/zh_CN.po | 9 --------- 18 files changed, 118 insertions(+), 255 deletions(-) diff --git a/i18n/ar_IQ.po b/i18n/ar_IQ.po index cbeeaaf0e3..13422d6d58 100644 --- a/i18n/ar_IQ.po +++ b/i18n/ar_IQ.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: KRG HIS , 2024\n" "Language-Team: Arabic (Iraq) (https://app.transifex.com/hisp-uio/teams/100509/ar_IQ/)\n" @@ -602,15 +602,6 @@ msgstr "البرنامج غير موجود" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "متصل" - -msgid "Offline" -msgstr "غير متصل" - -msgid "Syncing" -msgstr "تزامن" - msgid "Add note" msgstr "" @@ -1251,12 +1242,6 @@ msgstr "" msgid "Follow-up" msgstr "" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "تم الإلغاء" @@ -1482,6 +1467,23 @@ msgstr "" msgid "New {{ eventName }} event" msgstr "" +msgid "An error occurred while deleting the event" +msgstr "" + +msgid "" +"Deleting an event is permanent and cannot be undone. Are you sure you want " +"to delete this event?" +msgstr "" + +msgid "An error occurred when updating event status" +msgstr "" + +msgid "Unskip" +msgstr "" + +msgid "Skip" +msgstr "" + msgid "To open this event, please wait until saving is complete" msgstr "" diff --git a/i18n/ckb.po b/i18n/ckb.po index 1a33d92772..851ae43bd0 100644 --- a/i18n/ckb.po +++ b/i18n/ckb.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Central Kurdish (https://app.transifex.com/hisp-uio/teams/100509/ckb/)\n" @@ -607,15 +607,6 @@ msgstr "پرۆگرامەکە بوونی نیە" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "ئۆنڵاین" - -msgid "Offline" -msgstr "ئۆفڵاین" - -msgid "Syncing" -msgstr "هاوتاکردن" - msgid "Add note" msgstr "" @@ -1254,12 +1245,6 @@ msgstr "" msgid "Follow-up" msgstr "" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "" @@ -1477,6 +1462,23 @@ msgstr "" msgid "New {{ eventName }} event" msgstr "" +msgid "An error occurred while deleting the event" +msgstr "" + +msgid "" +"Deleting an event is permanent and cannot be undone. Are you sure you want " +"to delete this event?" +msgstr "" + +msgid "An error occurred when updating event status" +msgstr "" + +msgid "Unskip" +msgstr "" + +msgid "Skip" +msgstr "" + msgid "To open this event, please wait until saving is complete" msgstr "" diff --git a/i18n/es_419.po b/i18n/es_419.po index 1007032b9c..f5afa49b7d 100644 --- a/i18n/es_419.po +++ b/i18n/es_419.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Jaime Bosque , 2024\n" "Language-Team: Spanish (Latin America) (https://app.transifex.com/hisp-uio/teams/100509/es_419/)\n" @@ -617,15 +617,6 @@ msgstr "El programa no existe" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "En línea" - -msgid "Offline" -msgstr "Offline" - -msgid "Syncing" -msgstr "Sincronizando" - msgid "Add note" msgstr "Añadir nota" @@ -1293,12 +1284,6 @@ msgstr "" msgid "Follow-up" msgstr "" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "Cancelar" diff --git a/i18n/km.po b/i18n/km.po index 04fa91cdc5..ec9c3dac3e 100644 --- a/i18n/km.po +++ b/i18n/km.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Khmer (https://app.transifex.com/hisp-uio/teams/100509/km/)\n" @@ -589,15 +589,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "លើបណ្ដាញអិនធឺរណែត" - -msgid "Offline" -msgstr "ក្រៅ​បណ្ដាញអិនធឺរណែត" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "បន្ថែមការកត់ចំណាំ" @@ -1233,12 +1224,6 @@ msgstr "" msgid "Follow-up" msgstr "តាមដាន" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "បានលុបចោល" @@ -1454,6 +1439,23 @@ msgstr "" msgid "New {{ eventName }} event" msgstr "" +msgid "An error occurred while deleting the event" +msgstr "" + +msgid "" +"Deleting an event is permanent and cannot be undone. Are you sure you want " +"to delete this event?" +msgstr "" + +msgid "An error occurred when updating event status" +msgstr "" + +msgid "Unskip" +msgstr "" + +msgid "Skip" +msgstr "" + msgid "To open this event, please wait until saving is complete" msgstr "" diff --git a/i18n/prs.po b/i18n/prs.po index 89f3234f12..9b6cbf8306 100644 --- a/i18n/prs.po +++ b/i18n/prs.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Persian (Afghanistan) (https://app.transifex.com/hisp-uio/teams/100509/fa_AF/)\n" @@ -588,15 +588,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "آنلاین" - -msgid "Offline" -msgstr "آفلاین" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "افزودن یاداشت" @@ -1233,12 +1224,6 @@ msgstr "" msgid "Follow-up" msgstr "تعقیب کردن" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "" diff --git a/i18n/ps.po b/i18n/ps.po index 31f1707af2..38518df9a7 100644 --- a/i18n/ps.po +++ b/i18n/ps.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Pashto (https://app.transifex.com/hisp-uio/teams/100509/ps/)\n" @@ -589,15 +589,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "په لیکه کې دی" - -msgid "Offline" -msgstr "په لیکه کې نشته" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "نوټ ور اضافه کړئ" @@ -1234,12 +1225,6 @@ msgstr "" msgid "Follow-up" msgstr "" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "لغوه شوی" diff --git a/i18n/pt.po b/i18n/pt.po index 7531dccfa4..45ada7e10f 100644 --- a/i18n/pt.po +++ b/i18n/pt.po @@ -7,13 +7,14 @@ # Sheila André , 2024 # Ge Joao , 2024 # Viktor Varland , 2024 +# Juan M Alcantara Acosta , 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" "POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Viktor Varland , 2024\n" +"Last-Translator: Juan M Alcantara Acosta , 2024\n" "Language-Team: Portuguese (https://app.transifex.com/hisp-uio/teams/100509/pt/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -616,15 +617,6 @@ msgstr "Programa não existe" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Ligado" - -msgid "Offline" -msgstr "Desligado" - -msgid "Syncing" -msgstr "Sincronizando" - msgid "Add note" msgstr "Adicionar uma nota" @@ -1594,7 +1586,7 @@ msgid "Scheduled" msgstr "Agendado" msgid "Changelog" -msgstr "" +msgstr "Registo de mudanças" msgid "No changes to display" msgstr "" diff --git a/i18n/pt_BR.po b/i18n/pt_BR.po index 00cd51c882..f33904fb18 100644 --- a/i18n/pt_BR.po +++ b/i18n/pt_BR.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Thiago Rocha, 2024\n" "Language-Team: Portuguese (Brazil) (https://app.transifex.com/hisp-uio/teams/100509/pt_BR/)\n" @@ -592,15 +592,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Ligado" - -msgid "Offline" -msgstr "Desligado" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "Adicionar uma nota" @@ -1238,12 +1229,6 @@ msgstr "" msgid "Follow-up" msgstr "Seguimento" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "Cancelado" diff --git a/i18n/ro.po b/i18n/ro.po index 5c64022113..1308197957 100644 --- a/i18n/ro.po +++ b/i18n/ro.po @@ -603,15 +603,6 @@ msgstr "Programul nu există" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Online" - -msgid "Offline" -msgstr "Offline" - -msgid "Syncing" -msgstr "Sincronizare" - msgid "Add note" msgstr "" diff --git a/i18n/ru.po b/i18n/ru.po index 01896cce66..3182a61401 100644 --- a/i18n/ru.po +++ b/i18n/ru.po @@ -615,15 +615,6 @@ msgid "Selected program is invalid for selected organisation unit" msgstr "" "Выбранная программа недействительна для выбранной организационной единицы" -msgid "Online" -msgstr "Онлайн" - -msgid "Offline" -msgstr "Оффлайн" - -msgid "Syncing" -msgstr "Синхронизация" - msgid "Add note" msgstr "Добавить заметку" diff --git a/i18n/sv.po b/i18n/sv.po index 62edd96eb5..e771dc9cec 100644 --- a/i18n/sv.po +++ b/i18n/sv.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Swedish (https://app.transifex.com/hisp-uio/teams/100509/sv/)\n" @@ -591,15 +591,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Uppkopplad" - -msgid "Offline" -msgstr "Off-line" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "Lägg till anteckning" @@ -1236,12 +1227,6 @@ msgstr "" msgid "Follow-up" msgstr "" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "Avbruten" @@ -1459,6 +1444,23 @@ msgstr "" msgid "New {{ eventName }} event" msgstr "" +msgid "An error occurred while deleting the event" +msgstr "" + +msgid "" +"Deleting an event is permanent and cannot be undone. Are you sure you want " +"to delete this event?" +msgstr "" + +msgid "An error occurred when updating event status" +msgstr "" + +msgid "Unskip" +msgstr "" + +msgid "Skip" +msgstr "" + msgid "To open this event, please wait until saving is complete" msgstr "" diff --git a/i18n/tet.po b/i18n/tet.po index 719938fd39..d268e14ea8 100644 --- a/i18n/tet.po +++ b/i18n/tet.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Tetum (Tetun) (https://app.transifex.com/hisp-uio/teams/100509/tet/)\n" @@ -588,15 +588,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Online" - -msgid "Offline" -msgstr "Offline" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "" @@ -1232,12 +1223,6 @@ msgstr "" msgid "Follow-up" msgstr "Segimentu" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "" @@ -1453,6 +1438,23 @@ msgstr "" msgid "New {{ eventName }} event" msgstr "" +msgid "An error occurred while deleting the event" +msgstr "" + +msgid "" +"Deleting an event is permanent and cannot be undone. Are you sure you want " +"to delete this event?" +msgstr "" + +msgid "An error occurred when updating event status" +msgstr "" + +msgid "Unskip" +msgstr "" + +msgid "Skip" +msgstr "" + msgid "To open this event, please wait until saving is complete" msgstr "" diff --git a/i18n/tg.po b/i18n/tg.po index 1346766a62..02c2ea6da5 100644 --- a/i18n/tg.po +++ b/i18n/tg.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Tajik (https://app.transifex.com/hisp-uio/teams/100509/tg/)\n" @@ -589,15 +589,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Онлайн" - -msgid "Offline" -msgstr "Офлайн" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "" @@ -1234,12 +1225,6 @@ msgstr "" msgid "Follow-up" msgstr "Пайгирӣ кардан" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "" @@ -1457,6 +1442,23 @@ msgstr "" msgid "New {{ eventName }} event" msgstr "" +msgid "An error occurred while deleting the event" +msgstr "" + +msgid "" +"Deleting an event is permanent and cannot be undone. Are you sure you want " +"to delete this event?" +msgstr "" + +msgid "An error occurred when updating event status" +msgstr "" + +msgid "Unskip" +msgstr "" + +msgid "Skip" +msgstr "" + msgid "To open this event, please wait until saving is complete" msgstr "" diff --git a/i18n/uk.po b/i18n/uk.po index c51bff2210..b294680692 100644 --- a/i18n/uk.po +++ b/i18n/uk.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Ukrainian (https://app.transifex.com/hisp-uio/teams/100509/uk/)\n" @@ -594,15 +594,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Онлайн" - -msgid "Offline" -msgstr "Офлайн" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "Додати нотатку" @@ -1241,12 +1232,6 @@ msgstr "" msgid "Follow-up" msgstr "Подальші дії" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "Скасовано" diff --git a/i18n/ur.po b/i18n/ur.po index ce4b3021c3..9a1900631a 100644 --- a/i18n/ur.po +++ b/i18n/ur.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Urdu (https://app.transifex.com/hisp-uio/teams/100509/ur/)\n" @@ -589,15 +589,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "آن لائن" - -msgid "Offline" -msgstr "آف لائن" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "نوٹ شامل" @@ -1234,12 +1225,6 @@ msgstr "" msgid "Follow-up" msgstr "" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "منسوخ" diff --git a/i18n/uz_UZ_Cyrl.po b/i18n/uz_UZ_Cyrl.po index 32a8d2e932..6ad437c602 100644 --- a/i18n/uz_UZ_Cyrl.po +++ b/i18n/uz_UZ_Cyrl.po @@ -606,15 +606,6 @@ msgstr "Дастур мавжуд эмас" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Онлайн" - -msgid "Offline" -msgstr "Оффлайн" - -msgid "Syncing" -msgstr "Синхронлашмоқда" - msgid "Add note" msgstr "Изоҳ қолдириш" diff --git a/i18n/uz_UZ_Latn.po b/i18n/uz_UZ_Latn.po index 0379eb17c6..720b8be8e6 100644 --- a/i18n/uz_UZ_Latn.po +++ b/i18n/uz_UZ_Latn.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Yury Rogachev , 2024\n" "Language-Team: Uzbek (Latin) (https://app.transifex.com/hisp-uio/teams/100509/uz@Latn/)\n" @@ -607,15 +607,6 @@ msgstr "Dastur mavjud emas" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "Onlayn" - -msgid "Offline" -msgstr "Offlayn" - -msgid "Syncing" -msgstr "Sinxronlashmoqda" - msgid "Add note" msgstr "Izoh qoldirish" @@ -1258,12 +1249,6 @@ msgstr "" msgid "Follow-up" msgstr "Kuzatish" -msgid "Started at {{orgUnitName}}" -msgstr "" - -msgid "Owned by {{ownerOrgUnit}}" -msgstr "" - msgid "Cancelled" msgstr "Bekor qilindi" diff --git a/i18n/zh_CN.po b/i18n/zh_CN.po index d370cc02a6..68ce40fc28 100644 --- a/i18n/zh_CN.po +++ b/i18n/zh_CN.po @@ -591,15 +591,6 @@ msgstr "项目不存在" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "在线" - -msgid "Offline" -msgstr "离线" - -msgid "Syncing" -msgstr "同步" - msgid "Add note" msgstr "添加笔记" From 5e377e6b910d729e4d6296c0259f78ff13134773 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Sun, 13 Oct 2024 01:48:51 +0000 Subject: [PATCH 04/45] chore(release): cut 101.9.1 [skip release] ## [101.9.1](https://github.com/dhis2/capture-app/compare/v101.9.0...v101.9.1) (2024-10-13) ### Bug Fixes * **translations:** sync translations from transifex (master) ([2603f34](https://github.com/dhis2/capture-app/commit/2603f342d3e34e1f4ac631797c60b93e2aa3606a)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 07ffe6de6b..be5bbe281c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [101.9.1](https://github.com/dhis2/capture-app/compare/v101.9.0...v101.9.1) (2024-10-13) + + +### Bug Fixes + +* **translations:** sync translations from transifex (master) ([2603f34](https://github.com/dhis2/capture-app/commit/2603f342d3e34e1f4ac631797c60b93e2aa3606a)) + # [101.9.0](https://github.com/dhis2/capture-app/compare/v101.8.0...v101.9.0) (2024-10-09) diff --git a/package.json b/package.json index adcf77dda8..22ae5cce65 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.9.0", + "version": "101.9.1", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.9.0", + "@dhis2/rules-engine-javascript": "101.9.1", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index 736c8ceabc..968878a1d4 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.9.0", + "version": "101.9.1", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From b1a720afc58b281ec7fc50e5af39ac19f4ec0cf4 Mon Sep 17 00:00:00 2001 From: henrikmv <110386561+henrikmv@users.noreply.github.com> Date: Mon, 14 Oct 2024 10:55:13 +0200 Subject: [PATCH 05/45] feat: [DHIS2-17771] Org unit context in tables and lists (#3813) * feat: update client to list converter * feat: changes in tooltip component * feat: add orgunit context stages and events widget * feat: use cache for subvalues * feat: orgunit context event workspace * fix: renaming of return statement --- .../hooks/getSubValueForTei.js | 12 ++++------- .../TooltipOrgUnit.component.js | 13 ++++++------ .../WidgetEnrollment.component.js | 4 ++-- .../WidgetProfile/hooks/getSubValueForTei.js | 20 ++++--------------- .../Stages/Stage/StageDetail/hooks/helpers.js | 4 ++-- .../Stage/StageDetail/hooks/useEventList.js | 2 +- .../Stages/Stage/getEventDataWithSubValue.js | 17 ++++------------ .../FlatListOrgUnitField.js | 19 ------------------ .../FlatListOrgUnitField/index.js | 3 --- .../utils/getDataEntryDetails.js | 4 ++-- .../utils/getSubValueForDataValue.js | 13 ++++-------- .../capture-core/converters/clientToList.js | 9 +++++++-- .../capture-core/converters/clientToView.js | 14 +++---------- .../metadataRetrieval/orgUnitName/index.js | 1 - .../orgUnitName/orgUnitName.js | 2 -- 15 files changed, 40 insertions(+), 97 deletions(-) delete mode 100644 src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/FlatListOrgUnitField.js delete mode 100644 src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/index.js diff --git a/src/core_modules/capture-core/components/DataEntries/EnrollmentRegistrationEntry/hooks/getSubValueForTei.js b/src/core_modules/capture-core/components/DataEntries/EnrollmentRegistrationEntry/hooks/getSubValueForTei.js index b8df8130ed..eab8d88a89 100644 --- a/src/core_modules/capture-core/components/DataEntries/EnrollmentRegistrationEntry/hooks/getSubValueForTei.js +++ b/src/core_modules/capture-core/components/DataEntries/EnrollmentRegistrationEntry/hooks/getSubValueForTei.js @@ -1,6 +1,8 @@ // @flow import type { QuerySingleResource } from 'capture-core/utils/api'; import { dataElementTypes } from '../../../../metaData'; +import { getOrgUnitNames } from '../../../../metadataRetrieval/orgUnitName'; + const getImageOrFileResourceSubvalue = async (key: string, querySingleResource: QuerySingleResource) => { const { id, displayName: name } = await querySingleResource({ resource: 'fileResources', id: key }); @@ -11,14 +13,8 @@ const getImageOrFileResourceSubvalue = async (key: string, querySingleResource: }; const getOrganisationUnitSubvalue = async (key: string, querySingleResource: QuerySingleResource) => { - const organisationUnit = await querySingleResource({ - resource: 'organisationUnits', - id: key, - params: { - fields: 'id,name', - }, - }); - return { ...organisationUnit }; + const organisationUnit = await getOrgUnitNames([key], querySingleResource); + return organisationUnit[key]; }; export const subValueGetterByElementType = { diff --git a/src/core_modules/capture-core/components/Tooltips/TooltipOrgUnit/TooltipOrgUnit.component.js b/src/core_modules/capture-core/components/Tooltips/TooltipOrgUnit/TooltipOrgUnit.component.js index 8b756f7e9c..7173df8144 100644 --- a/src/core_modules/capture-core/components/Tooltips/TooltipOrgUnit/TooltipOrgUnit.component.js +++ b/src/core_modules/capture-core/components/Tooltips/TooltipOrgUnit/TooltipOrgUnit.component.js @@ -1,18 +1,19 @@ // @flow import React from 'react'; import { Tooltip } from '@dhis2/ui'; +import { useOrgUnitNameWithAncestors } from '../../../metadataRetrieval/orgUnitName'; type Props = { - orgUnitName: string, - ancestors?: Array, + orgUnitId: string, }; -export const TooltipOrgUnit = ({ orgUnitName, ancestors = [] }: Props) => { - const fullPath = [...ancestors, orgUnitName].join(' / '); +export const TooltipOrgUnit = ({ orgUnitId }: Props) => { + const { displayName, ancestors = [] } = useOrgUnitNameWithAncestors(orgUnitId); + const fullPath = [...ancestors, displayName].join(' / '); return ( - - {orgUnitName} + + {displayName} ); }; diff --git a/src/core_modules/capture-core/components/WidgetEnrollment/WidgetEnrollment.component.js b/src/core_modules/capture-core/components/WidgetEnrollment/WidgetEnrollment.component.js index 3bec583e85..00c44c0a6e 100644 --- a/src/core_modules/capture-core/components/WidgetEnrollment/WidgetEnrollment.component.js +++ b/src/core_modules/capture-core/components/WidgetEnrollment/WidgetEnrollment.component.js @@ -78,8 +78,8 @@ export const WidgetEnrollmentPlain = ({ const { displayName: orgUnitName, ancestors } = useOrgUnitNameWithAncestors(enrollment?.orgUnit); const { displayName: ownerOrgUnitName, ancestors: ownerAncestors } = useOrgUnitNameWithAncestors(ownerOrgUnit?.id); - const orgUnitClientValue = { name: orgUnitName, ancestors }; - const ownerOrgUnitClientValue = { name: ownerOrgUnitName, ancestors: ownerAncestors }; + const orgUnitClientValue = { id: enrollment?.orgUnit, name: orgUnitName, ancestors }; + const ownerOrgUnitClientValue = { id: ownerOrgUnit?.id, name: ownerOrgUnitName, ancestors: ownerAncestors }; return (
diff --git a/src/core_modules/capture-core/components/WidgetProfile/hooks/getSubValueForTei.js b/src/core_modules/capture-core/components/WidgetProfile/hooks/getSubValueForTei.js index af3c5de5ec..18891f0578 100644 --- a/src/core_modules/capture-core/components/WidgetProfile/hooks/getSubValueForTei.js +++ b/src/core_modules/capture-core/components/WidgetProfile/hooks/getSubValueForTei.js @@ -2,6 +2,7 @@ import type { QuerySingleResource } from 'capture-core/utils/api'; import { dataElementTypes } from '../../../metaData'; import { FEATURES, hasAPISupportForFeature } from '../../../../capture-core-utils'; +import { getOrgUnitNames } from '../../../metadataRetrieval/orgUnitName'; type Attribute = { id: string, @@ -59,22 +60,9 @@ const getImageResourceSubvalue = async ({ attribute, minorServerVersion }: SubVa }; }; -const getOrganisationUnitSubvalue = async ({ attribute, querySingleResource }: SubValueFunctionParams) => { - const organisationUnit = await querySingleResource({ - resource: 'organisationUnits', - id: attribute.value, - params: { - fields: 'id,name,ancestors[displayName]', - }, - }); - - const orgUnitClientValue = { - id: organisationUnit.id, - name: organisationUnit.name, - ancestors: organisationUnit.ancestors.map(ancestor => ancestor.displayName), - }; - - return orgUnitClientValue; +const getOrganisationUnitSubvalue = async ({ attribute: { value }, querySingleResource }: SubValueFunctionParams) => { + const organisationUnits = await getOrgUnitNames([value], querySingleResource); + return organisationUnits[value]; }; export const subValueGetterByElementType = { diff --git a/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/helpers.js b/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/helpers.js index d4f2d6b2a6..74ae039f19 100644 --- a/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/helpers.js +++ b/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/helpers.js @@ -8,7 +8,7 @@ import type { StageDataElement } from '../../../../types/common.types'; import { Notes } from '../Notes.component'; import type { QuerySingleResource } from '../../../../../../utils/api/api.types'; import { isEventOverdue } from '../../../../../../utils/isEventOverdue'; -import { getCachedOrgUnitName } from '../../../../../../metadataRetrieval/orgUnitName'; +import { TooltipOrgUnit } from '../../../../../Tooltips/TooltipOrgUnit/TooltipOrgUnit.component'; const getEventStatus = (event: ApiEnrollmentEvent) => { const today = moment().startOf('day'); @@ -58,7 +58,7 @@ const convertStatusForView = (event: ApiEnrollmentEvent) => { }; }; -const convertOrgUnitForView = (event: ApiEnrollmentEvent) => getCachedOrgUnitName(event.orgUnit); +const convertOrgUnitForView = (event: ApiEnrollmentEvent) => ; const convertNoteForView = (event: ApiEnrollmentEvent) => ; diff --git a/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/useEventList.js b/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/useEventList.js index 2199216154..f160eb00e3 100644 --- a/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/useEventList.js +++ b/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/StageDetail/hooks/useEventList.js @@ -22,7 +22,7 @@ import { } from '../../../../../../metaDataMemoryStoreBuilders/common/helpers/dataElement/unsupportedMultiText'; import { useOrgUnitNames } from '../../../../../../metadataRetrieval/orgUnitName'; -const baseKeys = [{ id: 'status' }, { id: 'occurredAt' }, { id: 'assignedUser' }, { id: 'orgUnitName' }, { id: 'scheduledAt' }, { id: 'notes' }]; +const baseKeys = [{ id: 'status' }, { id: 'occurredAt' }, { id: 'assignedUser' }, { id: 'orgUnit' }, { id: 'scheduledAt' }, { id: 'notes' }]; const basedFieldTypes = [ { type: dataElementTypes.STATUS, resolveValue: convertStatusForView }, { type: dataElementTypes.DATE }, diff --git a/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/getEventDataWithSubValue.js b/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/getEventDataWithSubValue.js index a5493d19fd..d0aa4cc038 100644 --- a/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/getEventDataWithSubValue.js +++ b/src/core_modules/capture-core/components/WidgetStagesAndEvents/Stages/Stage/getEventDataWithSubValue.js @@ -2,6 +2,7 @@ import { featureAvailable, FEATURES } from 'capture-core-utils'; import { dataElementTypes } from '../../../../metaData'; import type { QuerySingleResource } from '../../../../utils/api/api.types'; +import { getOrgUnitNames } from '../../../../metadataRetrieval/orgUnitName'; const getFileResourceSubvalue = async (keys: Object, querySingleResource: QuerySingleResource, eventId: string, absoluteApiPath: string) => { const promises = Object.keys(keys) @@ -57,19 +58,9 @@ const getImageSubvalue = (keys: Object, querySingleResource: QuerySingleResource ); const getOrganisationUnitSubvalue = async (keys: Object, querySingleResource: QuerySingleResource) => { - const ids = Object.values(keys) - .join(','); - - const { organisationUnits = [] } = await querySingleResource({ - resource: 'organisationUnits', - params: { filter: `id:in:[${ids}]` }, - }); - - return organisationUnits - .reduce((acc, { id, displayName: name }) => { - acc[id] = { id, name }; - return acc; - }, {}); + const ids = Object.values(keys).map(value => String(value)); + const orgUnitNames = await getOrgUnitNames(ids, querySingleResource); + return orgUnitNames; }; const subValueGetterByElementType = { diff --git a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/FlatListOrgUnitField.js b/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/FlatListOrgUnitField.js deleted file mode 100644 index aaf3ffdf3c..0000000000 --- a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/FlatListOrgUnitField.js +++ /dev/null @@ -1,19 +0,0 @@ -// @flow -import React from 'react'; -import { useOrgUnitNameWithAncestors } from '../../../metadataRetrieval/orgUnitName'; - -type Props = { - orgUnitId: string, -} - -export const FlatListOrgUnitField = ({ - orgUnitId, -}: Props) => { - const { displayName } = useOrgUnitNameWithAncestors(orgUnitId); - - return ( - - {displayName} - - ); -}; diff --git a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/index.js b/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/index.js deleted file mode 100644 index cf8e8c20b7..0000000000 --- a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/FlatListOrgUnitField/index.js +++ /dev/null @@ -1,3 +0,0 @@ -// @flow - -export { FlatListOrgUnitField } from './FlatListOrgUnitField'; diff --git a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getDataEntryDetails.js b/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getDataEntryDetails.js index 3e42d171de..a76d895a77 100644 --- a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getDataEntryDetails.js +++ b/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getDataEntryDetails.js @@ -5,7 +5,7 @@ import i18n from '@dhis2/d2-i18n'; import { dataElementTypes, type RenderFoundation } from '../../../metaData'; import { convertClientToView, convertServerToClient } from '../../../converters'; import type { LinkedEvent } from '../WidgetTwoEventWorkspace.types'; -import { FlatListOrgUnitField } from '../FlatListOrgUnitField'; +import { TooltipOrgUnit } from '../../Tooltips/TooltipOrgUnit'; const convertFn = pipe(convertServerToClient, convertClientToView); @@ -37,7 +37,7 @@ const DataEntryFieldsToInclude = { type: dataElementTypes.ORGANISATION_UNIT, placement: Placements.TOP, label: i18n.t('Organisation unit'), - convertFn: orgUnitId => , + convertFn: orgUnitId => , }, status: { apiKey: 'status', diff --git a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getSubValueForDataValue.js b/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getSubValueForDataValue.js index 5de5037e21..2a54bc5f8c 100644 --- a/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getSubValueForDataValue.js +++ b/src/core_modules/capture-core/components/WidgetTwoEventWorkspace/utils/getSubValueForDataValue.js @@ -2,6 +2,7 @@ import { dataElementTypes } from '../../../metaData'; import type { QuerySingleResource } from '../../../utils/api'; import { featureAvailable, FEATURES } from '../../../../capture-core-utils'; +import { getOrgUnitNames } from '../../../metadataRetrieval/orgUnitName'; type SubValueFunctionProps = { dataElement: Object, @@ -44,15 +45,9 @@ const getImageSubvalue = async ({ dataElement, querySingleResource, eventId, abs }; }; -const getOrganisationUnitSubvalue = async ({ dataElement, querySingleResource }: SubValueFunctionProps) => { - const organisationUnit = await querySingleResource({ - resource: 'organisationUnits', - id: dataElement.value, - params: { - fields: 'id,name', - }, - }); - return { ...organisationUnit }; +const getOrganisationUnitSubvalue = async ({ dataElement: { value }, querySingleResource }: SubValueFunctionProps) => { + const organisationUnits = await getOrgUnitNames([value], querySingleResource); + return organisationUnits[value]; }; export const subValueGetterByElementType = { diff --git a/src/core_modules/capture-core/converters/clientToList.js b/src/core_modules/capture-core/converters/clientToList.js index a5f39b4105..870d0d7981 100644 --- a/src/core_modules/capture-core/converters/clientToList.js +++ b/src/core_modules/capture-core/converters/clientToList.js @@ -8,6 +8,7 @@ import { dataElementTypes, type DataElement } from '../metaData'; import { convertMomentToDateFormatString } from '../utils/converters/date'; import { stringifyNumber } from './common/stringifyNumber'; import { MinimalCoordinates } from '../components/MinimalCoordinates'; +import { TooltipOrgUnit } from '../components/Tooltips/TooltipOrgUnit'; function convertDateForListDisplay(rawValue: string): string { const momentDate = moment(rawValue); @@ -37,6 +38,7 @@ type ImageClientValue = { previewUrl: string, }; + function convertFileForDisplay(clientValue: FileClientValue) { // Fallback until https://dhis2.atlassian.net/browse/DHIS2-16994 is implemented if (typeof clientValue === 'string' || clientValue instanceof String) { @@ -86,10 +88,13 @@ function convertStatusForDisplay(clientValue: Object) { ); } -function convertOrgUnitForDisplay(rawValue: string | Object) { - return (typeof rawValue === 'string' ? rawValue : rawValue.name); +function convertOrgUnitForDisplay(clientValue: { id: string }) { + return ( + + ); } + const valueConvertersForType = { [dataElementTypes.NUMBER]: stringifyNumber, [dataElementTypes.INTEGER]: stringifyNumber, diff --git a/src/core_modules/capture-core/converters/clientToView.js b/src/core_modules/capture-core/converters/clientToView.js index 115bcbeb69..2849a02b01 100644 --- a/src/core_modules/capture-core/converters/clientToView.js +++ b/src/core_modules/capture-core/converters/clientToView.js @@ -34,11 +34,6 @@ type ImageClientValue = { previewUrl: string, }; -type OrgUnitClientValue = { - name: string, - ancestors?: Array, - tooltip?: string, -}; function convertFileForDisplay(clientValue: FileClientValue) { return ( @@ -57,16 +52,13 @@ function convertImageForDisplay(clientValue: ImageClientValue) { return ; } -function convertOrgUnitForDisplay(clientValue: OrgUnitClientValue) { +function convertOrgUnitForDisplay(clientValue: { id: string }) { return ( - + ); } + const valueConvertersForType = { [dataElementTypes.NUMBER]: stringifyNumber, [dataElementTypes.INTEGER]: stringifyNumber, diff --git a/src/core_modules/capture-core/metadataRetrieval/orgUnitName/index.js b/src/core_modules/capture-core/metadataRetrieval/orgUnitName/index.js index 21e8b84212..204c983009 100644 --- a/src/core_modules/capture-core/metadataRetrieval/orgUnitName/index.js +++ b/src/core_modules/capture-core/metadataRetrieval/orgUnitName/index.js @@ -3,5 +3,4 @@ export { useOrgUnitNameWithAncestors, useOrgUnitNames, getOrgUnitNames, - getCachedOrgUnitName, } from './orgUnitName'; diff --git a/src/core_modules/capture-core/metadataRetrieval/orgUnitName/orgUnitName.js b/src/core_modules/capture-core/metadataRetrieval/orgUnitName/orgUnitName.js index 56d222c119..c86c4d7c14 100644 --- a/src/core_modules/capture-core/metadataRetrieval/orgUnitName/orgUnitName.js +++ b/src/core_modules/capture-core/metadataRetrieval/orgUnitName/orgUnitName.js @@ -209,5 +209,3 @@ export const useOrgUnitNameWithAncestors = (orgUnitId: ?string): { return { error }; }; - -export const getCachedOrgUnitName = (orgUnitId: string): ?string => displayNameCache[orgUnitId]?.displayName; From dbbf8347a44b338e229cbb55ebd2c0e8dedc3614 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Mon, 14 Oct 2024 08:59:21 +0000 Subject: [PATCH 06/45] chore(release): cut 101.10.0 [skip release] # [101.10.0](https://github.com/dhis2/capture-app/compare/v101.9.1...v101.10.0) (2024-10-14) ### Features * [DHIS2-17771] Org unit context in tables and lists ([#3813](https://github.com/dhis2/capture-app/issues/3813)) ([b1a720a](https://github.com/dhis2/capture-app/commit/b1a720afc58b281ec7fc50e5af39ac19f4ec0cf4)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index be5bbe281c..83f9e12192 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +# [101.10.0](https://github.com/dhis2/capture-app/compare/v101.9.1...v101.10.0) (2024-10-14) + + +### Features + +* [DHIS2-17771] Org unit context in tables and lists ([#3813](https://github.com/dhis2/capture-app/issues/3813)) ([b1a720a](https://github.com/dhis2/capture-app/commit/b1a720afc58b281ec7fc50e5af39ac19f4ec0cf4)) + ## [101.9.1](https://github.com/dhis2/capture-app/compare/v101.9.0...v101.9.1) (2024-10-13) diff --git a/package.json b/package.json index 22ae5cce65..f93636a12f 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.9.1", + "version": "101.10.0", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.9.1", + "@dhis2/rules-engine-javascript": "101.10.0", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index 968878a1d4..56a1e753fb 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.9.1", + "version": "101.10.0", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From 301585ed17379900db642a05e0157d52107f96a2 Mon Sep 17 00:00:00 2001 From: Eirik Haugstulen Date: Mon, 14 Oct 2024 13:32:53 +0200 Subject: [PATCH 07/45] fix: [DHIS2-18028] User is able to add invalid related stages event (#3795) * fix: change logic for linkable events * fix: split up all and linkable events * chore: remove redundant filter --- .../getConvertedRelatedStageEvent.js | 2 +- .../LinkToExisting.component.js | 22 +++++++++---------- .../LinkToExisting/LinkToExisting.types.js | 7 ++++-- .../RelatedStagesActions.component.js | 5 +++-- .../RelatedStagesActions.types.js | 7 ++++-- .../WidgetRelatedStages.component.js | 7 +++--- .../hooks/useCanAddNewEventToStage.js | 4 ++-- ...tageEvents.js => useRelatedStageEvents.js} | 19 +++++++++------- 8 files changed, 41 insertions(+), 32 deletions(-) rename src/core_modules/capture-core/components/WidgetRelatedStages/hooks/{useAvailableRelatedStageEvents.js => useRelatedStageEvents.js} (74%) diff --git a/src/core_modules/capture-core/components/WidgetEnrollmentEventNew/Validated/getConvertedRelatedStageEvent/getConvertedRelatedStageEvent.js b/src/core_modules/capture-core/components/WidgetEnrollmentEventNew/Validated/getConvertedRelatedStageEvent/getConvertedRelatedStageEvent.js index 061f7a5fe4..2da2338fe6 100644 --- a/src/core_modules/capture-core/components/WidgetEnrollmentEventNew/Validated/getConvertedRelatedStageEvent/getConvertedRelatedStageEvent.js +++ b/src/core_modules/capture-core/components/WidgetEnrollmentEventNew/Validated/getConvertedRelatedStageEvent/getConvertedRelatedStageEvent.js @@ -61,7 +61,7 @@ const getEventDetailsByLinkMode = ({ linkedEvent: { ...baseEventDetails, scheduledAt: convertFn(clientRequestEvent.scheduledAt, dataElementTypes.DATE), - orgUnit: convertFn(clientRequestEvent.orgUnit, dataElementTypes.ORGANISATION_UNIT), + orgUnit: clientRequestEvent.orgUnit, }, linkedEventId: baseEventDetails.event, }); diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.component.js b/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.component.js index 85bf2dae37..47f623af6e 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.component.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.component.js @@ -1,11 +1,7 @@ // @flow import React from 'react'; import i18n from '@dhis2/d2-i18n'; -import { - SingleSelectField, - SingleSelectOption, - spacers, -} from '@dhis2/ui'; +import { SingleSelectField, SingleSelectOption, spacers } from '@dhis2/ui'; import { withStyles } from '@material-ui/core'; import type { LinkToExistingProps } from './LinkToExisting.types'; @@ -58,13 +54,15 @@ export const LinkToExistingPlain = ({ error={saveAttempted && !!errorMessages.linkedEventId} validationText={saveAttempted && errorMessages.linkedEventId} > - {linkableEvents.map(event => ( - - ))} + {linkableEvents + .map(event => ( + + )) + }
); diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.types.js b/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.types.js index 386160b8e2..afa25ce233 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.types.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/LinkToExisting/LinkToExisting.types.js @@ -1,12 +1,15 @@ // @flow -import type { ErrorMessagesForRelatedStages, LinkableEvent } from '../RelatedStagesActions/RelatedStagesActions.types'; +import type { + ErrorMessagesForRelatedStages, + RelatedStagesEvents, +} from '../RelatedStagesActions/RelatedStagesActions.types'; import type { RelatedStageDataValueStates } from '../WidgetRelatedStages.types'; export type LinkToExistingProps = {| relatedStagesDataValues: RelatedStageDataValueStates, setRelatedStagesDataValues: (RelatedStageDataValueStates) => void, - linkableEvents: Array, + linkableEvents: Array, errorMessages: ErrorMessagesForRelatedStages, saveAttempted: boolean, linkableStageLabel: string, diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.component.js b/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.component.js index 5bd127a887..4266eaf52a 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.component.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.component.js @@ -1,7 +1,7 @@ // @flow import React, { type ComponentType, useMemo } from 'react'; import i18n from '@dhis2/d2-i18n'; -import { Radio, colors, spacers, spacersNum, IconInfo16, Button } from '@dhis2/ui'; +import { Button, colors, IconInfo16, Radio, spacers, spacersNum } from '@dhis2/ui'; import { withStyles } from '@material-ui/core'; import { ConditionalTooltip } from 'capture-core/components/Tooltips/ConditionalTooltip'; import { actions as RelatedStagesActionTypes, mainOptionTranslatedTexts, relatedStageStatus } from '../constants'; @@ -53,6 +53,7 @@ export const RelatedStagesActionsPlain = ({ type, relationshipName, scheduledLabel, + events, linkableEvents, relatedStagesDataValues, setRelatedStagesDataValues, @@ -71,7 +72,7 @@ export const RelatedStagesActionsPlain = ({ linkMode: action, })); }; - const canAddNewEventToStage = useCanAddNewEventToStage(programStage, linkableEvents); + const canAddNewEventToStage = useCanAddNewEventToStage(programStage, events); if (!programStage) { return null; diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.types.js b/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.types.js index ea381b6374..a99f2d0758 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.types.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/RelatedStagesActions/RelatedStagesActions.types.js @@ -17,16 +17,19 @@ export type ErrorMessagesForRelatedStages = {| linkedEventId?: ?string, |} -export type LinkableEvent = { +export type RelatedStagesEvents = { id: string, label: string, + isLinkable: boolean, + status: string, } export type Props = {| type: string, relationshipName: string, relatedStagesDataValues: RelatedStageDataValueStates, - linkableEvents: Array, + events: Array, + linkableEvents: Array, scheduledLabel: string, saveAttempted: boolean, errorMessages: ErrorMessagesForRelatedStages, diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js b/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js index 3050b4d3e9..7ac5068e44 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js @@ -2,12 +2,12 @@ import React, { forwardRef, useCallback, useEffect, useImperativeHandle, useState } from 'react'; import { useRelatedStages } from './useRelatedStages'; import type { Props, RelatedStageDataValueStates } from './WidgetRelatedStages.types'; +import type { ErrorMessagesForRelatedStages } from './RelatedStagesActions'; import { RelatedStagesActions } from './RelatedStagesActions'; import { relatedStageStatus } from './constants'; import { useStageLabels } from './hooks/useStageLabels'; -import type { ErrorMessagesForRelatedStages } from './RelatedStagesActions'; import { relatedStageWidgetIsValid } from './relatedStageEventIsValid/relatedStageEventIsValid'; -import { useAvailableRelatedStageEvents } from './hooks/useAvailableRelatedStageEvents'; +import { useRelatedStageEvents } from './hooks/useRelatedStageEvents'; const WidgetRelatedStagesPlain = ({ programId, @@ -21,7 +21,7 @@ const WidgetRelatedStagesPlain = ({ programId, }); const { scheduledLabel, occurredLabel } = useStageLabels(programId, constraint?.programStage?.id); - const { linkableEvents, isLoading: isLoadingEvents } = useAvailableRelatedStageEvents({ + const { events, linkableEvents, isLoading: isLoadingEvents } = useRelatedStageEvents({ stageId: constraint?.programStage?.id, relationshipTypeId: selectedRelationshipType?.id, scheduledLabel, @@ -90,6 +90,7 @@ const WidgetRelatedStagesPlain = ({ relationshipName={selectedRelationshipType.displayName} scheduledLabel={scheduledLabel} type={currentRelatedStagesStatus} + events={events} linkableEvents={linkableEvents} relatedStagesDataValues={relatedStageDataValues} setRelatedStagesDataValues={setRelatedStageDataValues} diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useCanAddNewEventToStage.js b/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useCanAddNewEventToStage.js index e78e53a554..a95321b927 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useCanAddNewEventToStage.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useCanAddNewEventToStage.js @@ -2,9 +2,9 @@ import { useMemo } from 'react'; import { useSelector } from 'react-redux'; import { ProgramStage } from '../../../metaData'; -import type { LinkableEvent } from '../RelatedStagesActions/RelatedStagesActions.types'; +import type { RelatedStagesEvents } from '../RelatedStagesActions/RelatedStagesActions.types'; -export const useCanAddNewEventToStage = (programStage: ?ProgramStage, existingRelatedEvents: LinkableEvent[]) => { +export const useCanAddNewEventToStage = (programStage: ?ProgramStage, existingRelatedEvents: RelatedStagesEvents[]) => { const hiddenProgramStages = useSelector(({ rulesEffectsHiddenProgramStageDesc }) => rulesEffectsHiddenProgramStageDesc?.['enrollmentEvent-newEvent'], ); diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useAvailableRelatedStageEvents.js b/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useRelatedStageEvents.js similarity index 74% rename from src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useAvailableRelatedStageEvents.js rename to src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useRelatedStageEvents.js index b273b3f66f..8a5e8a7c17 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useAvailableRelatedStageEvents.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/hooks/useRelatedStageEvents.js @@ -1,7 +1,7 @@ // @flow import { useMemo } from 'react'; import { convertDateObjectToDateFormatString } from '../../../utils/converters/date'; -import type { LinkableEvent } from '../RelatedStagesActions/RelatedStagesActions.types'; +import type { RelatedStagesEvents } from '../RelatedStagesActions/RelatedStagesActions.types'; import { useApiDataQuery } from '../../../utils/reactQueryHelpers'; import { handleAPIResponse, REQUESTED_ENTITIES } from '../../../utils/api'; @@ -15,12 +15,13 @@ type Props = { } type ReturnType = { - linkableEvents: Array, + events: Array, + linkableEvents: Array, isLoading: boolean, isError: boolean, } -export const useAvailableRelatedStageEvents = ({ +export const useRelatedStageEvents = ({ stageId, enrollmentId, relationshipTypeId, @@ -36,7 +37,7 @@ export const useAvailableRelatedStageEvents = ({ fields: 'event,occurredAt,scheduledAt,status,relationships', }, }), [stageId, enrollmentId]); - const { data, isLoading, isError } = useApiDataQuery>( + const { data, isLoading, isError } = useApiDataQuery>( ['availableRelatedStageEvents', stageId, enrollmentId, relationshipTypeId], query, { @@ -45,19 +46,20 @@ export const useAvailableRelatedStageEvents = ({ staleTime: 0, select: (response: any) => { const events = handleAPIResponse(REQUESTED_ENTITIES.events, response); - if (events.length === 0) return []; return events - .filter(event => !event.relationships || - !event.relationships.some(relationship => relationship.relationshipType === relationshipTypeId)) .map((event) => { + const isLinkable = !event.relationships + ?.some(relationship => relationship.relationshipType === relationshipTypeId); const label = event.occurredAt ? `${occurredLabel}: ${convertDateObjectToDateFormatString(new Date(event.occurredAt))}` : `${scheduledLabel}: ${convertDateObjectToDateFormatString(new Date(event.scheduledAt))}`; return ({ id: event.event, + status: event.status, + isLinkable, label, }); }); @@ -66,7 +68,8 @@ export const useAvailableRelatedStageEvents = ({ ); return { - linkableEvents: data ?? [], + events: data ?? [], + linkableEvents: data?.filter(event => event.isLinkable) ?? [], isLoading, isError, }; From 394efe983be1c71bf997ea5e6f73978cae2c8ed0 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Mon, 14 Oct 2024 11:42:37 +0000 Subject: [PATCH 08/45] chore(release): cut 101.10.1 [skip release] ## [101.10.1](https://github.com/dhis2/capture-app/compare/v101.10.0...v101.10.1) (2024-10-14) ### Bug Fixes * [DHIS2-18028] User is able to add invalid related stages event ([#3795](https://github.com/dhis2/capture-app/issues/3795)) ([301585e](https://github.com/dhis2/capture-app/commit/301585ed17379900db642a05e0157d52107f96a2)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 83f9e12192..1897fba86d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [101.10.1](https://github.com/dhis2/capture-app/compare/v101.10.0...v101.10.1) (2024-10-14) + + +### Bug Fixes + +* [DHIS2-18028] User is able to add invalid related stages event ([#3795](https://github.com/dhis2/capture-app/issues/3795)) ([301585e](https://github.com/dhis2/capture-app/commit/301585ed17379900db642a05e0157d52107f96a2)) + # [101.10.0](https://github.com/dhis2/capture-app/compare/v101.9.1...v101.10.0) (2024-10-14) diff --git a/package.json b/package.json index f93636a12f..437c545d18 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.10.0", + "version": "101.10.1", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.10.0", + "@dhis2/rules-engine-javascript": "101.10.1", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index 56a1e753fb..a922df4111 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.10.0", + "version": "101.10.1", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From ff859dc40a6ee43041dd0870e6730b89fc51b1e7 Mon Sep 17 00:00:00 2001 From: Eirik Haugstulen Date: Mon, 14 Oct 2024 15:21:34 +0200 Subject: [PATCH 09/45] test: cleanup after running NewPage tests (#3843) fix: cleanup after tests are run --- cypress/e2e/NewPage/NewPage.feature | 3 +++ cypress/e2e/NewPage/NewPage.js | 15 +++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/cypress/e2e/NewPage/NewPage.feature b/cypress/e2e/NewPage/NewPage.feature index 49e3d27f99..b6a7907dee 100644 --- a/cypress/e2e/NewPage/NewPage.feature +++ b/cypress/e2e/NewPage/NewPage.feature @@ -196,6 +196,9 @@ Feature: User creates a new entries from the registration page And you fill the Malaria case diagnosis registration form with values And you click the save malaria entity submit button Then you see the enrollment event Edit page + # Cleanup + And you delete the recently added malaria entity + ## New enrollment of existing TEI diff --git a/cypress/e2e/NewPage/NewPage.js b/cypress/e2e/NewPage/NewPage.js index de6efe53e2..9ef6ab3440 100644 --- a/cypress/e2e/NewPage/NewPage.js +++ b/cypress/e2e/NewPage/NewPage.js @@ -1,4 +1,4 @@ -import { Given, When, Then, defineStep as And } from '@badeball/cypress-cucumber-preprocessor'; +import { defineStep as And, Given, Then, When } from '@badeball/cypress-cucumber-preprocessor'; import moment from 'moment'; import { getCurrentYear } from '../../support/date'; @@ -17,7 +17,7 @@ And('there should be informative message explaining you need to select an organi }); And('you select tracked entity type person', () => { - cy.get('[data-test="dhis2-uicore-select"') + cy.get('[data-test="dhis2-uicore-select"]') .click(); cy.get('[data-test="dhis2-uicore-singleselectoption"]') .contains('Person') @@ -645,6 +645,17 @@ And('you delete the recently added tracked entity', () => { cy.url().should('include', 'selectedTemplateId=IpHINAT79UW'); }); +And('you delete the recently added malaria entity', () => { + cy.get('[data-test="widget-profile-overflow-menu"]') + .click(); + cy.contains('Delete Malaria Entity') + .click(); + cy.get('[data-test="widget-profile-delete-modal"]').within(() => { + cy.contains('Yes, delete Malaria Entity') + .click(); + }); +}); + And(/^you select (.*) from the available tracked entity types/, (selection) => { cy.get('[data-test="dhis2-uicore-select-input"]') .click(); From ab3c5326b66c680c43a12183e02a2a5b1462f646 Mon Sep 17 00:00:00 2001 From: Simona Domnisoru Date: Mon, 14 Oct 2024 15:50:08 +0200 Subject: [PATCH 10/45] chore: [DHIS2-17915] remove opt-in functionality (#3796) --- .../EnrollmentAddEventPageForm.feature | 1 - .../BreakingTheGlass/BreakingTheGlass.feature | 1 - cypress/e2e/MainPage/MainPage.feature | 9 --- cypress/e2e/NewPage/NewPage.feature | 6 -- cypress/e2e/SearchPage/SearchPage.feature | 4 -- .../step_definitions/common/baseSteps.js | 30 -------- docs/user/using-the-capture-app.md | 14 ---- i18n/en.pot | 48 ------------- .../navigateToEnrollmentOverview.constants.js | 6 -- .../navigateToEnrollmentOverview.epics.js | 54 +++----------- .../components/DataStore/DataStore.actions.js | 6 -- .../components/DataStore/DataStore.epics.js | 61 ---------------- .../components/DataStore/DataStore.types.js | 9 --- .../components/DataStore/index.js | 1 - .../OptInOut/OptIn/OptIn.component.js | 71 ------------------- .../OptInOut/OptIn/OptIn.container.js | 57 --------------- .../components/OptInOut/OptIn/index.js | 2 - .../components/OptInOut/OptIn/optIn.types.js | 12 ---- .../OptInOut/OptOut/OptOut.component.js | 44 ------------ .../OptInOut/OptOut/OptOut.container.js | 36 ---------- .../components/OptInOut/OptOut/index.js | 2 - .../OptInOut/OptOut/optOut.types.js | 12 ---- .../capture-core/components/OptInOut/index.js | 3 - .../WorkingListsType.component.js | 3 - .../RegistrationDataEntry.epics.js | 6 +- .../getStageWithOpenAfterEnrollment.js | 3 +- .../ConnectedEntity/TrackedEntityInstance.js | 39 +++------- .../useNewDashboard.reducerDescription.js | 17 ----- .../capture-core/utils/routing/index.js | 1 - .../utils/routing/newDashboard.js | 16 ----- src/epics/trackerCapture.epics.js | 7 -- .../trackerCapture.reducerDescriptions.js | 2 - 32 files changed, 19 insertions(+), 564 deletions(-) delete mode 100644 src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.constants.js delete mode 100644 src/core_modules/capture-core/components/DataStore/DataStore.actions.js delete mode 100644 src/core_modules/capture-core/components/DataStore/DataStore.epics.js delete mode 100644 src/core_modules/capture-core/components/DataStore/DataStore.types.js delete mode 100644 src/core_modules/capture-core/components/DataStore/index.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.component.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.container.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptIn/index.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptIn/optIn.types.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.component.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.container.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptOut/index.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/OptOut/optOut.types.js delete mode 100644 src/core_modules/capture-core/components/OptInOut/index.js delete mode 100644 src/core_modules/capture-core/reducers/descriptions/useNewDashboard.reducerDescription.js delete mode 100644 src/core_modules/capture-core/utils/routing/newDashboard.js diff --git a/cypress/e2e/EnrollmentAddEventPage/EnrollmentAddEventPageForm/EnrollmentAddEventPageForm.feature b/cypress/e2e/EnrollmentAddEventPage/EnrollmentAddEventPageForm/EnrollmentAddEventPageForm.feature index 47bacdbe8a..869b837615 100644 --- a/cypress/e2e/EnrollmentAddEventPage/EnrollmentAddEventPageForm/EnrollmentAddEventPageForm.feature +++ b/cypress/e2e/EnrollmentAddEventPage/EnrollmentAddEventPageForm/EnrollmentAddEventPageForm.feature @@ -50,7 +50,6 @@ Feature: User interacts with the Enrollment New Event Workspace Scenario: User should be asked to create new event after completing a stage and choose to cancel Given you land on the enrollment new event page by having typed #/enrollmentEventNew?enrollmentId=zRfAPUpjoG3&orgUnitId=DiszpKrYNg8&programId=M3xtLkYBlKI&stageId=CWaAcQYKVpq&teiId=S3JjTA4QMNe - And the data store is clean Then you see the following Enrollment: New Event And you see the widget header Foci investigation & classification And you type 2022-01-01 in the input number 0 diff --git a/cypress/e2e/EnrollmentPage/BreakingTheGlass/BreakingTheGlass.feature b/cypress/e2e/EnrollmentPage/BreakingTheGlass/BreakingTheGlass.feature index 8f20612a24..40ed7aac7c 100644 --- a/cypress/e2e/EnrollmentPage/BreakingTheGlass/BreakingTheGlass.feature +++ b/cypress/e2e/EnrollmentPage/BreakingTheGlass/BreakingTheGlass.feature @@ -4,7 +4,6 @@ Feature: Breaking the glass page @skip Scenario: User with search scope access tries to access an enrollment in a protected program Given the tei created by this test is cleared from the database - And the data store is clean And you create a new tei in Child programme from Ngelehun CHC And you change program to WHO RMNCH Tracker And you enroll the tei from Njandama MCHP diff --git a/cypress/e2e/MainPage/MainPage.feature b/cypress/e2e/MainPage/MainPage.feature index cb10b479fb..8f29db3697 100644 --- a/cypress/e2e/MainPage/MainPage.feature +++ b/cypress/e2e/MainPage/MainPage.feature @@ -35,15 +35,6 @@ Feature: User interacts with Main page Then the current url is /#/?orgUnitId=DiszpKrYNg8&programId=uy2gU8kT1jF&selectedTemplateId=uy2gU8kT1jF-default And the TEI working list is displayed - Scenario: The admin user can optout from using the new Enrollment Dashboard - Given you open the main page with Ngelehun and child programme context - And the data store is clean - And you see the opt out component for Child Programme - When you opt out to use the new enrollment Dashboard for Child Programme - Then you see the opt in component for Child Programme - When you opt in to use the new enrollment Dashboard for Child Programme - Then you see the opt out component for Child Programme - @v<41 Scenario: The icon is rendered as an svg Given you are in the main page with no selections made diff --git a/cypress/e2e/NewPage/NewPage.feature b/cypress/e2e/NewPage/NewPage.feature index b6a7907dee..29b5ffc199 100644 --- a/cypress/e2e/NewPage/NewPage.feature +++ b/cypress/e2e/NewPage/NewPage.feature @@ -7,7 +7,6 @@ Feature: User creates a new entries from the registration page @v>=41 Scenario: New person in Tracker Program > Filling the Allergies with multiple options Given you are in the WHO RMNCH program registration page - And the data store is clean When you fill in multiple Allergies options Then you can see the multiple selections in the form And you fill the WHO RMNCH program registration form with its required unique values @@ -103,14 +102,12 @@ Feature: User creates a new entries from the registration page Scenario: New person > Submitting the form with unique name navigates you to the user dashboard Given you are in the Person registration page - And the data store is clean When you fill in a unique first name And you click the save person submit button Then you are navigated to the enrollment dashboard page without enrollment Scenario: New person > Submitting the form from the duplicates modal navigates you to the user dashboard Given you are in the Person registration page - And the data store is clean When you fill in the first name with value that has duplicates And you click the save person submit button And you see the possible duplicates modal @@ -152,7 +149,6 @@ Feature: User creates a new entries from the registration page Scenario: New person in Tracker Program > Submitting the form with unique values navigates you to the user dashboard Given you are in the WHO RMNCH program registration page - And the data store is clean When you fill the WHO RMNCH program registration form with its required unique values And you click the save person submit button Then you see the enrollment event Edit page @@ -166,7 +162,6 @@ Feature: User creates a new entries from the registration page Scenario: New person in Tracker Program > Submitting the form from the duplicates modal navigates you to the user dashboard Given you are in the WHO RMNCH program registration page - And the data store is clean When you fill the WHO RMNCH program registration form with its required values And you click the save person submit button And you see the possible duplicates modal @@ -192,7 +187,6 @@ Feature: User creates a new entries from the registration page Scenario: Go to enrollment event when Open data entry form after enrollment is checked Given you are in the Malaria case diagnosis, treatment and investigation program registration page - And the data store is clean And you fill the Malaria case diagnosis registration form with values And you click the save malaria entity submit button Then you see the enrollment event Edit page diff --git a/cypress/e2e/SearchPage/SearchPage.feature b/cypress/e2e/SearchPage/SearchPage.feature index b1a2a58741..afc2f9e035 100644 --- a/cypress/e2e/SearchPage/SearchPage.feature +++ b/cypress/e2e/SearchPage/SearchPage.feature @@ -24,7 +24,6 @@ Feature: User interacts with Search page Scenario: Searching using unique identifier returns results Given you are on the default search page - And the data store is clean When you select the search domain WHO RMNCH Tracker And you fill in the unique identifier field with values that will return a tracked entity instance And you click find @@ -97,7 +96,6 @@ Feature: User interacts with Search page Scenario: Searching using attributes in Tracker Program navigates user to the dashboard view Given you are on the default search page - And the data store is clean When you select the search domain WHO RMNCH Tracker And you expand the attributes search area And you fill in the last name with values that will return results @@ -108,7 +106,6 @@ Feature: User interacts with Search page Scenario: Searching using attributes in TEType navigates user to dashboard view Given you are on the default search page - And the data store is clean When you select the search domain Person And you expand the attributes search area And you fill in the the form with first name value: Cla @@ -165,7 +162,6 @@ Feature: User interacts with Search page Scenario: Pressing enter should trigger search unique identifier returns results Given you are on the default search page - And the data store is clean When you select the search domain WHO RMNCH Tracker And you press enter after filling in the unique identifier field with values that will return a tracked entity instance Then you are navigated to the enrollment dashboard page diff --git a/cypress/support/step_definitions/common/baseSteps.js b/cypress/support/step_definitions/common/baseSteps.js index 42c19ad164..a4db6e4a30 100644 --- a/cypress/support/step_definitions/common/baseSteps.js +++ b/cypress/support/step_definitions/common/baseSteps.js @@ -181,33 +181,3 @@ When(/^the user selects the org unit (.*)$/, (orgUnit) => { cy.contains(orgUnit) .click(); }); - -When(/^you opt in to use the new enrollment Dashboard for (.*)$/, (program) => { - cy.get('[data-test="main-page-working-list"]').then(($wrapper) => { - if ($wrapper.find('[data-test="dhis2-uicore-button"]').length > 0) { - cy.contains('[data-test="dhis2-uicore-button"]', `Opt in for ${program}`).click(); - cy.contains('[data-test="opt-in-button"]', 'Yes, opt in').click(); - cy.contains('[data-test="opt-out-button"]', `Opt out for ${program}`); - } - }); -}); - -Then(/^you see the opt out component for (.*)$/, (program) => { - cy.contains('[data-test="opt-out-button"]', `Opt out for ${program}`); -}); - -When(/^you opt out to use the new enrollment Dashboard for (.*)$/, (program) => { - cy.intercept('PUT', '**/dataStore/capture/useNewDashboard').as('optOutEnrollmentDashboard'); - cy.contains('[data-test="opt-out-button"]', `Opt out for ${program}`).click(); - cy.wait('@optOutEnrollmentDashboard', { timeout: 30000 }); -}); - -Then(/^you see the opt in component for (.*)$/, (program) => { - cy.contains('[data-test="dhis2-uicore-button"]', `Opt in for ${program}`); -}); - -And('the data store is clean', () => { - cy.buildApiUrl('dataStore/capture/useNewDashboard') - .then(dataStoreUrl => - cy.request({ method: 'DELETE', url: dataStoreUrl, failOnStatusCode: false })); -}); diff --git a/docs/user/using-the-capture-app.md b/docs/user/using-the-capture-app.md index 651e9f7eb0..fab4c41175 100644 --- a/docs/user/using-the-capture-app.md +++ b/docs/user/using-the-capture-app.md @@ -821,20 +821,6 @@ For performance reasons the Capture app caches metadata in the client browser. W ## Enrollment dashboard -### Enabling the enrollment dashboard - -#### Opt in - -Enable the enrollment dashboard for a Tracker program for all the users. The dialog is visible for users with program write access. - -![](resources/images/enrollment-dash-opt-in.png) - -#### Opt out - -Disable the enrollment dashboard for a Tracker program for all the users. - -![](resources/images/enrollment-dash-opt-out.png) - ### Reaching the enrollment dashboard via url You reach the enrollment dashboard either by typing in the address bar of your browser or using the user interface of the capture app. diff --git a/i18n/en.pot b/i18n/en.pot index d299bcedcf..c098e29ad6 100644 --- a/i18n/en.pot +++ b/i18n/en.pot @@ -616,54 +616,6 @@ msgstr "Notice" msgid "Close the notice" msgstr "Close the notice" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "Use new Enrollment dashboard for {{programName}}" - -msgid "Opt in for {{programName}}" -msgstr "Opt in for {{programName}}" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is " -"certain functionality from Tracker Capture that has not yet been added, " -"including relationship and referral functionality. The work on including " -"this Tracker functionality in Capture is ongoing and will be added in " -"upcoming app releases." -msgstr "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is " -"certain functionality from Tracker Capture that has not yet been added, " -"including relationship and referral functionality. The work on including " -"this Tracker functionality in Capture is ongoing and will be added in " -"upcoming app releases." - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." - -msgid "Yes, opt in" -msgstr "Yes, opt in" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "Stop using new Enrollment dashboard for {{programName}}" - -msgid "Opt out for {{programName}}" -msgstr "Opt out for {{programName}}" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "Enrollment with id \"{{enrollmentId}}\" does not exist" diff --git a/src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.constants.js b/src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.constants.js deleted file mode 100644 index 435c2824ac..0000000000 --- a/src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.constants.js +++ /dev/null @@ -1,6 +0,0 @@ -// @flow - -export const scopeHierarchyTypes = { - PROGRAM: 'PROGRAM', - TRACKED_ENTITY_TYPE: 'TRACKED_ENTITY_TYPE', -}; diff --git a/src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.epics.js b/src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.epics.js index 32f7d066e2..8b413b70a4 100644 --- a/src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.epics.js +++ b/src/core_modules/capture-core/actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.epics.js @@ -4,58 +4,22 @@ import { ofType } from 'redux-observable'; import { switchMap } from 'rxjs/operators'; import { EMPTY } from 'rxjs'; import { actionTypes as NavigateToEnrollmentOverviewActionTypes } from './navigateToEnrollmentOverview.actions'; -import { buildUrlQueryString, getLocationQuery, shouldUseNewDashboard } from '../../utils/routing'; -import { scopeHierarchyTypes } from './navigateToEnrollmentOverview.constants'; +import { buildUrlQueryString } from '../../utils/routing'; -// TODO This will be removed when the link between capture and tracker capture is not relevant -const redirectToTracker = ({ teiId, orgUnitId, dependencies }) => { - const baseUrl = dependencies.absoluteApiPath; - const { search, pathname } = dependencies.history.location; - const { programId: queryProgramId, trackedEntityTypeId: queryTrackedEntityTypeId } = getLocationQuery(); - - const instanceBaseUrl = baseUrl.split('/api')[0]; - const scopeHierarchy = queryProgramId ? scopeHierarchyTypes.PROGRAM : scopeHierarchyTypes.TRACKED_ENTITY_TYPE; - const selectedScopeId = queryTrackedEntityTypeId || queryProgramId; - const scopeSearchParam = `${scopeHierarchy.toLowerCase()}=${selectedScopeId}`; - const base64Url = btoa(`/dhis-web-capture/#${pathname}${search}`); - setTimeout(() => { - window.location.href = `${instanceBaseUrl}/dhis-web-tracker-capture/#/dashboard?tei=${teiId}&ou=${orgUnitId}&${scopeSearchParam}&returnUrl=${base64Url}`; - }, 50); -}; - -const redirectToEnrollmentDashboard = ({ dependencies, teiId, programId, orgUnitId, enrollmentId }) => { - dependencies.history.push( - `/enrollment?${buildUrlQueryString({ - teiId, - programId, - orgUnitId, - enrollmentId, - })}`, - ); -}; - -export const navigateToEnrollmentOverviewEpic = (action$: InputObservable, store: ReduxStore, dependencies: any) => +export const navigateToEnrollmentOverviewEpic = (action$: InputObservable, store: ReduxStore, { history }: ApiUtils) => action$.pipe( ofType(NavigateToEnrollmentOverviewActionTypes.NAVIGATE_TO_ENROLLMENT_OVERVIEW), switchMap((action) => { const { teiId, programId, orgUnitId } = action.payload; const enrollmentId = programId && (action.payload?.enrollmentId || 'AUTO'); - const { dataStore, userDataStore } = store.value.useNewDashboard; - - if (dataStore || userDataStore) { - const shouldRedirectToEnrollmentDashboard = shouldUseNewDashboard({ - userDataStore, - dataStore, - programId, + history.push( + `/enrollment?${buildUrlQueryString({ teiId, - }); - if (shouldRedirectToEnrollmentDashboard) { - redirectToEnrollmentDashboard({ dependencies, teiId, programId, orgUnitId, enrollmentId }); - return EMPTY; - } - } - - redirectToTracker({ dependencies, store, teiId, orgUnitId }); + programId, + orgUnitId, + enrollmentId, + })}`, + ); return EMPTY; }), ); diff --git a/src/core_modules/capture-core/components/DataStore/DataStore.actions.js b/src/core_modules/capture-core/components/DataStore/DataStore.actions.js deleted file mode 100644 index a06c83561d..0000000000 --- a/src/core_modules/capture-core/components/DataStore/DataStore.actions.js +++ /dev/null @@ -1,6 +0,0 @@ -// @flow -import { actionCreator } from '../../actions/actions.utils'; -import { type UseNewDashboard, actionTypes as dataStoreActionTypes } from './DataStore.types'; - -export const saveDataStore = ({ dataStore, userDataStore }: UseNewDashboard) => - actionCreator(dataStoreActionTypes.SAVE_DATA_STORE)({ dataStore, userDataStore }); diff --git a/src/core_modules/capture-core/components/DataStore/DataStore.epics.js b/src/core_modules/capture-core/components/DataStore/DataStore.epics.js deleted file mode 100644 index 71c1cee90c..0000000000 --- a/src/core_modules/capture-core/components/DataStore/DataStore.epics.js +++ /dev/null @@ -1,61 +0,0 @@ -// @flow -import { ofType } from 'redux-observable'; -import { flatMap, catchError } from 'rxjs/operators'; -import { EMPTY } from 'rxjs'; -import { saveDataStore } from './DataStore.actions'; -import { type UseNewDashboard } from './DataStore.types'; -import { appStartActionTypes } from '../../../../components/AppStart'; -import { programCollection } from '../../metaDataMemoryStores'; - -const setNewDashboardByDefault = (key: string, dataStoreValues) => { - if (!dataStoreValues) { - return {}; - } - const programs = [...programCollection.keys()]; - const valuesWithDefault = programs.reduce((acc, program) => { - const dataStoreValue = dataStoreValues[program]; - acc[program] = dataStoreValue === undefined ? true : dataStoreValue; - return acc; - }, {}); - - return { [key]: valuesWithDefault }; -}; - -const getDataStoreFromApi = async querySingleResource => - querySingleResource({ - resource: 'dataStore/capture/useNewDashboard', - }); - -const getUserDataStoreFromApi = async querySingleResource => - querySingleResource({ - resource: 'userDataStore/capture/useNewDashboard', - }); - -export const fetchDataStoreEpic = (action$: InputObservable, _: ReduxStore, { querySingleResource }: ApiUtils) => - action$.pipe( - ofType(appStartActionTypes.APP_LOAD_SUCESS), - flatMap(async () => { - const apiDataStore: ?UseNewDashboard = await getDataStoreFromApi(querySingleResource) - .catch((error) => { - if (error.details.httpStatusCode === 404) { - return {}; - } - return undefined; - }); - - return saveDataStore(setNewDashboardByDefault('dataStore', apiDataStore)); - }), - catchError(() => EMPTY), - ); - -export const fetchUserDataStoreEpic = (action$: InputObservable, _: ReduxStore, { querySingleResource }: ApiUtils) => - action$.pipe( - ofType(appStartActionTypes.APP_LOAD_SUCESS), - flatMap(async () => { - const apiUserDataStore: UseNewDashboard = await getUserDataStoreFromApi(querySingleResource); - // $FlowFixMe - return saveDataStore(setNewDashboardByDefault('userDataStore', apiUserDataStore)); - }), - catchError(() => EMPTY), - ); - diff --git a/src/core_modules/capture-core/components/DataStore/DataStore.types.js b/src/core_modules/capture-core/components/DataStore/DataStore.types.js deleted file mode 100644 index ffa2641abb..0000000000 --- a/src/core_modules/capture-core/components/DataStore/DataStore.types.js +++ /dev/null @@ -1,9 +0,0 @@ -// @flow - -export const actionTypes = { - SAVE_DATA_STORE: 'useNewDashboard.SaveDataStore', -}; - -export type UseNewDashboard = {| - [key: string]: string, -|} diff --git a/src/core_modules/capture-core/components/DataStore/index.js b/src/core_modules/capture-core/components/DataStore/index.js deleted file mode 100644 index e6359f21f1..0000000000 --- a/src/core_modules/capture-core/components/DataStore/index.js +++ /dev/null @@ -1 +0,0 @@ -export { saveDataStore } from './DataStore.actions'; diff --git a/src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.component.js b/src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.component.js deleted file mode 100644 index 81a541bf82..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.component.js +++ /dev/null @@ -1,71 +0,0 @@ -// @flow -import React, { useState, type ComponentType } from 'react'; -import { NoticeBox, Button, Modal, ModalTitle, ModalContent, ModalActions, ButtonStrip } from '@dhis2/ui'; -import i18n from '@dhis2/d2-i18n'; -import { withStyles } from '@material-ui/core'; -import type { PlainProps } from './optIn.types'; - -const styles = { - container: { - width: '80%', - margin: '0 auto', - }, -}; - -export const OptInPlain = ({ classes, programName, handleOptIn, loading }: PlainProps) => { - const [toggle, setToggle] = useState(false); - - const title = i18n.t('Use new Enrollment dashboard for {{programName}}', { - programName, - interpolation: { escapeValue: false }, - }); - const button = i18n.t('Opt in for {{programName}}', { - programName, - interpolation: { escapeValue: false }, - }); - - const modalContent = i18n.t('By clicking opt-in below, you will start using the new enrollment dashboard in the Capture app for this Tracker program. At the moment, there is certain functionality from Tracker Capture that has not yet been added, including relationship and referral functionality. The work on including this Tracker functionality in Capture is ongoing and will be added in upcoming app releases.'); - - const modalContentFeedback = i18n.t('The core team appreciates any feedback on this new functionality which is currently being beta tested, please report any issues and feedback in the DHIS2 JIRA project.'); - - return ( -
- -

- {i18n.t('Click the button below to opt-in to the new enrollment dashboard functionality in the Capture app (beta) for this Tracker program for all users.')} -

- -
-
- {toggle && ( - setToggle(false)} dataTest="opt-in-modal"> - {title} - -

{modalContent}

-

{modalContentFeedback}

-
- - - - - - -
- )} -
- ); -}; - -export const OptIn: ComponentType<$Diff> = withStyles(styles)(OptInPlain); diff --git a/src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.container.js b/src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.container.js deleted file mode 100644 index 7bea988d28..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptIn/OptIn.container.js +++ /dev/null @@ -1,57 +0,0 @@ -// @flow -import React, { useCallback } from 'react'; -import { useDataMutation } from '@dhis2/app-runtime'; -import { useSelector, useDispatch } from 'react-redux'; -import { OptIn as OptInComponent } from './OptIn.component'; -import type { Props } from './optIn.types'; -import { useTrackerProgram } from '../../../hooks/useTrackerProgram'; -import { saveDataStore } from '../../DataStore'; - -const dataStoreUpdate = { - resource: 'dataStore/capture/useNewDashboard', - type: 'update', - data: ({ data }) => data, -}; - -const dataStoreCreate = { - resource: 'dataStore/capture/useNewDashboard', - type: 'create', - data: ({ data }) => data, -}; - -export const OptIn = ({ programId }: Props) => { - const dispatch = useDispatch(); - const program = useTrackerProgram(programId); - const newDashboard = useSelector(({ useNewDashboard }) => useNewDashboard); - const { dataStore } = newDashboard; - const showOptIn = program?.access?.write && !dataStore?.[programId]; - - const [updateMutation, { loading: loadingUpdate }] = useDataMutation(dataStoreUpdate, { - onComplete: () => { - dispatch(saveDataStore({ dataStore: { ...dataStore, [programId]: true } })); - }, - }); - const [createMutation, { loading: loadingCreate }] = useDataMutation(dataStoreCreate, { - onComplete: () => { - dispatch(saveDataStore({ dataStore: { ...dataStore, [programId]: true } })); - }, - }); - - const handleOptIn = useCallback(() => { - if (dataStore) { - const data = { ...dataStore, [programId]: true }; - updateMutation({ data }); - } else { - const data = { [programId]: true }; - createMutation({ data }); - } - }, [programId, updateMutation, createMutation, dataStore]); - - return showOptIn ? ( - - ) : null; -}; diff --git a/src/core_modules/capture-core/components/OptInOut/OptIn/index.js b/src/core_modules/capture-core/components/OptInOut/OptIn/index.js deleted file mode 100644 index 3d26d28715..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptIn/index.js +++ /dev/null @@ -1,2 +0,0 @@ -// @flow -export { OptIn } from './OptIn.container'; diff --git a/src/core_modules/capture-core/components/OptInOut/OptIn/optIn.types.js b/src/core_modules/capture-core/components/OptInOut/OptIn/optIn.types.js deleted file mode 100644 index e105d399ce..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptIn/optIn.types.js +++ /dev/null @@ -1,12 +0,0 @@ -// @flow - -export type Props = {| - programId: string, -|}; - -export type PlainProps = {| - handleOptIn: () => void, - programName: string, - loading: boolean, - ...CssClasses -|}; diff --git a/src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.component.js b/src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.component.js deleted file mode 100644 index 3639694228..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.component.js +++ /dev/null @@ -1,44 +0,0 @@ -// @flow -import React, { type ComponentType } from 'react'; -import { NoticeBox, Button } from '@dhis2/ui'; -import i18n from '@dhis2/d2-i18n'; -import { withStyles } from '@material-ui/core'; -import type { PlainProps } from './optOut.types'; - -const styles = { - container: { - width: '80%', - margin: '0 auto', - }, -}; - -export const OptOutPlain = ({ classes, programName, handleOptOut, loading }: PlainProps) => { - const title = i18n.t('Stop using new Enrollment dashboard for {{programName}}', { - programName, - interpolation: { escapeValue: false }, - }); - const button = i18n.t('Opt out for {{programName}}', { - programName, - interpolation: { escapeValue: false }, - }); - - return ( -
-
- -

- {i18n.t( - 'This program uses the new enrollment dashboard functionality ' + - 'in the Capture app (beta). Click this button to opt-out and direct ' + - 'all users to the Tracker capture app for this program.', - )} -

- -
-
- ); -}; - -export const OptOut: ComponentType<$Diff> = withStyles(styles)(OptOutPlain); diff --git a/src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.container.js b/src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.container.js deleted file mode 100644 index c9ba767866..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptOut/OptOut.container.js +++ /dev/null @@ -1,36 +0,0 @@ -// @flow -import React, { useCallback } from 'react'; -import { useDataMutation } from '@dhis2/app-runtime'; -import { useSelector, useDispatch } from 'react-redux'; -import { OptOut as OptOutComponent } from './OptOut.component'; -import type { Props } from './optOut.types'; -import { useTrackerProgram } from '../../../hooks/useTrackerProgram'; -import { saveDataStore } from '../../DataStore'; - -const dataStoreUpdate = { - resource: 'dataStore/capture/useNewDashboard', - type: 'update', - data: ({ data }) => data, -}; - -export const OptOut = ({ programId }: Props) => { - const dispatch = useDispatch(); - const program = useTrackerProgram(programId); - const newDashboard = useSelector(({ useNewDashboard }) => useNewDashboard); - const { dataStore } = newDashboard; - - const [updateMutation, { loading: loadingUpdate }] = useDataMutation(dataStoreUpdate, { - onComplete: () => { - dispatch(saveDataStore({ dataStore: { ...dataStore, [programId]: false } })); - }, - }); - const handleOptOut = useCallback(() => { - const data = { ...dataStore, [programId]: false }; - updateMutation({ data }); - }, [programId, updateMutation, dataStore]); - const showOptOut = program?.access?.write && dataStore?.[programId]; - - return showOptOut ? ( - - ) : null; -}; diff --git a/src/core_modules/capture-core/components/OptInOut/OptOut/index.js b/src/core_modules/capture-core/components/OptInOut/OptOut/index.js deleted file mode 100644 index b89207bf49..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptOut/index.js +++ /dev/null @@ -1,2 +0,0 @@ -// @flow -export { OptOut } from './OptOut.container'; diff --git a/src/core_modules/capture-core/components/OptInOut/OptOut/optOut.types.js b/src/core_modules/capture-core/components/OptInOut/OptOut/optOut.types.js deleted file mode 100644 index 3f4a4c244e..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/OptOut/optOut.types.js +++ /dev/null @@ -1,12 +0,0 @@ -// @flow - -export type Props = {| - programId: string, -|}; - -export type PlainProps = {| - handleOptOut: () => void, - programName: string, - loading: boolean, - ...CssClasses, -|}; diff --git a/src/core_modules/capture-core/components/OptInOut/index.js b/src/core_modules/capture-core/components/OptInOut/index.js deleted file mode 100644 index cc2949649c..0000000000 --- a/src/core_modules/capture-core/components/OptInOut/index.js +++ /dev/null @@ -1,3 +0,0 @@ -// @flow -export { OptIn } from './OptIn'; -export { OptOut } from './OptOut'; diff --git a/src/core_modules/capture-core/components/Pages/MainPage/WorkingListsType/WorkingListsType.component.js b/src/core_modules/capture-core/components/Pages/MainPage/WorkingListsType/WorkingListsType.component.js index dea90e1485..732f0d07d5 100644 --- a/src/core_modules/capture-core/components/Pages/MainPage/WorkingListsType/WorkingListsType.component.js +++ b/src/core_modules/capture-core/components/Pages/MainPage/WorkingListsType/WorkingListsType.component.js @@ -3,7 +3,6 @@ import React from 'react'; import { useProgramInfo, programTypes } from '../../../../hooks/useProgramInfo'; import { EventWorkingListsInit } from '../EventWorkingListsInit'; import { TeiWorkingLists } from '../../../WorkingLists/TeiWorkingLists'; -import { OptIn, OptOut } from '../../../OptInOut'; import type { Props } from './workingListsType.types'; export const WorkingListsType = ({ programId, orgUnitId, selectedTemplateId, onChangeTemplate }: Props) => { @@ -15,14 +14,12 @@ export const WorkingListsType = ({ programId, orgUnitId, selectedTemplateId, onC if (programType === programTypes.TRACKER_PROGRAM) { return ( <> - - ); } diff --git a/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/RegistrationDataEntry.epics.js b/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/RegistrationDataEntry.epics.js index d14df1119e..4ee21bd46c 100644 --- a/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/RegistrationDataEntry.epics.js +++ b/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/RegistrationDataEntry.epics.js @@ -12,7 +12,7 @@ import { getTrackerProgramThrowIfNotFound } from '../../../../metaData'; import { navigateToEnrollmentOverview, } from '../../../../actions/navigateToEnrollmentOverview/navigateToEnrollmentOverview.actions'; -import { buildUrlQueryString, shouldUseNewDashboard } from '../../../../utils/routing'; +import { buildUrlQueryString } from '../../../../utils/routing'; import { getStageWithOpenAfterEnrollment, PAGES, @@ -54,15 +54,11 @@ export const startSavingNewTrackedEntityInstanceWithEnrollmentEpic: Epic = ( ofType(registrationFormActionTypes.NEW_TRACKED_ENTITY_INSTANCE_WITH_ENROLLMENT_SAVE_START), map((action) => { const { currentSelections: { programId } } = store.value; - const { dataStore, userDataStore } = store.value.useNewDashboard; const { enrollmentPayload, uid } = action.payload; const { stages, useFirstStageDuringRegistration } = getTrackerProgramThrowIfNotFound(programId); - - const shouldRedirect = shouldUseNewDashboard({ userDataStore, dataStore, programId }); const { stageWithOpenAfterEnrollment, redirectTo } = getStageWithOpenAfterEnrollment( stages, useFirstStageDuringRegistration, - shouldRedirect, ); const eventIndex = enrollmentPayload.enrollments[0]?.events.findIndex( diff --git a/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/helpers/getStageWithOpenAfterEnrollment.js b/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/helpers/getStageWithOpenAfterEnrollment.js index 23d9d1a610..3688d29b4c 100644 --- a/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/helpers/getStageWithOpenAfterEnrollment.js +++ b/src/core_modules/capture-core/components/Pages/New/RegistrationDataEntry/helpers/getStageWithOpenAfterEnrollment.js @@ -13,13 +13,12 @@ export const PAGES = { export const getStageWithOpenAfterEnrollment = ( stages: Map, useFirstStageDuringRegistration: boolean, - shouldRedirect: boolean, ) => { const stagesArray = [...stages.values()]; const [firstStageWithOpenAfterEnrollment] = stagesArray.filter(({ openAfterEnrollment }) => openAfterEnrollment); const redirectTo = (() => { - if (shouldRedirect && firstStageWithOpenAfterEnrollment) { + if (firstStageWithOpenAfterEnrollment) { // event will be created during first stage registration if ( useFirstStageDuringRegistration diff --git a/src/core_modules/capture-core/components/Pages/ViewEvent/RightColumn/RelationshipsSection/ConnectedEntity/TrackedEntityInstance.js b/src/core_modules/capture-core/components/Pages/ViewEvent/RightColumn/RelationshipsSection/ConnectedEntity/TrackedEntityInstance.js index e02de9b1e9..16f0197068 100644 --- a/src/core_modules/capture-core/components/Pages/ViewEvent/RightColumn/RelationshipsSection/ConnectedEntity/TrackedEntityInstance.js +++ b/src/core_modules/capture-core/components/Pages/ViewEvent/RightColumn/RelationshipsSection/ConnectedEntity/TrackedEntityInstance.js @@ -1,10 +1,6 @@ // @flow import React, { useCallback } from 'react'; -import { useConfig } from '@dhis2/app-runtime'; -import { useSelector } from 'react-redux'; -import { buildUrl } from 'capture-core-utils'; -import { systemSettingsStore } from '../../../../../../metaDataMemoryStores'; -import { buildUrlQueryString, shouldUseNewDashboard } from '../../../../../../utils/routing'; +import { buildUrlQueryString } from '../../../../../../utils/routing'; type Props = { name: string, @@ -14,39 +10,20 @@ type Props = { }; export const TrackedEntityInstance = ({ name, id, orgUnitId, linkProgramId }: Props) => { - const { baseUrl } = useConfig(); - const { dataStore, userDataStore } = useSelector(({ useNewDashboard }) => useNewDashboard); - - const getUrl = useCallback(() => { - if (shouldUseNewDashboard({ userDataStore, dataStore, programId: linkProgramId, teiId: id })) { - return `/#/enrollment?${buildUrlQueryString({ + const getUrl = useCallback( + () => + `/#/enrollment?${buildUrlQueryString({ teiId: id, programId: linkProgramId, orgUnitId, enrollmentId: 'AUTO', - })}`; - } - const trackerBaseUrl = buildUrl(baseUrl, systemSettingsStore.get().trackerAppRelativePath, '/#/dashboard?'); - const baseParams = `tei=${id}&ou=${orgUnitId}`; - const params = linkProgramId ? `${baseParams}&program=${linkProgramId}` : baseParams; - return trackerBaseUrl + params; - }, [ - baseUrl, - id, - orgUnitId, - linkProgramId, - dataStore, - userDataStore, - ]); + })}`, + [id, orgUnitId, linkProgramId], + ); return ( - + {name} ); }; - diff --git a/src/core_modules/capture-core/reducers/descriptions/useNewDashboard.reducerDescription.js b/src/core_modules/capture-core/reducers/descriptions/useNewDashboard.reducerDescription.js deleted file mode 100644 index a2bd768063..0000000000 --- a/src/core_modules/capture-core/reducers/descriptions/useNewDashboard.reducerDescription.js +++ /dev/null @@ -1,17 +0,0 @@ -// @flow -import { createReducerDescription } from '../../trackerRedux/trackerReducer'; -import { actionTypes as dataStoreActionTypes } from '../../components/DataStore/DataStore.types'; - -export const useNewDashboardDesc = createReducerDescription({ - [dataStoreActionTypes.SAVE_DATA_STORE]: (state, action) => { - const newState = { ...state }; - const { dataStore, userDataStore } = action.payload; - newState.dataStore = dataStore; - newState.userDataStore = userDataStore; - - return newState; - }, -}, 'useNewDashboard', { - dataStore: undefined, - userDataStore: undefined, -}); diff --git a/src/core_modules/capture-core/utils/routing/index.js b/src/core_modules/capture-core/utils/routing/index.js index 3b533bc3cd..3131c7c491 100644 --- a/src/core_modules/capture-core/utils/routing/index.js +++ b/src/core_modules/capture-core/utils/routing/index.js @@ -2,4 +2,3 @@ export { useLocationQuery } from './useLocationQuery'; export { getLocationQuery } from './getLocationQuery'; export { buildUrlQueryString } from './buildUrlQueryString'; -export { shouldUseNewDashboard } from './newDashboard'; diff --git a/src/core_modules/capture-core/utils/routing/newDashboard.js b/src/core_modules/capture-core/utils/routing/newDashboard.js deleted file mode 100644 index c81265f93e..0000000000 --- a/src/core_modules/capture-core/utils/routing/newDashboard.js +++ /dev/null @@ -1,16 +0,0 @@ -// @flow - -export const shouldUseNewDashboard = ({ - userDataStore, - dataStore, - programId, - teiId, -}: { - userDataStore: any, - dataStore: any, - programId: ?string, - teiId?: ?string, -}): boolean => - Boolean(!programId && teiId) || // Check for when a TEI is created/searched without being enrolled in any program. In this case the URL has the enrollmentId set to 'AUTO'. - userDataStore?.[programId] || - (userDataStore?.[programId] !== false && dataStore?.[programId]); diff --git a/src/epics/trackerCapture.epics.js b/src/epics/trackerCapture.epics.js index f0bdf3bc7e..48836ddc46 100644 --- a/src/epics/trackerCapture.epics.js +++ b/src/epics/trackerCapture.epics.js @@ -35,11 +35,6 @@ import { deleteTemplateEpic, } from 'capture-core/components/WorkingLists/EventWorkingLists'; -import { - fetchDataStoreEpic, - fetchUserDataStoreEpic, -} from 'capture-core/components/DataStore/DataStore.epics'; - import { getEventFromUrlEpic, } from 'capture-core/components/Pages/ViewEvent/epics/editEvent.epics'; @@ -245,8 +240,6 @@ export const epics = combineEpics( resetProgramAfterSettingOrgUnitIfApplicableEpic, calculateSelectionsCompletenessEpic, triggerLoadCoreEpic, - fetchDataStoreEpic, - fetchUserDataStoreEpic, loadAppEpic, initEventListEpic, initTeiViewEpic, diff --git a/src/reducers/descriptions/trackerCapture.reducerDescriptions.js b/src/reducers/descriptions/trackerCapture.reducerDescriptions.js index 6f6ad63d84..ac35a29082 100644 --- a/src/reducers/descriptions/trackerCapture.reducerDescriptions.js +++ b/src/reducers/descriptions/trackerCapture.reducerDescriptions.js @@ -40,7 +40,6 @@ import { workingListsListRecordsDesc, } from 'capture-core/reducers/descriptions/workingLists'; import { mainPageDesc } from 'capture-core/reducers/descriptions/mainPage.reducerDescription'; -import { useNewDashboardDesc } from 'capture-core/reducers/descriptions/useNewDashboard.reducerDescription'; import { newEventPageDesc } from 'capture-core/reducers/descriptions/newEvent.reducerDescription'; import { editEventPageDesc } from 'capture-core/reducers/descriptions/editEvent.reducerDescription'; import { viewEventPageDesc } from 'capture-core/reducers/descriptions/viewEvent.reducerDescription'; @@ -129,7 +128,6 @@ export const reducerDescriptions = [ searchDomainDesc, teiSearchDesc, trackedEntityInstanceDesc, - useNewDashboardDesc, viewEventPageDesc, workingListsDesc, workingListsMetaDesc, From 599b2c1e29c94fd0258844aadb7eef20e03024eb Mon Sep 17 00:00:00 2001 From: Eirik Haugstulen Date: Mon, 14 Oct 2024 15:54:46 +0200 Subject: [PATCH 11/45] fix: [DHIS2-18215] selected working list not persisted on navigate (#3838) * fix: persist working list on navigate * fix: allow navigate back despite displayFrontPageList * chore: review --- .../TeiWorkingListsUser.feature | 619 +++++++++--------- .../TeiWorkingListsUser.js | 21 +- i18n/en.pot | 7 +- .../Pages/MainPage/MainPage.container.js | 25 +- 4 files changed, 358 insertions(+), 314 deletions(-) diff --git a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature index 3bf9fbfaf8..db142862ee 100644 --- a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature +++ b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.feature @@ -8,311 +8,316 @@ Feature: User interacts with tei working lists When you change the sharing settings Then you see the new sharing settings -Scenario: User opens the default working list for a tracker program -Given you open the main page with Ngelehun and child programe context -Then the default working list should be displayed -And rows per page should be set to 15 -And for a tracker program the page navigation should show that you are on the first page - -Scenario: Show only teis with completed enrollments using the predefined working list -Given you open the main page with Ngelehun and child programe context -When you select the working list called completed enrollments -Then the enrollment status filter button should show that the completed filter is in effect -And the list should display teis with a completed enrollment -And rows per page should be set to 15 -And for a tracker program the page navigation should show that you are on the first page - -Scenario: Show only teis with completed enrollments using the filter -Given you open the main page with Ngelehun and child programe context -When you set the enrollment status filter to completed -And you apply the current filter -Then the enrollment status filter button should show that the completed filter is in effect -And the list should display teis with a completed enrollment -And rows per page should be set to 15 -And for a tracker program the page navigation should show that you are on the first page - -# DHIS2-13960: /trackedEntities filter by assignee results are not consistent -@skip -Scenario: Show only teis with active enrollments and unassinged events using the filter -Given you open the main page with Ngelehun and Malaria focus investigation context -When you set the enrollment status filter to active -And you apply the current filter -And you set the assginee filter to None -And you apply the current filter -Then the enrollment status filter button should show that the active filter is in effect -And the assignee filter button should show that None filter is in effect -And the list should display teis with an active enrollment and unassinged events -And rows per page should be set to 15 -And for a tracker program the page navigation should show that you are on the first page - -Scenario: Show only teis with first name containig John using the filter -Given you open the main page with Ngelehun and child programe context -When you set the first name filter to John -And you apply the current filter -Then the first name filter button should show that the filter is in effect -And the list should display teis with John as the first name -And rows per page should be set to 15 -And for a tracker program the page navigation should show that you are on the first page - -Scenario: Show the registering unit column -Given you open the main page with Ngelehun and child programe context -When you open the column selector -And you select the organisation unit and save from the column selector -Then the organisation unit should display in the list - -Scenario: Show next page -Given you open the main page with Ngelehun and child programe context -When you click the next page button -Then the list should display data for the second page -And the pagination for the tei working list should show the second page - -Scenario: Show next page then previous page -Given you open the main page with Ngelehun and child programe context -When you click the next page button -Then the list should display data for the second page -And the pagination for the tei working list should show the second page -When you click the previous page button -Then the default working list should be displayed -And for a tracker program the page navigation should show that you are on the first page - -Scenario: Show next page then first page -Given you open the main page with Ngelehun and child programe context -When you click the next page button -Then the list should display data for the second page -And the pagination for the tei working list should show the second page -When you click the first page button -Then the default working list should be displayed -And for a tracker program the page navigation should show that you are on the first page - -Scenario: Show 10 rows per page -Given you open the main page with Ngelehun and child programe context -When you change rows per page to 10 -Then the list should display 10 rows of data -And for a tracker program the page navigation should show that you are on the first page - -Scenario: Show teis ordered ascendingly by first name -Given you open the main page with Ngelehun and child programe context -When you click the first name column header -Then the sort arrow should indicate ascending order -And the list should display data ordered ascendingly by first name -And for a tracker program the page navigation should show that you are on the first page - -Scenario: The TEI custom working lists is loaded -Given you open the main page with Ngelehun and Malaria focus investigation context -Then you see the custom TEI working lists -And you can load the view with the name Events assigned to me - - - -Scenario: The user creates, updates and deletes a TEI custom working list -Given you open the main page with Ngelehun and Malaria case diagnosis context -And you set the enrollment status filter to completed -And you apply the current filter -And you set the enrollment date to a relative range -And you apply the current filter -When you save the list with the name My custom list -Then the new My custom list is created -And the enrollment status filter button should show that the completed filter is in effect -When you set the enrollment status filter to active -And you apply the current filter -When you update the list with the name My custom list -Then the enrollment status filter button should show that the active filter is in effect -And you delete the name My custom list -Then the My custom list is deleted - -Scenario: The user can delete a TEI working list right immediately after creating it. -Given you open the main page with Ngelehun and Malaria case diagnosis context -And you set the enrollment status filter to completed -And you apply the current filter -And you set the enrollment date to a relative range -And you apply the current filter -When you save the list with the name My custom list -Then the new My custom list is created -When you delete the name My custom list -Then the My custom list is deleted - -Scenario: The user can open and select a program stage filter -Given you open the main page with Ngelehun and Malaria focus investigation context -When you open the program stage filters from the more filters dropdown menu -When you select the Foci response program stage -And you apply the current filter -And you open the column selector -And you select a data element columns and save from the column selector -Then you see data elements specific filters and columns - -Scenario: While in a program stage working list, the user can filter by both TEA and data elements -Given you open the main page with Ngelehun, WHO RMNCH Tracker and First antenatal care visit context -When you set the enrollment status filter to active -And you apply the current filter -And you set the event status filter to completed -And you apply the current filter -And you set the first name filter to Urzula -And you apply the current filter -And you set the WHOMCH Smoking filter to No -And you apply the current filter -Then the list should display 1 row of data - -Scenario: While in a program stage working list, the user can sort by both TEA and data elements -Given you open the main page with Ngelehun, WHO RMNCH Tracker and First antenatal care visit context -And you set the first name filter to u -And you apply the current filter -When you click the last name column header -Then the sort arrow should indicate ascending order -And the list should display data ordered ascendingly by last name -When you click the WHOMCH Hemoglobin value column header -Then the sort arrow should indicate descending order -And the list should display data ordered descending by WHOMCH Hemoglobin - -Scenario: The user can remove the program stage filter -Given you open the main page with Ngelehun and WHO RMNCH Tracker context -When you open the program stage filters from the more filters dropdown menu -And you select the First antenatal care visit program stage -And you apply the current filter -Then you see program stage working list events -When you remove the program stage filter -Then you don't see program stage working list events - -Scenario: The user can filter the events by scheduledAt date -Given you open the main page with Ngelehun and WHO RMNCH Tracker context -When you open the program stage filters from the more filters dropdown menu -And you select the First antenatal care visit program stage -And you apply the current filter -Then you see scheduledAt filter -And you open the column selector -When you select a scheduledAt column and save from the column selector -And you select the events scheduled today -And you apply the current filter -Then you see the selected option in the scheduledAt filter - -Scenario: The program stage working list configureation is kept when navigating -Given you open the main page with Ngelehun and WHO RMNCH Tracker context and configure a program stage working list -When you open an enrollment event from the working list -And you go back using the browser button -Then the program stage working list is loaded - -Scenario: The program stage working list without a orgUnit selected redirects to a tracker event -Given you open the main page with all accesible records in the WHO RMNCH Tracker context and configure a program stage working list -When you open an enrollment event from the working list -Then the tracker event URL contains the orgUnitId - -Scenario: The user can open a program stage list without events -Given you open the main page with Ngelehun and WHO RMNCH Tracker context and configure a program stage working list -And you set the event visit date to Today -And you apply the current filter -Then the working list is empty - -Scenario: The user can filter the Foci response assigned events -Given you open the main page with Ngelehun and Malaria focus investigation context -When you open the program stage filters from the more filters dropdown menu -And you select the Foci response program stage -And you apply the current filter -And you set the assginee filter to Anyone -And you apply the current filter -Then the assignee filter button should show that Anyone filter is in effect -And the assignee column is displayed - -Scenario: The assigned user data is kept when switching between working list types -Given you open the main page with Ngelehun and Malaria focus investigation context -And you filter by assigned Foci investigation & classification events -And the assignee filter button should show that Anyone filter is in effect -When you remove the program stage filter -Then you don't see program stage working list events -And the assignee filter button should show that Anyone filter is in effect -When you set the assginee filter to None -And you apply the current filter -Then the assignee filter button should show that None filter is in effect -When you open the program stage filters from the more filters dropdown menu -And you select the Foci response program stage -And you apply the current filter -Then the assignee filter button should show that None filter is in effect - -@v>=40 -Scenario: The user can create and delete a program stage working list for Foci investigation & classification assigned events -Given you open the main page with Ngelehun and Malaria focus investigation context -And you filter by assigned Foci investigation & classification events -When you save the list with the name Custom Program stage list -Then the new Custom Program stage list is created -And you delete the name Custom Program stage list -Then the Custom Program stage list is deleted - -@v>=40 -Scenario: The user creates, updates and deletes a Program stage custom working list -Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context -And you set the enrollment status filter to completed -And you apply the current filter -And you set the enrollment date to a relative range -And you apply the current filter -When you save the list with the name Custom Program stage list -Then the new Custom Program stage list is created -And the enrollment status filter button should show that the completed filter is in effect -When you set the enrollment status filter to active -And you apply the current filter -When you update the list with the name Custom Program stage list -Then the enrollment status filter button should show that the active filter is in effect -And you delete the name Custom Program stage list -Then the Custom Program stage list is deleted - -@v>=40 -Scenario: The user can delete a Program stage working list right immediately after creating it. -Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context -When you save the list with the name Custom Program stage list -Then the new Custom Program stage list is created -And you delete the name Custom Program stage list -Then the Custom Program stage list is deleted - -# For the program stage WL scenarios I need to create/delete my own because there are no program stage working lists in the demo database. -@v>=40 -Scenario: The Program stage custom working can be shared -Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context -And you save the list with the name Custom Program stage list -When you change the sharing settings -Then you see the new sharing settings - -@v>=40 -Scenario: The Program stage working list configuration is kept when changing the org unit -Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context -And you save the list with the name Custom Program stage list -Then the new Custom Program stage list is created -And you set the event status filter to completed -And you apply the current filter -And you change the org unit -Then the working list configuration was kept -And you delete the name Custom Program stage list -And the Custom Program stage list is deleted - -@v>=40 -Scenario: The user can save a program stage working list, based on a TEI working list configuration -Given you open a clean main page with Ngelehun and Malaria focus investigation context -Then you see the custom TEI working lists -And you can load the view with the name Ongoing foci responses -And you open the program stage filters from the more filters dropdown menu -And you select the Foci response program stage -And you apply the current filter -Then you are redirect to the default templete -When you save the list with the name Custom Program stage list -Then the new Custom Program stage list is created -And the TEI working list initial configuration was kept -And you delete the name Custom Program stage list -Then the Custom Program stage list is deleted - -@v>=40 -Scenario: The user can download the tracked entity working list -Given you open the main page with Ngelehun and child programe context -And you open the menu and click the "Download data..." button -Then the download dialog opens -Then the CSV button exists -Then the JSON button exists - -@v<40 -Scenario: The user can download the tracked entity working list -Given you open the main page with Ngelehun and child programe context -And you open the menu and click the "Download data..." button -Then the download dialog opens -Then the JSON button exists - -Scenario: The user cannot download the tracked entity working list when no orgUnit is selected -Given you open the main page with child programe context -And the user clicks the element containing the text: Or see all records accessible to you in Child Programme -And you open the menu -Then the "Download data..." button is hidden + Scenario: User opens the default working list for a tracker program + Given you open the main page with Ngelehun and child programe context + Then the default working list should be displayed + And rows per page should be set to 15 + And for a tracker program the page navigation should show that you are on the first page + + Scenario: Show only teis with completed enrollments using the predefined working list + Given you open the main page with Ngelehun and child programe context + When you select the working list called completed enrollments + Then the enrollment status filter button should show that the completed filter is in effect + And the list should display teis with a completed enrollment + And rows per page should be set to 15 + And for a tracker program the page navigation should show that you are on the first page + + Scenario: Show only teis with completed enrollments using the filter + Given you open the main page with Ngelehun and child programe context + When you set the enrollment status filter to completed + And you apply the current filter + Then the enrollment status filter button should show that the completed filter is in effect + And the list should display teis with a completed enrollment + And rows per page should be set to 15 + And for a tracker program the page navigation should show that you are on the first page + + # DHIS2-13960: /trackedEntities filter by assignee results are not consistent + @skip + Scenario: Show only teis with active enrollments and unassinged events using the filter + Given you open the main page with Ngelehun and Malaria focus investigation context + When you set the enrollment status filter to active + And you apply the current filter + And you set the assginee filter to None + And you apply the current filter + Then the enrollment status filter button should show that the active filter is in effect + And the assignee filter button should show that None filter is in effect + And the list should display teis with an active enrollment and unassinged events + And rows per page should be set to 15 + And for a tracker program the page navigation should show that you are on the first page + + Scenario: Show only teis with first name containig John using the filter + Given you open the main page with Ngelehun and child programe context + When you set the first name filter to John + And you apply the current filter + Then the first name filter button should show that the filter is in effect + And the list should display teis with John as the first name + And rows per page should be set to 15 + And for a tracker program the page navigation should show that you are on the first page + + Scenario: Show the registering unit column + Given you open the main page with Ngelehun and child programe context + When you open the column selector + And you select the organisation unit and save from the column selector + Then the organisation unit should display in the list + + Scenario: Show next page + Given you open the main page with Ngelehun and child programe context + When you click the next page button + Then the list should display data for the second page + And the pagination for the tei working list should show the second page + + Scenario: Show next page then previous page + Given you open the main page with Ngelehun and child programe context + When you click the next page button + Then the list should display data for the second page + And the pagination for the tei working list should show the second page + When you click the previous page button + Then the default working list should be displayed + And for a tracker program the page navigation should show that you are on the first page + + Scenario: Show next page then first page + Given you open the main page with Ngelehun and child programe context + When you click the next page button + Then the list should display data for the second page + And the pagination for the tei working list should show the second page + When you click the first page button + Then the default working list should be displayed + And for a tracker program the page navigation should show that you are on the first page + + Scenario: Show 10 rows per page + Given you open the main page with Ngelehun and child programe context + When you change rows per page to 10 + Then the list should display 10 rows of data + And for a tracker program the page navigation should show that you are on the first page + + Scenario: Show teis ordered ascendingly by first name + Given you open the main page with Ngelehun and child programe context + When you click the first name column header + Then the sort arrow should indicate ascending order + And the list should display data ordered ascendingly by first name + And for a tracker program the page navigation should show that you are on the first page + + Scenario: The TEI custom working lists is loaded + Given you open the main page with Ngelehun and Malaria focus investigation context + Then you see the custom TEI working lists + And you can load the view with the name Events assigned to me + + Scenario: The user creates, updates and deletes a TEI custom working list + Given you open the main page with Ngelehun and Malaria case diagnosis context + And you set the enrollment status filter to completed + And you apply the current filter + And you set the enrollment date to a relative range + And you apply the current filter + When you save the list with the name My custom list + Then the new My custom list is created + And the enrollment status filter button should show that the completed filter is in effect + When you set the enrollment status filter to active + And you apply the current filter + When you update the list with the name My custom list + Then the enrollment status filter button should show that the active filter is in effect + And you delete the name My custom list + Then the My custom list is deleted + + Scenario: The user is navigated back to the selected working list after closing a TEI + Given you open the main page with Ngelehun and child programe context + And you select the working list called completed enrollments + When you open a tei from the working list + And you deselect the tracked entity from the context selector + Then the working list called completed enrollments should be selected + + Scenario: The user can delete a TEI working list right immediately after creating it. + Given you open the main page with Ngelehun and Malaria case diagnosis context + And you set the enrollment status filter to completed + And you apply the current filter + And you set the enrollment date to a relative range + And you apply the current filter + When you save the list with the name My custom list + Then the new My custom list is created + When you delete the name My custom list + Then the My custom list is deleted + + Scenario: The user can open and select a program stage filter + Given you open the main page with Ngelehun and Malaria focus investigation context + When you open the program stage filters from the more filters dropdown menu + When you select the Foci response program stage + And you apply the current filter + And you open the column selector + And you select a data element columns and save from the column selector + Then you see data elements specific filters and columns + + Scenario: While in a program stage working list, the user can filter by both TEA and data elements + Given you open the main page with Ngelehun, WHO RMNCH Tracker and First antenatal care visit context + When you set the enrollment status filter to active + And you apply the current filter + And you set the event status filter to completed + And you apply the current filter + And you set the first name filter to Urzula + And you apply the current filter + And you set the WHOMCH Smoking filter to No + And you apply the current filter + Then the list should display 1 row of data + + Scenario: While in a program stage working list, the user can sort by both TEA and data elements + Given you open the main page with Ngelehun, WHO RMNCH Tracker and First antenatal care visit context + And you set the first name filter to u + And you apply the current filter + When you click the last name column header + Then the sort arrow should indicate ascending order + And the list should display data ordered ascendingly by last name + When you click the WHOMCH Hemoglobin value column header + Then the sort arrow should indicate descending order + And the list should display data ordered descending by WHOMCH Hemoglobin + + Scenario: The user can remove the program stage filter + Given you open the main page with Ngelehun and WHO RMNCH Tracker context + When you open the program stage filters from the more filters dropdown menu + And you select the First antenatal care visit program stage + And you apply the current filter + Then you see program stage working list events + When you remove the program stage filter + Then you don't see program stage working list events + + Scenario: The user can filter the events by scheduledAt date + Given you open the main page with Ngelehun and WHO RMNCH Tracker context + When you open the program stage filters from the more filters dropdown menu + And you select the First antenatal care visit program stage + And you apply the current filter + Then you see scheduledAt filter + And you open the column selector + When you select a scheduledAt column and save from the column selector + And you select the events scheduled today + And you apply the current filter + Then you see the selected option in the scheduledAt filter + + Scenario: The program stage working list configureation is kept when navigating + Given you open the main page with Ngelehun and WHO RMNCH Tracker context and configure a program stage working list + When you open an enrollment event from the working list + And you go back using the browser button + Then the program stage working list is loaded + + Scenario: The program stage working list without a orgUnit selected redirects to a tracker event + Given you open the main page with all accesible records in the WHO RMNCH Tracker context and configure a program stage working list + When you open an enrollment event from the working list + Then the tracker event URL contains the orgUnitId + + Scenario: The user can open a program stage list without events + Given you open the main page with Ngelehun and WHO RMNCH Tracker context and configure a program stage working list + And you set the event visit date to Today + And you apply the current filter + Then the working list is empty + + Scenario: The user can filter the Foci response assigned events + Given you open the main page with Ngelehun and Malaria focus investigation context + When you open the program stage filters from the more filters dropdown menu + And you select the Foci response program stage + And you apply the current filter + And you set the assginee filter to Anyone + And you apply the current filter + Then the assignee filter button should show that Anyone filter is in effect + And the assignee column is displayed + + Scenario: The assigned user data is kept when switching between working list types + Given you open the main page with Ngelehun and Malaria focus investigation context + And you filter by assigned Foci investigation & classification events + And the assignee filter button should show that Anyone filter is in effect + When you remove the program stage filter + Then you don't see program stage working list events + And the assignee filter button should show that Anyone filter is in effect + When you set the assginee filter to None + And you apply the current filter + Then the assignee filter button should show that None filter is in effect + When you open the program stage filters from the more filters dropdown menu + And you select the Foci response program stage + And you apply the current filter + Then the assignee filter button should show that None filter is in effect + + @v>=40 + Scenario: The user can create and delete a program stage working list for Foci investigation & classification assigned events + Given you open the main page with Ngelehun and Malaria focus investigation context + And you filter by assigned Foci investigation & classification events + When you save the list with the name Custom Program stage list + Then the new Custom Program stage list is created + And you delete the name Custom Program stage list + Then the Custom Program stage list is deleted + + @v>=40 + Scenario: The user creates, updates and deletes a Program stage custom working list + Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context + And you set the enrollment status filter to completed + And you apply the current filter + And you set the enrollment date to a relative range + And you apply the current filter + When you save the list with the name Custom Program stage list + Then the new Custom Program stage list is created + And the enrollment status filter button should show that the completed filter is in effect + When you set the enrollment status filter to active + And you apply the current filter + When you update the list with the name Custom Program stage list + Then the enrollment status filter button should show that the active filter is in effect + And you delete the name Custom Program stage list + Then the Custom Program stage list is deleted + + @v>=40 + Scenario: The user can delete a Program stage working list right immediately after creating it. + Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context + When you save the list with the name Custom Program stage list + Then the new Custom Program stage list is created + And you delete the name Custom Program stage list + Then the Custom Program stage list is deleted + + # For the program stage WL scenarios I need to create/delete my own because there are no program stage working lists in the demo database. + @v>=40 + Scenario: The Program stage custom working can be shared + Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context + And you save the list with the name Custom Program stage list + When you change the sharing settings + Then you see the new sharing settings + + @v>=40 + Scenario: The Program stage working list configuration is kept when changing the org unit + Given you open the main page with Ngelehun and Malaria case diagnosis and Household investigation context + And you save the list with the name Custom Program stage list + Then the new Custom Program stage list is created + And you set the event status filter to completed + And you apply the current filter + And you change the org unit + Then the working list configuration was kept + And you delete the name Custom Program stage list + And the Custom Program stage list is deleted + + @v>=40 + Scenario: The user can save a program stage working list, based on a TEI working list configuration + Given you open a clean main page with Ngelehun and Malaria focus investigation context + Then you see the custom TEI working lists + And you can load the view with the name Ongoing foci responses + And you open the program stage filters from the more filters dropdown menu + And you select the Foci response program stage + And you apply the current filter + Then you are redirect to the default templete + When you save the list with the name Custom Program stage list + Then the new Custom Program stage list is created + And the TEI working list initial configuration was kept + And you delete the name Custom Program stage list + Then the Custom Program stage list is deleted + + @v>=40 + Scenario: The user can download the tracked entity working list + Given you open the main page with Ngelehun and child programe context + And you open the menu and click the "Download data..." button + Then the download dialog opens + Then the CSV button exists + Then the JSON button exists + + @v<40 + Scenario: The user can download the tracked entity working list + Given you open the main page with Ngelehun and child programe context + And you open the menu and click the "Download data..." button + Then the download dialog opens + Then the JSON button exists + + Scenario: The user cannot download the tracked entity working list when no orgUnit is selected + Given you open the main page with child programe context + And the user clicks the element containing the text: Or see all records accessible to you in Child Programme + And you open the menu + Then the "Download data..." button is hidden diff --git a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js index 260e312422..0ea736c26a 100644 --- a/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js +++ b/cypress/e2e/WorkingLists/TeiWorkingLists/TeiWorkingListsUser/TeiWorkingListsUser.js @@ -1,4 +1,4 @@ -import { Given, When, Then, defineStep as And } from '@badeball/cypress-cucumber-preprocessor'; +import { defineStep as And, Given, Then, When } from '@badeball/cypress-cucumber-preprocessor'; import { v4 as uuid } from 'uuid'; import '../sharedSteps'; @@ -654,6 +654,25 @@ When('you remove the program stage filter', () => { .click(); }); +When('you open a tei from the working list', () => { + cy.get('[data-test="tei-working-lists"]') + .contains('Filona') + .click(); +}); + +When('you deselect the tracked entity from the context selector', () => { + cy.get('[data-test="person-selector-container-clear-icon"]') + .click(); +}); + +// the working list called completed enrollments should be selected +Then('the working list called completed enrollments should be selected', () => { + cy.get('[data-test="workinglist-template-selector-chip"]') + .contains('Completed enrollments') + .parent() + .should('have.class', 'selected'); +}); + Then('you see scheduledAt filter', () => { cy.get('[data-test="tei-working-lists"]') .contains('Appointment date') diff --git a/i18n/en.pot b/i18n/en.pot index c098e29ad6..9b56b6db68 100644 --- a/i18n/en.pot +++ b/i18n/en.pot @@ -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: 2024-09-02T11:08:16.281Z\n" -"PO-Revision-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-10T14:29:59.249Z\n" +"PO-Revision-Date: 2024-10-10T14:29:59.249Z\n" msgid "Choose one or more dates..." msgstr "Choose one or more dates..." @@ -1071,6 +1071,9 @@ msgstr "Create new event" msgid "Search for a {{trackedEntityName}} in {{programName}}" msgstr "Search for a {{trackedEntityName}} in {{programName}}" +msgid "Back to list" +msgstr "Back to list" + msgid "No tracked entity types available" msgstr "No tracked entity types available" diff --git a/src/core_modules/capture-core/components/Pages/MainPage/MainPage.container.js b/src/core_modules/capture-core/components/Pages/MainPage/MainPage.container.js index 52a10ab4e4..32ac19a65b 100644 --- a/src/core_modules/capture-core/components/Pages/MainPage/MainPage.container.js +++ b/src/core_modules/capture-core/components/Pages/MainPage/MainPage.container.js @@ -1,7 +1,7 @@ // @flow -import React, { useEffect, useMemo, useCallback } from 'react'; +import React, { useCallback, useEffect, useMemo } from 'react'; // $FlowFixMe -import { connect, useSelector, shallowEqual, useDispatch } from 'react-redux'; +import { connect, shallowEqual, useDispatch, useSelector } from 'react-redux'; import { useHistory } from 'react-router-dom'; import { programCollection } from 'capture-core/metaDataMemoryStores/programCollection/programCollection'; import { MainPageComponent } from './MainPage.component'; @@ -68,9 +68,11 @@ const useMainPageStatus = ({ const useSelectorMainPage = () => useSelector( - ({ currentSelections, activePage }) => ({ + ({ currentSelections, activePage, workingListsTemplates, workingListsContext }) => ({ categories: currentSelections.categories, selectedCategories: currentSelections.categoriesMeta, + reduxSelectedTemplateId: workingListsTemplates.teiList?.selectedTemplateId, + workingListProgramId: workingListsContext.teiList?.programIdView, ready: !activePage.isLoading && !activePage.lockedSelectorLoads, error: activePage.selectionsError && activePage.selectionsError.error, }), @@ -103,6 +105,8 @@ const MainPageContainer = () => { const { categories, selectedCategories, + reduxSelectedTemplateId, + workingListProgramId, error, ready, } = useSelectorMainPage(); @@ -131,7 +135,18 @@ const MainPageContainer = () => { }, [showAllAccessible, dispatch]); useEffect(() => { - if (programId && trackedEntityTypeId && displayFrontPageList && selectedTemplateId === undefined) { + if (programId && trackedEntityTypeId && selectedTemplateId === undefined) { + if (reduxSelectedTemplateId && workingListProgramId === programId) { + handleChangeTemplateUrl({ + programId, + orgUnitId, + selectedTemplateId: reduxSelectedTemplateId, + showAllAccessible, + history, + }); + return; + } + if (!displayFrontPageList) return; handleChangeTemplateUrl({ programId, orgUnitId, @@ -148,6 +163,8 @@ const MainPageContainer = () => { trackedEntityTypeId, displayFrontPageList, history, + reduxSelectedTemplateId, + workingListProgramId, ]); return ( From cd63f877772ae5f6e943371c19791b9495085904 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Mon, 14 Oct 2024 14:12:33 +0000 Subject: [PATCH 12/45] chore(release): cut 101.10.2 [skip release] ## [101.10.2](https://github.com/dhis2/capture-app/compare/v101.10.1...v101.10.2) (2024-10-14) ### Bug Fixes * [DHIS2-18215] selected working list not persisted on navigate ([#3838](https://github.com/dhis2/capture-app/issues/3838)) ([599b2c1](https://github.com/dhis2/capture-app/commit/599b2c1e29c94fd0258844aadb7eef20e03024eb)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1897fba86d..0656efb4df 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [101.10.2](https://github.com/dhis2/capture-app/compare/v101.10.1...v101.10.2) (2024-10-14) + + +### Bug Fixes + +* [DHIS2-18215] selected working list not persisted on navigate ([#3838](https://github.com/dhis2/capture-app/issues/3838)) ([599b2c1](https://github.com/dhis2/capture-app/commit/599b2c1e29c94fd0258844aadb7eef20e03024eb)) + ## [101.10.1](https://github.com/dhis2/capture-app/compare/v101.10.0...v101.10.1) (2024-10-14) diff --git a/package.json b/package.json index 437c545d18..6221901040 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.10.1", + "version": "101.10.2", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.10.1", + "@dhis2/rules-engine-javascript": "101.10.2", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index a922df4111..594bb9704e 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.10.1", + "version": "101.10.2", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From de06f8b1b5480ba7315ca648784ef414f8473e06 Mon Sep 17 00:00:00 2001 From: henrikmv <110386561+henrikmv@users.noreply.github.com> Date: Mon, 14 Oct 2024 16:53:05 +0200 Subject: [PATCH 13/45] feat: [DHIS2-17970] Auto-select orgUnit if there is only one available (#3798) * feat: pre select * feat: review changes * fix: remove children check * fix: review change * feat: merge hooks for auto select * Revert "feat: merge hooks for auto select" This reverts commit 9b97d2e6499e9d3ba4b99068659495a355d83ddf. * fix: review changes --- .../hooks/useMetadataAutoSelect.js | 20 +++----------- .../WidgetRelatedStages.component.js | 20 ++++++++++---- .../capture-core/dataQueries/index.js | 1 + .../dataQueries/useOrgUnitsForAutoSelect.js | 26 +++++++++++++++++++ 4 files changed, 46 insertions(+), 21 deletions(-) create mode 100644 src/core_modules/capture-core/dataQueries/useOrgUnitsForAutoSelect.js diff --git a/src/core_modules/capture-core/components/MetadataAutoSelectInitializer/hooks/useMetadataAutoSelect.js b/src/core_modules/capture-core/components/MetadataAutoSelectInitializer/hooks/useMetadataAutoSelect.js index 90be846e65..e85322f939 100644 --- a/src/core_modules/capture-core/components/MetadataAutoSelectInitializer/hooks/useMetadataAutoSelect.js +++ b/src/core_modules/capture-core/components/MetadataAutoSelectInitializer/hooks/useMetadataAutoSelect.js @@ -1,9 +1,10 @@ // @flow import { useCallback, useEffect, useState } from 'react'; import { useHistory } from 'react-router-dom'; -import { useApiMetadataQuery, useIndexedDBQuery } from '../../../utils/reactQueryHelpers'; +import { useIndexedDBQuery } from '../../../utils/reactQueryHelpers'; import { getUserStorageController, userStores } from '../../../storageControllers'; import { buildUrlQueryString, useLocationQuery } from '../../../utils/routing'; +import { useOrgUnitAutoSelect } from '../../../dataQueries'; const getAllPrograms = () => { const userStorageController = getUserStorageController(); @@ -28,21 +29,8 @@ export const useMetadataAutoSelect = () => { }, ); - const { data: searchOrgUnits, isLoading: loadingOrgUnits } = useApiMetadataQuery( - ['searchOrgUnitsForAutoSelect'], - { - resource: 'organisationUnits', - params: { - fields: 'id', - withinUserSearchHierarchy: true, - pageSize: 2, - }, - }, - { - enabled: Object.keys(urlParams).length === 0 && !mounted, - select: ({ organisationUnits }) => organisationUnits, - }, - ); + const queryOptions = { enabled: Object.keys(urlParams).length === 0 && !mounted }; + const { isLoading: loadingOrgUnits, data: searchOrgUnits } = useOrgUnitAutoSelect(queryOptions); const updateUrlIfApplicable = useCallback(() => { const paramsToAdd = { diff --git a/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js b/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js index 7ac5068e44..722515d992 100644 --- a/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js +++ b/src/core_modules/capture-core/components/WidgetRelatedStages/WidgetRelatedStages.component.js @@ -1,6 +1,7 @@ // @flow import React, { forwardRef, useCallback, useEffect, useImperativeHandle, useState } from 'react'; import { useRelatedStages } from './useRelatedStages'; +import { useOrgUnitAutoSelect } from '../../dataQueries'; import type { Props, RelatedStageDataValueStates } from './WidgetRelatedStages.types'; import type { ErrorMessagesForRelatedStages } from './RelatedStagesActions'; import { RelatedStagesActions } from './RelatedStagesActions'; @@ -36,6 +37,15 @@ const WidgetRelatedStagesPlain = ({ orgUnit: undefined, linkedEventId: undefined, }); + const { isLoading: orgUnitLoading, data } = useOrgUnitAutoSelect(); + useEffect(() => { + if (!orgUnitLoading && data?.length === 1) { + setRelatedStageDataValues(prev => ({ + ...prev, + orgUnit: data[0], + })); + } + }, [data, orgUnitLoading, setRelatedStageDataValues]); const addErrorMessage = (message: ErrorMessagesForRelatedStages) => { setErrorMessages((prevMessages: Object) => ({ @@ -81,7 +91,7 @@ const WidgetRelatedStagesPlain = ({ } }, [formIsValid, relatedStageDataValues]); - if (!currentRelatedStagesStatus || !selectedRelationshipType || isLoadingEvents) { + if (!currentRelatedStagesStatus || !selectedRelationshipType || isLoadingEvents || orgUnitLoading) { return null; } @@ -104,8 +114,8 @@ const WidgetRelatedStagesPlain = ({ ); }; -export const WidgetRelatedStages = forwardRef(WidgetRelatedStagesPlain); + formIsValidOnSave: Function, + getLinkedStageValues: Function + |}>(WidgetRelatedStagesPlain); diff --git a/src/core_modules/capture-core/dataQueries/index.js b/src/core_modules/capture-core/dataQueries/index.js index 913bca576a..c77469ff0c 100644 --- a/src/core_modules/capture-core/dataQueries/index.js +++ b/src/core_modules/capture-core/dataQueries/index.js @@ -1 +1,2 @@ export { useOrganisationUnit } from './useOrganisationUnit'; +export { useOrgUnitAutoSelect } from './useOrgUnitsForAutoSelect'; diff --git a/src/core_modules/capture-core/dataQueries/useOrgUnitsForAutoSelect.js b/src/core_modules/capture-core/dataQueries/useOrgUnitsForAutoSelect.js new file mode 100644 index 0000000000..a2e57ed10a --- /dev/null +++ b/src/core_modules/capture-core/dataQueries/useOrgUnitsForAutoSelect.js @@ -0,0 +1,26 @@ +// @flow +import { useApiMetadataQuery } from '../utils/reactQueryHelpers'; + +export const useOrgUnitAutoSelect = (customQueryOptions: Object) => { + const queryKey = ['organisationUnits']; + const queryFn = { + resource: 'organisationUnits', + params: { + fields: ['id, displayName~rename(name), path'], + withinUserHierarchy: true, + pageSize: 2, + }, + }; + const defaultQueryOptions = { + select: ({ organisationUnits }) => organisationUnits, + }; + + const queryOptions = { ...defaultQueryOptions, ...customQueryOptions }; + + const { data, isLoading } = useApiMetadataQuery(queryKey, queryFn, queryOptions); + + return { + isLoading, + data, + }; +}; From 5444ac70ac5635db674e2dee1475b604ef004bdb Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Mon, 14 Oct 2024 14:57:09 +0000 Subject: [PATCH 14/45] chore(release): cut 101.11.0 [skip release] # [101.11.0](https://github.com/dhis2/capture-app/compare/v101.10.2...v101.11.0) (2024-10-14) ### Features * [DHIS2-17970] Auto-select orgUnit if there is only one available ([#3798](https://github.com/dhis2/capture-app/issues/3798)) ([de06f8b](https://github.com/dhis2/capture-app/commit/de06f8b1b5480ba7315ca648784ef414f8473e06)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0656efb4df..08e6811337 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +# [101.11.0](https://github.com/dhis2/capture-app/compare/v101.10.2...v101.11.0) (2024-10-14) + + +### Features + +* [DHIS2-17970] Auto-select orgUnit if there is only one available ([#3798](https://github.com/dhis2/capture-app/issues/3798)) ([de06f8b](https://github.com/dhis2/capture-app/commit/de06f8b1b5480ba7315ca648784ef414f8473e06)) + ## [101.10.2](https://github.com/dhis2/capture-app/compare/v101.10.1...v101.10.2) (2024-10-14) diff --git a/package.json b/package.json index 6221901040..2ca3ec5672 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.10.2", + "version": "101.11.0", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.10.2", + "@dhis2/rules-engine-javascript": "101.11.0", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index 594bb9704e..ac2c2f545a 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.10.2", + "version": "101.11.0", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From 5e6dfa6bb4b82a68305741bd4bb672a5a1af8f5f Mon Sep 17 00:00:00 2001 From: henrikmv <110386561+henrikmv@users.noreply.github.com> Date: Tue, 15 Oct 2024 09:36:31 +0200 Subject: [PATCH 15/45] fix: [DHIS2-16993] Text and long text DEs are missing arrows in changelog when deleted (#3827) * fix: make arrow size static * fix: revert changes to text --- .../common/ChangelogTable/ChangelogChangeCell.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core_modules/capture-core/components/WidgetsChangelog/common/ChangelogTable/ChangelogChangeCell.js b/src/core_modules/capture-core/components/WidgetsChangelog/common/ChangelogTable/ChangelogChangeCell.js index e5dbef266a..1ec493edff 100644 --- a/src/core_modules/capture-core/components/WidgetsChangelog/common/ChangelogTable/ChangelogChangeCell.js +++ b/src/core_modules/capture-core/components/WidgetsChangelog/common/ChangelogTable/ChangelogChangeCell.js @@ -35,7 +35,7 @@ const styles = { const Updated = ({ previousValue, currentValue, classes }) => (
{previousValue} - + {currentValue}
); @@ -50,7 +50,7 @@ const Created = ({ currentValue, classes }) => ( const Deleted = ({ previousValue, classes }) => (
{previousValue} - + {i18n.t('Deleted')}
); From b6bb0ff43dfa6c9e37718fda0f456512aabf77b9 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Tue, 15 Oct 2024 07:40:44 +0000 Subject: [PATCH 16/45] chore(release): cut 101.11.1 [skip release] ## [101.11.1](https://github.com/dhis2/capture-app/compare/v101.11.0...v101.11.1) (2024-10-15) ### Bug Fixes * [DHIS2-16993] Text and long text DEs are missing arrows in changelog when deleted ([#3827](https://github.com/dhis2/capture-app/issues/3827)) ([5e6dfa6](https://github.com/dhis2/capture-app/commit/5e6dfa6bb4b82a68305741bd4bb672a5a1af8f5f)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 08e6811337..c8583ebad6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [101.11.1](https://github.com/dhis2/capture-app/compare/v101.11.0...v101.11.1) (2024-10-15) + + +### Bug Fixes + +* [DHIS2-16993] Text and long text DEs are missing arrows in changelog when deleted ([#3827](https://github.com/dhis2/capture-app/issues/3827)) ([5e6dfa6](https://github.com/dhis2/capture-app/commit/5e6dfa6bb4b82a68305741bd4bb672a5a1af8f5f)) + # [101.11.0](https://github.com/dhis2/capture-app/compare/v101.10.2...v101.11.0) (2024-10-14) diff --git a/package.json b/package.json index 2ca3ec5672..dbc834dc74 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.11.0", + "version": "101.11.1", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.11.0", + "@dhis2/rules-engine-javascript": "101.11.1", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index ac2c2f545a..6d49dda633 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.11.0", + "version": "101.11.1", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From cbfe70b850554678c7a8bad40e0874ea227fe65c Mon Sep 17 00:00:00 2001 From: Simona Domnisoru Date: Tue, 15 Oct 2024 12:13:15 +0200 Subject: [PATCH 17/45] fix: [DHIS2-18056] use linkedEntityFormFoundation instead of the searchFormFoundation (#3835) --- .../TeiRelationshipSearchResults.component.js | 24 ++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) diff --git a/src/core_modules/capture-core/components/Pages/NewRelationship/TeiRelationship/SearchResults/TeiRelationshipSearchResults.component.js b/src/core_modules/capture-core/components/Pages/NewRelationship/TeiRelationship/SearchResults/TeiRelationshipSearchResults.component.js index 3cced06ccf..461424f302 100644 --- a/src/core_modules/capture-core/components/Pages/NewRelationship/TeiRelationship/SearchResults/TeiRelationshipSearchResults.component.js +++ b/src/core_modules/capture-core/components/Pages/NewRelationship/TeiRelationship/SearchResults/TeiRelationshipSearchResults.component.js @@ -10,7 +10,11 @@ import { makeAttributesSelector } from './teiRelationshipSearchResults.selectors import { CardList } from '../../../../CardList'; import type { CurrentSearchTerms } from '../../../../SearchBox'; import { SearchResultsHeader } from '../../../../SearchResultsHeader'; -import { type SearchGroup } from '../../../../../metaData'; +import { + type SearchGroup, + getTrackerProgramThrowIfNotFound, + getTrackedEntityTypeThrowIfNotFound, +} from '../../../../../metaData'; import { ResultsPageSizeContext } from '../../../shared-contexts'; import type { ListItem } from '../../../../CardList/CardList.types'; import { convertClientValuesToServer } from '../../../../../converters/helpers/clientToServer'; @@ -25,7 +29,8 @@ type Props = {| currentPage: number, searchGroup: SearchGroup, searchValues: any, - selectedProgramId: string, + selectedProgramId?: string, + selectedTrackedEntityTypeId: string, teis: Array, trackedEntityTypeName: string, ...CssClasses @@ -60,6 +65,15 @@ const getStyles = (theme: Theme) => ({ }, }); +const getLinkedEntityFormFoundation = (selectedProgramId, selectedTrackedEntityTypeId) => { + if (selectedProgramId) { + const program = getTrackerProgramThrowIfNotFound(selectedProgramId); + return program.enrollment.enrollmentForm; + } + const trackedEntityType = getTrackedEntityTypeThrowIfNotFound(selectedTrackedEntityTypeId); + return trackedEntityType.teiRegistration.form; +}; + const CardListButton = ({ handleOnClick, teiId }) => ( - + + + + + ); }; -export const DeleteConfirmationDialog = withStyles(getStyles)(DeleteConfirmationDialogPlain); diff --git a/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/ExistingTemplateContents.component.js b/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/ExistingTemplateContents.component.js index 0efef529f0..993b30eb2d 100644 --- a/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/ExistingTemplateContents.component.js +++ b/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/ExistingTemplateContents.component.js @@ -1,40 +1,30 @@ // @flow import * as React from 'react'; -import { withStyles } from '@material-ui/core/styles'; import i18n from '@dhis2/d2-i18n'; -import { Button, ModalTitle, ModalContent, ModalActions } from '@dhis2/ui'; - -const getStyles = () => ({ - buttonContainer: { - display: 'flex', - justifyContent: 'space-between', - }, -}); +import { Button, ButtonStrip, ModalActions, ModalContent, ModalTitle } from '@dhis2/ui'; type Props = { onSaveTemplate: () => void, onClose: () => void, - classes: Object, }; -const ExistingTemplateContentsPlain = (props: Props) => { - const { onSaveTemplate, onClose, classes } = props; +export const ExistingTemplateContents = (props: Props) => { + const { onSaveTemplate, onClose } = props; return ( {i18n.t('Save')} - - - + + + + + ); }; -export const ExistingTemplateContents = withStyles(getStyles)(ExistingTemplateContentsPlain); diff --git a/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/NewTemplateContents.component.js b/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/NewTemplateContents.component.js index c064f74893..ca1a446e8f 100644 --- a/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/NewTemplateContents.component.js +++ b/src/core_modules/capture-core/components/WorkingLists/WorkingListsBase/TemplateMaintenance/NewTemplateContents.component.js @@ -1,6 +1,6 @@ // @flow import * as React from 'react'; -import { colors, Button, ModalTitle, ModalContent, ModalActions } from '@dhis2/ui'; +import { Button, ButtonStrip, colors, ModalActions, ModalContent, ModalTitle } from '@dhis2/ui'; import { withStyles } from '@material-ui/core/styles'; import i18n from '@dhis2/d2-i18n'; import { NewTemplateTextField } from './NewTemplateTextField.component'; @@ -64,15 +64,15 @@ const NewTemplateContentsPlain = (props: Props) => { {error} - - - + + + + + ); From 28e1f15d82b0da1aa93dba6bc3d1e6d2fba3b7a6 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Fri, 1 Nov 2024 14:58:30 +0000 Subject: [PATCH 41/45] chore(release): cut 101.14.5 [skip release] MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## [101.14.5](https://github.com/dhis2/capture-app/compare/v101.14.4...v101.14.5) (2024-11-01) ### Bug Fixes * [DHIS2-18238] incorrect criteria when saving list with follow up false ([#3868](https://github.com/dhis2/capture-app/issues/3868)) ([53c21f0](https://github.com/dhis2/capture-app/commit/53c21f0a4942d09ae4bf88253b576de8ca94b9b6)) * [DHIS2-18248] pass on createdAt to rules engine when editing ([#3848](https://github.com/dhis2/capture-app/issues/3848)) ([31cb56c](https://github.com/dhis2/capture-app/commit/31cb56c4f05727eb84fcc36e39f897cccc5627b3)) --- CHANGELOG.md | 8 ++++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4ec9917046..8136f020c9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +## [101.14.5](https://github.com/dhis2/capture-app/compare/v101.14.4...v101.14.5) (2024-11-01) + + +### Bug Fixes + +* [DHIS2-18238] incorrect criteria when saving list with follow up false ([#3868](https://github.com/dhis2/capture-app/issues/3868)) ([53c21f0](https://github.com/dhis2/capture-app/commit/53c21f0a4942d09ae4bf88253b576de8ca94b9b6)) +* [DHIS2-18248] pass on createdAt to rules engine when editing ([#3848](https://github.com/dhis2/capture-app/issues/3848)) ([31cb56c](https://github.com/dhis2/capture-app/commit/31cb56c4f05727eb84fcc36e39f897cccc5627b3)) + ## [101.14.4](https://github.com/dhis2/capture-app/compare/v101.14.3...v101.14.4) (2024-10-29) diff --git a/package.json b/package.json index cb10cd10a4..c0edde4cd1 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.14.4", + "version": "101.14.5", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.14.4", + "@dhis2/rules-engine-javascript": "101.14.5", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index 33aba0adb7..459d5ca235 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.14.4", + "version": "101.14.5", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From facbee13d009d11e955a1a9b277e27ba41b63867 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Sun, 3 Nov 2024 02:44:44 +0100 Subject: [PATCH 42/45] fix(translations): sync translations from transifex (master) Automatically merged. --- i18n/ar.po | 65 +++++++++------------------------ i18n/ar_IQ.po | 61 ++++++++----------------------- i18n/ckb.po | 65 +++++++++------------------------ i18n/km.po | 65 +++++++++------------------------ i18n/my.po | 65 +++++++++------------------------ i18n/prs.po | 61 ++++++++----------------------- i18n/ps.po | 65 +++++++++------------------------ i18n/pt.po | 36 +++++++++++------- i18n/pt_BR.po | 65 +++++++++------------------------ i18n/ro.po | 25 ++++++++----- i18n/ru.po | 27 ++++++++------ i18n/si.po | 91 ++++++++++++++++------------------------------ i18n/sv.po | 61 ++++++++----------------------- i18n/tet.po | 61 ++++++++----------------------- i18n/tg.po | 65 +++++++++------------------------ i18n/uk.po | 65 +++++++++------------------------ i18n/ur.po | 61 ++++++++----------------------- i18n/uz_UZ_Cyrl.po | 61 ++++++++----------------------- i18n/uz_UZ_Latn.po | 61 ++++++++----------------------- i18n/vi.po | 65 +++++++++------------------------ i18n/zh_CN.po | 25 ++++++++----- 21 files changed, 377 insertions(+), 839 deletions(-) diff --git a/i18n/ar.po b/i18n/ar.po index 2e69358014..bd06150d1f 100644 --- a/i18n/ar.po +++ b/i18n/ar.po @@ -2,15 +2,15 @@ # Translators: # KRG HIS , 2020 # Philip Larsen Donnelly, 2023 -# Hamza Assada <7amza.it@gmail.com>, 2024 # Viktor Varland , 2024 +# Hamza Assada <7amza.it@gmail.com>, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Viktor Varland , 2024\n" +"Last-Translator: Hamza Assada <7amza.it@gmail.com>, 2024\n" "Language-Team: Arabic (https://app.transifex.com/hisp-uio/teams/100509/ar/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -623,42 +623,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -746,9 +710,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1167,6 +1128,9 @@ msgstr "" msgid "Mark incomplete" msgstr "تعيين كـ غير مكتمل" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "الغِ التسجيل" @@ -1247,6 +1211,12 @@ msgstr "" msgid "Follow-up" msgstr "متابعة" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "الملغية" @@ -1443,11 +1413,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1534,6 +1499,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "تم تحديثه" + msgid "Created" msgstr "تم الإنشاء" @@ -1552,6 +1520,9 @@ msgstr "عنصر بيانات" msgid "Change" msgstr "" +msgid "Value" +msgstr "القيمة" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/ar_IQ.po b/i18n/ar_IQ.po index 13422d6d58..f818d29a25 100644 --- a/i18n/ar_IQ.po +++ b/i18n/ar_IQ.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: KRG HIS , 2024\n" "Language-Team: Arabic (Iraq) (https://app.transifex.com/hisp-uio/teams/100509/ar_IQ/)\n" @@ -620,42 +620,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -743,9 +707,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1162,6 +1123,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1242,6 +1206,12 @@ msgstr "" msgid "Follow-up" msgstr "" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "تم الإلغاء" @@ -1438,11 +1408,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1529,6 +1494,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "تم الإنشاء" @@ -1547,6 +1515,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "القيمة" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/ckb.po b/i18n/ckb.po index 851ae43bd0..54b435b433 100644 --- a/i18n/ckb.po +++ b/i18n/ckb.po @@ -2,15 +2,15 @@ # Translators: # Antonia Bezenchek , 2021 # KRG HIS , 2021 -# Viktor Varland , 2022 # Philip Larsen Donnelly, 2024 +# Viktor Varland , 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Philip Larsen Donnelly, 2024\n" +"Last-Translator: Viktor Varland , 2024\n" "Language-Team: Central Kurdish (https://app.transifex.com/hisp-uio/teams/100509/ckb/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -625,42 +625,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -748,9 +712,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1165,6 +1126,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1245,6 +1209,12 @@ msgstr "" msgid "Follow-up" msgstr "" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "" @@ -1433,11 +1403,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1520,6 +1485,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "" @@ -1538,6 +1506,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "بةها" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/km.po b/i18n/km.po index ec9c3dac3e..f203f663af 100644 --- a/i18n/km.po +++ b/i18n/km.po @@ -1,15 +1,15 @@ # # Translators: # channara rin, 2023 -# Philip Larsen Donnelly, 2024 # Viktor Varland , 2024 +# Philip Larsen Donnelly, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Viktor Varland , 2024\n" +"Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Khmer (https://app.transifex.com/hisp-uio/teams/100509/km/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -607,42 +607,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -730,9 +694,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1144,6 +1105,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1224,6 +1188,12 @@ msgstr "" msgid "Follow-up" msgstr "តាមដាន" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "បានលុបចោល" @@ -1410,11 +1380,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1496,6 +1461,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "" @@ -1514,6 +1482,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "តម្លៃ" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/my.po b/i18n/my.po index 1416f92911..e86c5d5eca 100644 --- a/i18n/my.po +++ b/i18n/my.po @@ -1,16 +1,16 @@ # # Translators: # Wanda , 2021 -# Philip Larsen Donnelly, 2024 # Aung Kyi Min , 2024 # Viktor Varland , 2024 +# Philip Larsen Donnelly, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Viktor Varland , 2024\n" +"Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Burmese (https://app.transifex.com/hisp-uio/teams/100509/my/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -608,42 +608,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -731,9 +695,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1145,6 +1106,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1225,6 +1189,12 @@ msgstr "" msgid "Follow-up" msgstr "စောင့်ကြပ်ကြည့်ရှုခြင်း" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "" @@ -1411,11 +1381,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1497,6 +1462,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "" @@ -1515,6 +1483,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "တန်ဖိုး" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/prs.po b/i18n/prs.po index 9b6cbf8306..76198d8d85 100644 --- a/i18n/prs.po +++ b/i18n/prs.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Persian (Afghanistan) (https://app.transifex.com/hisp-uio/teams/100509/fa_AF/)\n" @@ -606,42 +606,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -729,9 +693,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1144,6 +1105,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "حذف شمولیت" @@ -1224,6 +1188,12 @@ msgstr "" msgid "Follow-up" msgstr "تعقیب کردن" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "" @@ -1412,11 +1382,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1499,6 +1464,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "ایجاد شده" @@ -1517,6 +1485,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "مقدار" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/ps.po b/i18n/ps.po index 38518df9a7..f8acba0571 100644 --- a/i18n/ps.po +++ b/i18n/ps.po @@ -1,14 +1,14 @@ # # Translators: -# Philip Larsen Donnelly, 2024 # Viktor Varland , 2024 +# Philip Larsen Donnelly, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Viktor Varland , 2024\n" +"Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Pashto (https://app.transifex.com/hisp-uio/teams/100509/ps/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -607,42 +607,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -730,9 +694,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1145,6 +1106,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "د شمولیت حذفول" @@ -1225,6 +1189,12 @@ msgstr "" msgid "Follow-up" msgstr "" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "لغوه شوی" @@ -1413,11 +1383,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1500,6 +1465,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "ایجاد شوی دی" @@ -1518,6 +1486,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "ارزښت یا رقم" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/pt.po b/i18n/pt.po index 0f02ab2cdc..1a05f44f6b 100644 --- a/i18n/pt.po +++ b/i18n/pt.po @@ -4,17 +4,20 @@ # Fernando Jorge Bade, 2023 # Philip Larsen Donnelly, 2024 # Gabriela Rodriguez , 2024 -# Sheila André , 2024 # Ge Joao , 2024 # Viktor Varland , 2024 # Juan M Alcantara Acosta , 2024 +# Sheila André , 2024 +# Jason Pickering , 2024 +# Helton Dias, 2024 +# Shelsea Chumaio, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-10-14T14:53:34.553Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Juan M Alcantara Acosta , 2024\n" +"Last-Translator: Shelsea Chumaio, 2024\n" "Language-Team: Portuguese (https://app.transifex.com/hisp-uio/teams/100509/pt/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -531,7 +534,7 @@ msgid "Type to filter options" msgstr "" msgid "No match found" -msgstr "" +msgstr "Nenhuma correspondência encontrada" msgid "Search" msgstr "Pesquisar" @@ -730,9 +733,6 @@ msgstr "Veja a lista de trabalho neste programa." msgid "Page is missing required values from URL" msgstr "A página tem em falta os valores obrigatórios do URL" -msgid "Program is not valid" -msgstr "O programa não é válido" - msgid "Org unit is not valid with current program" msgstr "A unidade organizacional não é válida com o programa atual" @@ -1166,6 +1166,9 @@ msgstr "Marcar como cancelado" msgid "Mark incomplete" msgstr "Marca incompleta" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Excluir inscrição" @@ -1186,7 +1189,7 @@ msgid "Mark for follow-up" msgstr "Marcar para acompanhamento" msgid "Transfer" -msgstr "" +msgstr "Transferir" msgid "An error occurred while transferring ownership" msgstr "" @@ -1250,6 +1253,12 @@ msgstr "" msgid "Follow-up" msgstr "Acompanhamento" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Cancelado" @@ -1452,11 +1461,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1543,6 +1547,9 @@ msgstr "Registo de mudanças" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "Actualizado" + msgid "Created" msgstr "Criado" @@ -1561,6 +1568,9 @@ msgstr "Item de dados" msgid "Change" msgstr "" +msgid "Value" +msgstr "Valor" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/pt_BR.po b/i18n/pt_BR.po index f33904fb18..dde9b5e1e0 100644 --- a/i18n/pt_BR.po +++ b/i18n/pt_BR.po @@ -1,16 +1,16 @@ # # Translators: # Oscar Mesones Lapouble , 2021 -# Philip Larsen Donnelly, 2024 # Viktor Varland , 2024 # Thiago Rocha, 2024 +# Philip Larsen Donnelly, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Thiago Rocha, 2024\n" +"Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Portuguese (Brazil) (https://app.transifex.com/hisp-uio/teams/100509/pt_BR/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -610,42 +610,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -733,9 +697,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1149,6 +1110,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Excluir inscrição" @@ -1229,6 +1193,12 @@ msgstr "" msgid "Follow-up" msgstr "Seguimento" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Cancelado" @@ -1419,11 +1389,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1507,6 +1472,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "Criado" @@ -1525,6 +1493,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "Valor" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/ro.po b/i18n/ro.po index ee6543821a..ee369e5446 100644 --- a/i18n/ro.po +++ b/i18n/ro.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-10-14T14:53:34.553Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Valeriu Plesca , 2024\n" "Language-Team: Romanian (https://app.transifex.com/hisp-uio/teams/100509/ro/)\n" @@ -708,9 +708,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "În pagină lipsesc valorile obligatorii din URL" -msgid "Program is not valid" -msgstr "Programul nu este valid" - msgid "Org unit is not valid with current program" msgstr "Unitatea organizațională nu este validă cu programul curent" @@ -1130,6 +1127,9 @@ msgstr "Marcare ca anulat" msgid "Mark incomplete" msgstr "Marcare ca incomplet" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Lichidare înrolare" @@ -1210,6 +1210,12 @@ msgstr "" msgid "Follow-up" msgstr "" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Anulat" @@ -1401,11 +1407,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1489,6 +1490,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "" @@ -1507,6 +1511,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/ru.po b/i18n/ru.po index 68ea9d95c7..23d7e47cd1 100644 --- a/i18n/ru.po +++ b/i18n/ru.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-10-14T14:53:34.553Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Russian (https://app.transifex.com/hisp-uio/teams/100509/ru/)\n" @@ -735,9 +735,6 @@ msgstr "Просмотреть рабочий список в данной пр msgid "Page is missing required values from URL" msgstr "Страница не содержит необходимых данных в URL адресе" -msgid "Program is not valid" -msgstr "Программа недействительна" - msgid "Org unit is not valid with current program" msgstr "Организационная единица не действительна для данной программы" @@ -1170,6 +1167,9 @@ msgstr "Присвоить метку \"Отменено\"" msgid "Mark incomplete" msgstr " Присвоить метку \"Незавершено\"" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Удалить регистрационную запись" @@ -1262,6 +1262,12 @@ msgstr "" msgid "Follow-up" msgstr "Наблюдать" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Отменен/а/о" @@ -1483,13 +1489,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "Неопределенные связи, обратитесь к системному администратору" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" -"Ввести данные этапа {{linkableStageLabel}} на следующем шаге после " -"заполнения данных данного этапа {{currentStageLabel}}." - msgid "Enter details now" msgstr "Ввести данные сейчас" @@ -1574,6 +1573,9 @@ msgstr "Лог изменений" msgid "No changes to display" msgstr "Нет изменений для отображения" +msgid "Updated" +msgstr "Обновлено" + msgid "Created" msgstr "Создан/а/о" @@ -1592,6 +1594,9 @@ msgstr "Переменная" msgid "Change" msgstr "Изменить" +msgid "Value" +msgstr "Значение" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "Новая связь для объекта {{trackedEntityTypeName}} " diff --git a/i18n/si.po b/i18n/si.po index 996801aea5..35f0e324d6 100644 --- a/i18n/si.po +++ b/i18n/si.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-08-10T10:42:21.141Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Malinda Wijeratne, 2024\n" "Language-Team: Sinhala (https://app.transifex.com/hisp-uio/teams/100509/si/)\n" @@ -588,15 +588,6 @@ msgstr "" msgid "Selected program is invalid for selected organisation unit" msgstr "" -msgid "Online" -msgstr "" - -msgid "Offline" -msgstr "" - -msgid "Syncing" -msgstr "" - msgid "Add note" msgstr "" @@ -615,42 +606,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -738,9 +693,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1153,6 +1105,9 @@ msgstr "" msgid "Mark incomplete" msgstr "අසම්පූර්ණ බව සලකුණු කරන්න" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1233,10 +1188,10 @@ msgstr "" msgid "Follow-up" msgstr "" -msgid "Started at {{orgUnitName}}" +msgid "Started at{{escape}}" msgstr "" -msgid "Owned by {{ownerOrgUnit}}" +msgid "Owned by{{escape}}" msgstr "" msgid "Cancelled" @@ -1293,6 +1248,9 @@ msgstr "" msgid "Event completed" msgstr "" +msgid "The event cannot be edited after it has been completed" +msgstr "" + msgid "Back to all stages and events" msgstr "" @@ -1424,11 +1382,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1453,13 +1406,27 @@ msgstr "" msgid "New {{ eventName }} event" msgstr "" -msgid "To open this event, please wait until saving is complete" +msgid "An error occurred while deleting the event" msgstr "" -msgid "Show {{ rest }} more" +msgid "" +"Deleting an event is permanent and cannot be undone. Are you sure you want " +"to delete this event?" msgstr "" -msgid "Reset list" +msgid "An error occurred when updating event status" +msgstr "" + +msgid "Unskip" +msgstr "" + +msgid "Skip" +msgstr "" + +msgid "To open this event, please wait until saving is complete" +msgstr "" + +msgid "Show {{ rest }} more" msgstr "" msgid "Go to full {{ eventName }}" @@ -1497,6 +1464,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "" @@ -1515,6 +1485,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "අගය" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/sv.po b/i18n/sv.po index e771dc9cec..6e16f66d26 100644 --- a/i18n/sv.po +++ b/i18n/sv.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Swedish (https://app.transifex.com/hisp-uio/teams/100509/sv/)\n" @@ -609,42 +609,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -732,9 +696,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1147,6 +1108,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1227,6 +1191,12 @@ msgstr "" msgid "Follow-up" msgstr "" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Avbruten" @@ -1415,11 +1385,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1502,6 +1467,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "Uppdaterad" + msgid "Created" msgstr "Skapad" @@ -1520,6 +1488,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "Värde" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/tet.po b/i18n/tet.po index d268e14ea8..4757d41fce 100644 --- a/i18n/tet.po +++ b/i18n/tet.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Tetum (Tetun) (https://app.transifex.com/hisp-uio/teams/100509/tet/)\n" @@ -606,42 +606,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -729,9 +693,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1143,6 +1104,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1223,6 +1187,12 @@ msgstr "" msgid "Follow-up" msgstr "Segimentu" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "" @@ -1409,11 +1379,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1495,6 +1460,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "" @@ -1513,6 +1481,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "Valor" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/tg.po b/i18n/tg.po index 02c2ea6da5..545222c3dc 100644 --- a/i18n/tg.po +++ b/i18n/tg.po @@ -1,14 +1,14 @@ # # Translators: -# Philip Larsen Donnelly, 2024 # Viktor Varland , 2024 +# Philip Larsen Donnelly, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Viktor Varland , 2024\n" +"Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Tajik (https://app.transifex.com/hisp-uio/teams/100509/tg/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -607,42 +607,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -730,9 +694,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1145,6 +1106,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "" @@ -1225,6 +1189,12 @@ msgstr "" msgid "Follow-up" msgstr "Пайгирӣ кардан" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "" @@ -1413,11 +1383,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1500,6 +1465,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "" @@ -1518,6 +1486,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "Қимат" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/uk.po b/i18n/uk.po index b294680692..0506bb74f1 100644 --- a/i18n/uk.po +++ b/i18n/uk.po @@ -1,17 +1,17 @@ # # Translators: -# Philip Larsen Donnelly, 2023 # Wanda , 2024 # Éva Tamási, 2024 # Nadiia , 2024 # Viktor Varland , 2024 +# Philip Larsen Donnelly, 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" -"Last-Translator: Viktor Varland , 2024\n" +"Last-Translator: Philip Larsen Donnelly, 2024\n" "Language-Team: Ukrainian (https://app.transifex.com/hisp-uio/teams/100509/uk/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -612,42 +612,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -735,9 +699,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1152,6 +1113,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Видалити реєстрацію" @@ -1232,6 +1196,12 @@ msgstr "" msgid "Follow-up" msgstr "Подальші дії" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Скасовано" @@ -1424,11 +1394,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1513,6 +1478,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "Створено" @@ -1531,6 +1499,9 @@ msgstr "Елемент даних" msgid "Change" msgstr "" +msgid "Value" +msgstr "Значення" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/ur.po b/i18n/ur.po index 9a1900631a..a955c4e3e1 100644 --- a/i18n/ur.po +++ b/i18n/ur.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Viktor Varland , 2024\n" "Language-Team: Urdu (https://app.transifex.com/hisp-uio/teams/100509/ur/)\n" @@ -607,42 +607,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -730,9 +694,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1145,6 +1106,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "اندراج حذف کریں" @@ -1225,6 +1189,12 @@ msgstr "" msgid "Follow-up" msgstr "" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "منسوخ" @@ -1413,11 +1383,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1500,6 +1465,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "تخلیق" @@ -1518,6 +1486,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "قدر" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/uz_UZ_Cyrl.po b/i18n/uz_UZ_Cyrl.po index 6ad437c602..a397b0df49 100644 --- a/i18n/uz_UZ_Cyrl.po +++ b/i18n/uz_UZ_Cyrl.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Khurshid Ibatov , 2024\n" "Language-Team: Uzbek (Cyrillic) (https://app.transifex.com/hisp-uio/teams/100509/uz@Cyrl/)\n" @@ -624,42 +624,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "\"{{enrollmentId}}\" идентификатори билан қайд қилиш имконсиз" @@ -754,9 +718,6 @@ msgstr "Ушбу дастурдаги ишчи рўйхатни кўриб чи msgid "Page is missing required values from URL" msgstr "URL саҳифасида керакли қийматлар йўқ" -msgid "Program is not valid" -msgstr "Дастур яроқли эмас" - msgid "Org unit is not valid with current program" msgstr "Жорий дастур учун ташкилий бирлик яроқли эмас" @@ -1178,6 +1139,9 @@ msgstr "" msgid "Mark incomplete" msgstr "Тугалланмаган деб белгилансин" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Рўйхатдан ўтказиш ўчирилсин " @@ -1259,6 +1223,12 @@ msgstr "" msgid "Follow-up" msgstr "Кузатиш" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Бекор қилинди" @@ -1446,11 +1416,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1532,6 +1497,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "Янгиланди" + msgid "Created" msgstr "Яратилган" @@ -1550,6 +1518,9 @@ msgstr "Маълумот элементи" msgid "Change" msgstr "" +msgid "Value" +msgstr "Қиймат" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/uz_UZ_Latn.po b/i18n/uz_UZ_Latn.po index 720b8be8e6..cbb6637b95 100644 --- a/i18n/uz_UZ_Latn.po +++ b/i18n/uz_UZ_Latn.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Yury Rogachev , 2024\n" "Language-Team: Uzbek (Latin) (https://app.transifex.com/hisp-uio/teams/100509/uz@Latn/)\n" @@ -625,42 +625,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -748,9 +712,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -1169,6 +1130,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Roʼyxatdan oʼtkazish oʼchirilsin" @@ -1249,6 +1213,12 @@ msgstr "" msgid "Follow-up" msgstr "Kuzatish" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Bekor qilindi" @@ -1435,11 +1405,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1521,6 +1486,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "Yangilandi" + msgid "Created" msgstr "Yaratilgan" @@ -1539,6 +1507,9 @@ msgstr "Maʼlumot elementi" msgid "Change" msgstr "" +msgid "Value" +msgstr "Қиймат" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/vi.po b/i18n/vi.po index 4599936038..5ca15df651 100644 --- a/i18n/vi.po +++ b/i18n/vi.po @@ -1,14 +1,14 @@ # # Translators: -# Philip Larsen Donnelly, 2024 # Mai Nguyen , 2024 # Viktor Varland , 2024 +# Philip Larsen Donnelly, 2024 # Thuy Nguyen , 2024 # msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-09-02T11:08:16.281Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: Thuy Nguyen , 2024\n" "Language-Team: Vietnamese (https://app.transifex.com/hisp-uio/teams/100509/vi/)\n" @@ -622,42 +622,6 @@ msgstr "" msgid "Close the notice" msgstr "" -msgid "Use new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt in for {{programName}}" -msgstr "" - -msgid "" -"By clicking opt-in below, you will start using the new enrollment dashboard " -"in the Capture app for this Tracker program. At the moment, there is certain" -" functionality from Tracker Capture that has not yet been added, including " -"relationship and referral functionality. The work on including this Tracker " -"functionality in Capture is ongoing and will be added in upcoming app " -"releases." -msgstr "" - -msgid "" -"The core team appreciates any feedback on this new functionality which is " -"currently being beta tested, please report any issues and feedback in the " -"DHIS2 JIRA project." -msgstr "" - -msgid "" -"Click the button below to opt-in to the new enrollment dashboard " -"functionality in the Capture app (beta) for this Tracker program for all " -"users." -msgstr "" - -msgid "Yes, opt in" -msgstr "" - -msgid "Stop using new Enrollment dashboard for {{programName}}" -msgstr "" - -msgid "Opt out for {{programName}}" -msgstr "" - msgid "Enrollment with id \"{{enrollmentId}}\" does not exist" msgstr "" @@ -745,9 +709,6 @@ msgstr "" msgid "Page is missing required values from URL" msgstr "" -msgid "Program is not valid" -msgstr "" - msgid "Org unit is not valid with current program" msgstr "" @@ -770,7 +731,7 @@ msgid "Schedule" msgstr "Lịch biểu" msgid "Refer" -msgstr "" +msgstr "Tham chiếu" msgid "You can't add any more {{ programStageName }} events" msgstr "" @@ -1167,6 +1128,9 @@ msgstr "" msgid "Mark incomplete" msgstr "" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "Xóa đăng ký" @@ -1247,6 +1211,12 @@ msgstr "" msgid "Follow-up" msgstr "Theo dõi sau" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "Đã hủy" @@ -1433,11 +1403,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1519,6 +1484,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "" + msgid "Created" msgstr "Đã tạo" @@ -1537,6 +1505,9 @@ msgstr "Mục dữ liệu" msgid "Change" msgstr "" +msgid "Value" +msgstr "Giá trị" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" diff --git a/i18n/zh_CN.po b/i18n/zh_CN.po index 3f3a8e6b43..8d01178792 100644 --- a/i18n/zh_CN.po +++ b/i18n/zh_CN.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: i18next-conv\n" -"POT-Creation-Date: 2024-10-14T14:53:34.553Z\n" +"POT-Creation-Date: 2024-10-25T18:18:11.518Z\n" "PO-Revision-Date: 2019-06-27 07:31+0000\n" "Last-Translator: 晓东 林 <13981924470@126.com>, 2024\n" "Language-Team: Chinese (China) (https://app.transifex.com/hisp-uio/teams/100509/zh_CN/)\n" @@ -697,9 +697,6 @@ msgstr "查看此项目中的工作清单。" msgid "Page is missing required values from URL" msgstr "页面缺少 URL 中的必需值" -msgid "Program is not valid" -msgstr "项目无效" - msgid "Org unit is not valid with current program" msgstr "机构对当前项目无效" @@ -1113,6 +1110,9 @@ msgstr "标记为已取消" msgid "Mark incomplete" msgstr "标记不完整" +msgid "You do not have access to delete this enrollment" +msgstr "" + msgid "Delete enrollment" msgstr "删除报名" @@ -1193,6 +1193,12 @@ msgstr "无法加载报名的小部件。请稍后再试" msgid "Follow-up" msgstr "后续" +msgid "Started at{{escape}}" +msgstr "" + +msgid "Owned by{{escape}}" +msgstr "" + msgid "Cancelled" msgstr "已取消" @@ -1379,11 +1385,6 @@ msgstr "" msgid "Ambiguous relationships, contact system administrator" msgstr "" -msgid "" -"Enter {{linkableStageLabel}} details in the next step after completing this " -"{{currentStageLabel}}." -msgstr "" - msgid "Enter details now" msgstr "" @@ -1465,6 +1466,9 @@ msgstr "" msgid "No changes to display" msgstr "" +msgid "Updated" +msgstr "更新的" + msgid "Created" msgstr "已创建" @@ -1483,6 +1487,9 @@ msgstr "" msgid "Change" msgstr "" +msgid "Value" +msgstr "值" + msgid "New {{trackedEntityTypeName}} relationship" msgstr "" From 2bbea47eb519b6c91a7c76c10bf817e26f35ca41 Mon Sep 17 00:00:00 2001 From: "@dhis2-bot" Date: Sun, 3 Nov 2024 01:49:02 +0000 Subject: [PATCH 43/45] chore(release): cut 101.14.6 [skip release] ## [101.14.6](https://github.com/dhis2/capture-app/compare/v101.14.5...v101.14.6) (2024-11-03) ### Bug Fixes * **translations:** sync translations from transifex (master) ([facbee1](https://github.com/dhis2/capture-app/commit/facbee13d009d11e955a1a9b277e27ba41b63867)) --- CHANGELOG.md | 7 +++++++ package.json | 4 ++-- packages/rules-engine/package.json | 2 +- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8136f020c9..6c192352e2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [101.14.6](https://github.com/dhis2/capture-app/compare/v101.14.5...v101.14.6) (2024-11-03) + + +### Bug Fixes + +* **translations:** sync translations from transifex (master) ([facbee1](https://github.com/dhis2/capture-app/commit/facbee13d009d11e955a1a9b277e27ba41b63867)) + ## [101.14.5](https://github.com/dhis2/capture-app/compare/v101.14.4...v101.14.5) (2024-11-01) diff --git a/package.json b/package.json index c0edde4cd1..59fa6c912d 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "capture-app", "homepage": ".", - "version": "101.14.5", + "version": "101.14.6", "cacheVersion": "7", "serverVersion": "38", "license": "BSD-3-Clause", @@ -10,7 +10,7 @@ "packages/rules-engine" ], "dependencies": { - "@dhis2/rules-engine-javascript": "101.14.5", + "@dhis2/rules-engine-javascript": "101.14.6", "@dhis2/app-runtime": "^3.9.3", "@dhis2/d2-i18n": "^1.1.0", "@dhis2/d2-icons": "^1.0.1", diff --git a/packages/rules-engine/package.json b/packages/rules-engine/package.json index 459d5ca235..dcd47d7c56 100644 --- a/packages/rules-engine/package.json +++ b/packages/rules-engine/package.json @@ -1,6 +1,6 @@ { "name": "@dhis2/rules-engine-javascript", - "version": "101.14.5", + "version": "101.14.6", "license": "BSD-3-Clause", "main": "./build/cjs/index.js", "scripts": { From 1d9ae5731331d3f19a0980cf09ebdd9cc46e4583 Mon Sep 17 00:00:00 2001 From: henrikmv <110386561+henrikmv@users.noreply.github.com> Date: Mon, 4 Nov 2024 09:22:37 +0100 Subject: [PATCH 44/45] fix: [DHIS2-17135][DHIS2-17018] Adjust strings for error messages (#3858) * fix: string adjustment * fix: disable button and add tooltip * Revert "fix: disable button and add tooltip" This reverts commit 8cfb4a655a45420f714d4c12d5d91ce4a90475c9. * fix: string improvement for record access error * fix: string improvement * fix: merge conflict * fix: merge conflict --- i18n/en.pot | 16 ++++++++++------ .../Pages/Enrollment/MissingMessage.component.js | 2 +- .../WidgetAssignee/DisplayMode.component.js | 4 ++-- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/i18n/en.pot b/i18n/en.pot index 5fb403e3d7..370523a4b2 100644 --- a/i18n/en.pot +++ b/i18n/en.pot @@ -674,8 +674,12 @@ msgstr "There are no active enrollments." msgid "Add new enrollment for {{teiDisplayName}} in this program." msgstr "Add new enrollment for {{teiDisplayName}} in this program." -msgid "No access to program owner." -msgstr "No access to program owner." +msgid "" +"You do not have permissions to access to this program, registering unit or " +"record, contact your administrator for more information." +msgstr "" +"You do not have permissions to access to this program, registering unit or " +"record, contact your administrator for more information." msgid "{{teiDisplayName}} is not enrolled in this program." msgstr "{{teiDisplayName}} is not enrolled in this program." @@ -1074,8 +1078,8 @@ msgstr "No tracked entity types available" msgid "Assigned to" msgstr "Assigned to" -msgid "You don't have access to edit this assignee" -msgstr "You don't have access to edit this assignee" +msgid "You don't have access to edit the assigned user" +msgstr "You don't have access to edit the assigned user" msgid "Edit" msgstr "Edit" @@ -1083,8 +1087,8 @@ msgstr "Edit" msgid "No one is assigned to this event" msgstr "No one is assigned to this event" -msgid "You don't have access to assign an assignee" -msgstr "You don't have access to assign an assignee" +msgid "You don't have access to assign a user to this event" +msgstr "You don't have access to assign a user to this event" msgid "Assign" msgstr "Assign" diff --git a/src/core_modules/capture-core/components/Pages/Enrollment/MissingMessage.component.js b/src/core_modules/capture-core/components/Pages/Enrollment/MissingMessage.component.js index 17d36faedd..e46f36adb9 100644 --- a/src/core_modules/capture-core/components/Pages/Enrollment/MissingMessage.component.js +++ b/src/core_modules/capture-core/components/Pages/Enrollment/MissingMessage.component.js @@ -194,7 +194,7 @@ export const MissingMessage = withStyles(getStyles)(({ { missingStatus === missingStatuses.RESTRICTED_PROGRAM_NO_ACCESS && - {i18n.t('No access to program owner.')} + {i18n.t('You do not have permissions to access to this program, registering unit or record, contact your administrator for more information.')} } diff --git a/src/core_modules/capture-core/components/WidgetAssignee/DisplayMode.component.js b/src/core_modules/capture-core/components/WidgetAssignee/DisplayMode.component.js index e0b2ebb2dd..8f49833590 100644 --- a/src/core_modules/capture-core/components/WidgetAssignee/DisplayMode.component.js +++ b/src/core_modules/capture-core/components/WidgetAssignee/DisplayMode.component.js @@ -44,7 +44,7 @@ const DisplayModePlain = ({ assignee, onEdit, writeAccess, avatarId, classes }: {assignee.name}