diff --git a/i18n/en.pot b/i18n/en.pot index 830b0a62dc..71a7f46f88 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-10-16T14:15:58.172Z\n" -"PO-Revision-Date: 2024-10-16T14:15:58.172Z\n" +"POT-Creation-Date: 2024-10-17T17:11:55.065Z\n" +"PO-Revision-Date: 2024-10-17T17:11:55.065Z\n" msgid "Choose one or more dates..." msgstr "Choose one or more dates..." @@ -774,6 +774,9 @@ msgstr "Program Stages could not be loaded" msgid "Stage" msgstr "Stage" +msgid "Registered events" +msgstr "Registered events" + msgid "" "The category option is not valid for the selected organisation unit. Please " "select a valid combination." diff --git a/src/core_modules/capture-core/components/Pages/EnrollmentEditEvent/EnrollmentEditEventPage.container.js b/src/core_modules/capture-core/components/Pages/EnrollmentEditEvent/EnrollmentEditEventPage.container.js index 8532981589..7b9015c53d 100644 --- a/src/core_modules/capture-core/components/Pages/EnrollmentEditEvent/EnrollmentEditEventPage.container.js +++ b/src/core_modules/capture-core/components/Pages/EnrollmentEditEvent/EnrollmentEditEventPage.container.js @@ -137,6 +137,10 @@ const EnrollmentEditEventPageWithContextPlain = ({ const programStage = [...program.stages?.values()].find(item => item.id === stageId); const hideWidgets = useHideWidgetByRuleLocations(program.programRules.concat(programStage?.programRules)); + const onDeleteTrackedEntitySuccess = useCallback(() => { + history.push(`/?${buildUrlQueryString({ orgUnitId, programId })}`); + }, [history, orgUnitId, programId]); + const onBackToMainPage = useCallback(() => { history.push(`/?${buildUrlQueryString({ orgUnitId, programId })}`); }, [history, orgUnitId, programId]); @@ -264,7 +268,7 @@ const EnrollmentEditEventPageWithContextPlain = ({ trackedEntityName={trackedEntityName} program={program} onDelete={onDelete} - onDeleteTrackedEntitySuccess={onBackToMainPage} + onDeleteTrackedEntitySuccess={onDeleteTrackedEntitySuccess} onAddNew={onAddNew} orgUnitId={orgUnitId} eventDate={eventDate} diff --git a/src/core_modules/capture-core/components/Pages/MainPage/EventWorkingListsInit/Header/EventWorkingListsInitHeader.js b/src/core_modules/capture-core/components/Pages/MainPage/EventWorkingListsInit/Header/EventWorkingListsInitHeader.js index ca5c2a09dd..37a869ea4c 100644 --- a/src/core_modules/capture-core/components/Pages/MainPage/EventWorkingListsInit/Header/EventWorkingListsInitHeader.js +++ b/src/core_modules/capture-core/components/Pages/MainPage/EventWorkingListsInit/Header/EventWorkingListsInitHeader.js @@ -1,5 +1,6 @@ // @flow import { colors, spacers } from '@dhis2/ui'; +import i18n from '@dhis2/d2-i18n'; import React, { type ComponentType } from 'react'; import { withStyles } from '@material-ui/core/styles'; import type { Props } from './eventWorkingListsInitHeader.types'; @@ -12,11 +13,28 @@ const getStyles = () => ({ borderRadius: 3, padding: spacers.dp16, }, + headerContainer: { + marginBottom: spacers.dp16, + }, + title: { + fontSize: 16, + color: colors.grey800, + fontWeight: 500, + }, }); const EventWorkingListsInitHeaderPlain = - ({ children, classes: { container, listContainer } }: Props) => ( + ({ children, classes: { container, headerContainer, listContainer, title } }: Props) => (