Skip to content

Commit

Permalink
Merge pull request #40 from EyeSeeTea/feature/user-upload-case-data
Browse files Browse the repository at this point in the history
User Upload of Case Data
  • Loading branch information
bhavananarayanan authored Jan 10, 2025
2 parents cd68605 + a8db71e commit c9a5e8d
Show file tree
Hide file tree
Showing 90 changed files with 3,359 additions and 1,116 deletions.
76 changes: 65 additions & 11 deletions i18n/en.pot
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"POT-Creation-Date: 2024-11-27T21:40:09.970Z\n"
"PO-Revision-Date: 2024-11-27T21:40:09.970Z\n"
"POT-Creation-Date: 2025-01-03T08:28:56.703Z\n"
"PO-Revision-Date: 2025-01-03T08:28:56.703Z\n"

msgid "Low"
msgstr ""
Expand Down Expand Up @@ -75,9 +75,6 @@ msgstr ""
msgid "Save"
msgstr ""

msgid "There is an error in this field"
msgstr ""

msgid "Indicates required"
msgstr ""

Expand All @@ -90,6 +87,9 @@ msgstr ""
msgid "Edit Details"
msgstr ""

msgid "Edit historical case data"
msgstr ""

msgid "Complete Event"
msgstr ""

Expand All @@ -102,6 +102,36 @@ msgstr ""
msgid "Currently assigned:"
msgstr ""

msgid "Multiple uploads not allowed, please select one file"
msgstr ""

msgid "Error uploading file."
msgstr ""

msgid "Select a file"
msgstr ""

msgid "Errors in file"
msgstr ""

msgid "Close"
msgstr ""

msgid "Download empty template"
msgstr ""

msgid "Download historical data"
msgstr ""

msgid "Confirm remove the file"
msgstr ""

msgid "Delete"
msgstr ""

msgid "Are you sure you want to remove the file?"
msgstr ""

msgid "Error loading current Incident Management Team"
msgstr ""

Expand All @@ -114,9 +144,6 @@ msgstr ""
msgid "Map not found."
msgstr ""

msgid "Close"
msgstr ""

msgid "Search"
msgstr ""

Expand Down Expand Up @@ -189,15 +216,35 @@ msgstr ""
msgid "N/A"
msgstr ""

msgid "Add another"
msgid ""
"In order to add or replace cases, you need to download the current file and "
"add the new ones."
msgstr ""

msgid "Form cannot be loaded"
msgid "Please, download the template and add the required data."
msgstr ""

msgid "Disease Outbreak saved successfully"
msgstr ""

msgid "Disease outbreak case data saved successfully"
msgstr ""

msgid "Warning"
msgstr ""

msgid ""
"You have uploaded a new data cases file. This action will replace the "
"current data of this disease outbreak event with the data of the file. Are "
"you sure you want to continue?"
msgstr ""

msgid "Add another"
msgstr ""

msgid "Form cannot be loaded"
msgstr ""

msgid "Risk Assessment Grading saved successfully"
msgstr ""

Expand Down Expand Up @@ -252,8 +299,15 @@ msgstr ""
msgid "Confirm deletion"
msgstr ""

msgid "Delete"
msgid "Are you sure you want to delete these team roles?"
msgstr ""

msgid "Are you sure you want to delete this team role?"
msgstr ""

msgid "Resources"
msgstr ""

msgctxt "DATA"
msgid "HISTORICAL_CASE"
msgstr ""
74 changes: 64 additions & 10 deletions i18n/es.po
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
msgid ""
msgstr ""
"Project-Id-Version: i18next-conv\n"
"POT-Creation-Date: 2024-11-27T21:40:09.970Z\n"
"POT-Creation-Date: 2025-01-03T08:28:56.703Z\n"
"PO-Revision-Date: 2018-10-25T09:02:35.143Z\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -74,9 +74,6 @@ msgstr ""
msgid "Save"
msgstr ""

msgid "There is an error in this field"
msgstr ""

msgid "Indicates required"
msgstr ""

Expand All @@ -89,6 +86,9 @@ msgstr ""
msgid "Edit Details"
msgstr ""

msgid "Edit historical case data"
msgstr ""

msgid "Complete Event"
msgstr ""

Expand All @@ -101,6 +101,36 @@ msgstr ""
msgid "Currently assigned:"
msgstr ""

msgid "Multiple uploads not allowed, please select one file"
msgstr ""

msgid "Error uploading file."
msgstr ""

msgid "Select a file"
msgstr ""

msgid "Errors in file"
msgstr ""

msgid "Close"
msgstr ""

msgid "Download empty template"
msgstr ""

msgid "Download historical data"
msgstr ""

msgid "Confirm remove the file"
msgstr ""

msgid "Delete"
msgstr ""

msgid "Are you sure you want to remove the file?"
msgstr ""

msgid "Error loading current Incident Management Team"
msgstr ""

Expand All @@ -113,9 +143,6 @@ msgstr ""
msgid "Map not found."
msgstr ""

msgid "Close"
msgstr ""

msgid "Search"
msgstr ""

Expand Down Expand Up @@ -188,15 +215,35 @@ msgstr ""
msgid "N/A"
msgstr ""

msgid "Add another"
msgid ""
"In order to add or replace cases, you need to download the current file and "
"add the new ones."
msgstr ""

msgid "Form cannot be loaded"
msgid "Please, download the template and add the required data."
msgstr ""

msgid "Disease Outbreak saved successfully"
msgstr ""

msgid "Disease outbreak case data saved successfully"
msgstr ""

msgid "Warning"
msgstr ""

msgid ""
"You have uploaded a new data cases file. This action will replace the "
"current data of this disease outbreak event with the data of the file. Are "
"you sure you want to continue?"
msgstr ""

msgid "Add another"
msgstr ""

msgid "Form cannot be loaded"
msgstr ""

msgid "Risk Assessment Grading saved successfully"
msgstr ""

Expand Down Expand Up @@ -251,12 +298,19 @@ msgstr ""
msgid "Confirm deletion"
msgstr ""

msgid "Delete"
msgid "Are you sure you want to delete these team roles?"
msgstr ""

msgid "Are you sure you want to delete this team role?"
msgstr ""

msgid "Resources"
msgstr ""

msgctxt "DATA"
msgid "HISTORICAL_CASE"
msgstr ""

#~ msgid "Add"
#~ msgstr "Añadir"

Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,14 @@
"purify-ts-extra-codec": "0.6.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-dropzone": "^14.3.5",
"react-router-dom": "5.2.0",
"real-cancellable-promise": "^1.1.2",
"string-ts": "2.2.0",
"styled-components": "5.3.5",
"styled-jsx": "3.4.5",
"typed-immutable-map": "^0.1.1",
"xlsx": "^0.18.5",
"zustand": "^4.3.7"
},
"devDependencies": {
Expand Down
9 changes: 7 additions & 2 deletions src/CompositionRoot.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ import { MapConfigD2Repository } from "./data/repositories/MapConfigD2Repository
import { MapConfigTestRepository } from "./data/repositories/test/MapConfigTestRepository";
import { GetMapConfigUseCase } from "./domain/usecases/GetMapConfigUseCase";
import { GetProvincesOrgUnits } from "./domain/usecases/GetProvincesOrgUnits";
import { GetAllOrgUnitsUseCase } from "./domain/usecases/GetAllOrgUnitsUseCase";
import { PerformanceOverviewRepository } from "./domain/repositories/PerformanceOverviewRepository";
import { GetAllPerformanceOverviewMetricsUseCase } from "./domain/usecases/GetAllPerformanceOverviewMetricsUseCase";
import { PerformanceOverviewD2Repository } from "./data/repositories/PerformanceOverviewD2Repository";
Expand Down Expand Up @@ -68,6 +67,9 @@ import { ConfigurationsRepository } from "./domain/repositories/ConfigurationsRe
import { ConfigurationsD2Repository } from "./data/repositories/ConfigurationsD2Repository";
import { ConfigurationsTestRepository } from "./data/repositories/test/ConfigurationsTestRepository";
import { CompleteEventTrackerUseCase } from "./domain/usecases/CompleteEventTrackerUseCase";
import { CasesFileD2Repository } from "./data/repositories/CasesFileD2Repository";
import { CasesFileRepository } from "./domain/repositories/CasesFileRepository";
import { CasesFileTestRepository } from "./data/repositories/test/CasesFileTestRepository";
import { UserGroupD2Repository } from "./data/repositories/UserGroupD2Repository";
import { UserGroupRepository } from "./domain/repositories/UserGroupRepository";
import { UserGroupTestRepository } from "./data/repositories/test/UserGroupTestRepository";
Expand All @@ -90,6 +92,7 @@ type Repositories = {
chartConfigRepository: ChartConfigRepository;
systemRepository: SystemRepository;
configurationsRepository: ConfigurationsRepository;
casesFileRepository: CasesFileRepository;
userGroupRepository: UserGroupRepository;
};

Expand All @@ -110,6 +113,7 @@ function getCompositionRoot(repositories: Repositories) {
getConfigurations: new GetConfigurationsUseCase(
repositories.configurationsRepository,
repositories.teamMemberRepository,
repositories.orgUnitRepository,
repositories.userGroupRepository
),
complete: new CompleteEventTrackerUseCase(repositories),
Expand Down Expand Up @@ -138,7 +142,6 @@ function getCompositionRoot(repositories: Repositories) {
getConfig: new GetMapConfigUseCase(repositories.mapConfigRepository),
},
orgUnits: {
getAll: new GetAllOrgUnitsUseCase(repositories.orgUnitRepository),
getProvinces: new GetProvincesOrgUnits(repositories.orgUnitRepository),
},
charts: {
Expand All @@ -165,6 +168,7 @@ export function getWebappCompositionRoot(api: D2Api) {
chartConfigRepository: new ChartConfigD2Repository(dataStoreClient),
systemRepository: new SystemD2Repository(api),
configurationsRepository: new ConfigurationsD2Repository(api),
casesFileRepository: new CasesFileD2Repository(api, dataStoreClient),
userGroupRepository: new UserGroupD2Repository(api),
};

Expand All @@ -188,6 +192,7 @@ export function getTestCompositionRoot() {
chartConfigRepository: new ChartConfigTestRepository(),
systemRepository: new SystemTestRepository(),
configurationsRepository: new ConfigurationsTestRepository(),
casesFileRepository: new CasesFileTestRepository(),
userGroupRepository: new UserGroupTestRepository(),
};

Expand Down
Loading

0 comments on commit c9a5e8d

Please sign in to comment.