@opencrvs/toolkit 2.1.0-rc.5617d8e → 2.1.0-rc.573b41e

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/dist/application-config/index.js +1 -2
  2. package/dist/commons/api/router.d.ts +1645 -1631
  3. package/dist/commons/application-config/index.d.ts +6 -6
  4. package/dist/commons/conditionals/conditionals.d.ts +323 -32
  5. package/dist/commons/events/ActionConfig.d.ts +105 -105
  6. package/dist/commons/events/ActionDocument.d.ts +119 -119
  7. package/dist/commons/events/ActionInput.d.ts +6 -0
  8. package/dist/commons/events/ActionType.d.ts +62 -62
  9. package/dist/commons/events/AdvancedSearchConfig.d.ts +507 -507
  10. package/dist/commons/events/AuditLog.d.ts +43 -43
  11. package/dist/commons/events/CompositeFieldValue.d.ts +4 -4
  12. package/dist/commons/events/Conditional.d.ts +3 -3
  13. package/dist/commons/events/CountryConfigQueryInput.d.ts +590 -590
  14. package/dist/commons/events/Draft.d.ts +37 -37
  15. package/dist/commons/events/DynamicFieldValue.d.ts +9 -9
  16. package/dist/commons/events/EventConfig.d.ts +5 -5
  17. package/dist/commons/events/EventDocument.d.ts +48 -48
  18. package/dist/commons/events/EventIndex.d.ts +62 -62
  19. package/dist/commons/events/EventMetadata.d.ts +40 -40
  20. package/dist/commons/events/FieldConfig.d.ts +337 -337
  21. package/dist/commons/events/FieldType.d.ts +51 -51
  22. package/dist/commons/events/FieldTypeMapping.d.ts +100 -100
  23. package/dist/commons/events/FieldValue.d.ts +12 -12
  24. package/dist/commons/events/Flag.d.ts +15 -15
  25. package/dist/commons/events/TemplateConfig.d.ts +1 -1
  26. package/dist/commons/events/WorkqueueColumnConfig.d.ts +40 -40
  27. package/dist/commons/events/WorkqueueConfig.d.ts +820 -820
  28. package/dist/commons/events/deduplication.d.ts +1 -1
  29. package/dist/commons/events/event.d.ts +2 -2
  30. package/dist/commons/events/field.d.ts +198 -69
  31. package/dist/commons/events/locations.d.ts +6 -99
  32. package/dist/commons/events/mocks.test.utils.d.ts +4 -20
  33. package/dist/commons/events/scopes.d.ts +4 -4
  34. package/dist/commons/events/state/index.d.ts +17 -17
  35. package/dist/commons/events/state/utils.d.ts +7 -7
  36. package/dist/commons/events/test.utils.d.ts +43 -40
  37. package/dist/commons/events/utils.d.ts +114 -114
  38. package/dist/commons/notification/UserNotifications.d.ts +10 -10
  39. package/dist/environment/derived-variables.d.ts +119 -119
  40. package/dist/environment/derived-variables.d.ts.map +1 -1
  41. package/dist/environment/logger.d.ts +12 -3
  42. package/dist/environment/logger.d.ts.map +1 -1
  43. package/dist/environment/manage-users.js +7 -17
  44. package/dist/environment/questions.d.ts +74 -75
  45. package/dist/environment/questions.d.ts.map +1 -1
  46. package/dist/environment/setup-environment.js +14 -8
  47. package/dist/environment/swarm-to-k8s.js +7 -17
  48. package/dist/environment/update-workflows.js +7 -17
  49. package/dist/environment/users.js +7 -17
  50. package/dist/environment/utils.d.ts +1 -1
  51. package/dist/environment/utils.js +7 -17
  52. package/dist/events/deduplication.d.ts +1 -1
  53. package/dist/events/index.js +58 -65
  54. package/dist/migrations/v2.0/convert-config-files-to-ts.js +7 -17
  55. package/dist/migrations/v2.0/migrate-application-config-url.js +3 -4
  56. package/dist/migrations/v2.0/remove-hearth-migrations.js +7 -17
  57. package/dist/notification/index.js +57 -51
  58. package/dist/scopes/index.d.ts +146 -146
  59. package/opencrvs-toolkit-2.1.0-rc.573b41e.tgz +0 -0
  60. package/package.json +4 -3
  61. package/tsconfig.tsbuildinfo +1 -1
  62. package/opencrvs-toolkit-2.1.0-rc.5617d8e.tgz +0 -0
@@ -25,23 +25,13 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
25
25
  }) : function(o, v) {
26
26
  o["default"] = v;
27
27
  });
28
- var __importStar = (this && this.__importStar) || (function () {
29
- var ownKeys = function(o) {
30
- ownKeys = Object.getOwnPropertyNames || function (o) {
31
- var ar = [];
32
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
33
- return ar;
34
- };
35
- return ownKeys(o);
36
- };
37
- return function (mod) {
38
- if (mod && mod.__esModule) return mod;
39
- var result = {};
40
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
41
- __setModuleDefault(result, mod);
42
- return result;
43
- };
44
- })();
28
+ var __importStar = (this && this.__importStar) || function (mod) {
29
+ if (mod && mod.__esModule) return mod;
30
+ var result = {};
31
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
32
+ __setModuleDefault(result, mod);
33
+ return result;
34
+ };
45
35
  var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
46
36
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
47
37
  return new (P || (P = Promise))(function (resolve, reject) {
@@ -25,23 +25,13 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
25
25
  }) : function(o, v) {
26
26
  o["default"] = v;
27
27
  });
28
- var __importStar = (this && this.__importStar) || (function () {
29
- var ownKeys = function(o) {
30
- ownKeys = Object.getOwnPropertyNames || function (o) {
31
- var ar = [];
32
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
33
- return ar;
34
- };
35
- return ownKeys(o);
36
- };
37
- return function (mod) {
38
- if (mod && mod.__esModule) return mod;
39
- var result = {};
40
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
41
- __setModuleDefault(result, mod);
42
- return result;
43
- };
44
- })();
28
+ var __importStar = (this && this.__importStar) || function (mod) {
29
+ if (mod && mod.__esModule) return mod;
30
+ var result = {};
31
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
32
+ __setModuleDefault(result, mod);
33
+ return result;
34
+ };
45
35
  var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
46
36
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
47
37
  return new (P || (P = Promise))(function (resolve, reject) {
@@ -25,23 +25,13 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
25
25
  }) : function(o, v) {
26
26
  o["default"] = v;
27
27
  });
28
- var __importStar = (this && this.__importStar) || (function () {
29
- var ownKeys = function(o) {
30
- ownKeys = Object.getOwnPropertyNames || function (o) {
31
- var ar = [];
32
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
33
- return ar;
34
- };
35
- return ownKeys(o);
36
- };
37
- return function (mod) {
38
- if (mod && mod.__esModule) return mod;
39
- var result = {};
40
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
41
- __setModuleDefault(result, mod);
42
- return result;
43
- };
44
- })();
28
+ var __importStar = (this && this.__importStar) || function (mod) {
29
+ if (mod && mod.__esModule) return mod;
30
+ var result = {};
31
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
32
+ __setModuleDefault(result, mod);
33
+ return result;
34
+ };
45
35
  var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
46
36
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
47
37
  return new (P || (P = Promise))(function (resolve, reject) {
@@ -1,7 +1,7 @@
1
1
  import { Secret, Variable } from './github';
2
2
  import { Answers } from './custom-types';
3
3
  export declare function generateLongPassword(): string;
4
- export declare function findExistingValue<T extends string>(name: string, type: T, scope: 'ENVIRONMENT' | 'REPOSITORY', existingValues: Array<Secret | Variable>): (T extends 'SECRET' ? Secret : T extends 'VARIABLE' ? Variable : never) | undefined;
4
+ export declare function findExistingValue<T extends string>(name: string, type: T, scope: 'ENVIRONMENT' | 'REPOSITORY', existingValues: Array<Secret | Variable>): (T extends "SECRET" ? Secret : T extends "VARIABLE" ? Variable : never) | undefined;
5
5
  /**
6
6
  * Merges and stores secrets in `.env.{environment}` file.
7
7
  * Updates existing variables, preserves unchanged ones, adds new ones.
@@ -25,23 +25,13 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
25
25
  }) : function(o, v) {
26
26
  o["default"] = v;
27
27
  });
28
- var __importStar = (this && this.__importStar) || (function () {
29
- var ownKeys = function(o) {
30
- ownKeys = Object.getOwnPropertyNames || function (o) {
31
- var ar = [];
32
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
33
- return ar;
34
- };
35
- return ownKeys(o);
36
- };
37
- return function (mod) {
38
- if (mod && mod.__esModule) return mod;
39
- var result = {};
40
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
41
- __setModuleDefault(result, mod);
42
- return result;
43
- };
44
- })();
28
+ var __importStar = (this && this.__importStar) || function (mod) {
29
+ if (mod && mod.__esModule) return mod;
30
+ var result = {};
31
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
32
+ __setModuleDefault(result, mod);
33
+ return result;
34
+ };
45
35
  var __importDefault = (this && this.__importDefault) || function (mod) {
46
36
  return (mod && mod.__esModule) ? mod : { "default": mod };
47
37
  };
@@ -59,8 +59,8 @@ export declare function field(fieldId: string): {
59
59
  fieldId: string;
60
60
  type: "dateRange";
61
61
  options: {
62
- pivot?: number | undefined;
63
62
  days: number;
63
+ pivot?: number | undefined;
64
64
  boost?: number | undefined;
65
65
  matchAgainst?: string | undefined;
66
66
  };
@@ -161,9 +161,7 @@ __export(events_exports, {
161
161
  LanguageConfig: () => LanguageConfig,
162
162
  LegalStatuses: () => LegalStatuses,
163
163
  Location: () => Location,
164
- LocationStatus: () => LocationStatus,
165
164
  LocationTypeV1: () => LocationTypeV1,
166
- LocationVersion: () => LocationVersion,
167
165
  METADATA_FIELD_PREFIX: () => METADATA_FIELD_PREFIX,
168
166
  MarkAsDuplicateActionInput: () => MarkAsDuplicateActionInput,
169
167
  MarkNotDuplicateActionInput: () => MarkNotDuplicateActionInput,
@@ -203,8 +201,6 @@ __export(events_exports, {
203
201
  SelectDateRangeOption: () => SelectDateRangeOption,
204
202
  SelectDateRangeValue: () => SelectDateRangeValue,
205
203
  SelectOption: () => SelectOption,
206
- SetAdministrativeAreaPayload: () => SetAdministrativeAreaPayload,
207
- SetLocationPayload: () => SetLocationPayload,
208
204
  ShowConditional: () => ShowConditional,
209
205
  SignatureFieldValue: () => SignatureFieldValue,
210
206
  StaticDataEntry: () => StaticDataEntry,
@@ -437,7 +433,6 @@ __export(events_exports, {
437
433
  resolveDateOfEvent: () => resolveDateOfEvent,
438
434
  resolveEventCustomFlags: () => resolveEventCustomFlags,
439
435
  resolvePlaceOfEvent: () => resolvePlaceOfEvent,
440
- resolveVersion: () => resolveVersion,
441
436
  runClientFunction: () => runClientFunction,
442
437
  runFieldValidations: () => runFieldValidations,
443
438
  runStructuralValidations: () => runStructuralValidations,
@@ -1681,10 +1676,9 @@ var NotifiedAction = ActionBase.extend(
1681
1676
  var EditAction = ActionBase.extend(
1682
1677
  z14.object({
1683
1678
  type: z14.literal(ActionType.EDIT),
1684
- /** @deprecated New Edit-actions should no longer contain content. This is kept for old 2.0 edits. */
1685
1679
  content: z14.object({
1686
1680
  comment: z14.string().describe("Comment for the edit action.").optional()
1687
- }).optional()
1681
+ })
1688
1682
  }).shape
1689
1683
  );
1690
1684
  var PrintContent = z14.object({
@@ -6421,7 +6415,10 @@ var DeclareActionInput = BaseActionInput.extend(
6421
6415
  );
6422
6416
  var EditActionInput = BaseActionInput.extend(
6423
6417
  z38.object({
6424
- type: z38.literal(ActionType.EDIT).default(ActionType.EDIT)
6418
+ type: z38.literal(ActionType.EDIT).default(ActionType.EDIT),
6419
+ content: z38.object({
6420
+ comment: z38.string().describe("Comment for the edit action.").optional()
6421
+ })
6425
6422
  }).shape
6426
6423
  );
6427
6424
  var PrintCertificateActionInput = BaseActionInput.extend(
@@ -9966,6 +9963,7 @@ function eventPayloadGenerator(rng, configuration = tennisClubMembershipEvent) {
9966
9963
  },
9967
9964
  edit: (eventId, input = {}) => ({
9968
9965
  type: ActionType.EDIT,
9966
+ content: { comment: "Test comment" },
9969
9967
  transactionId: input.transactionId ?? getUUID(),
9970
9968
  declaration: input.declaration ?? generateActionDeclarationInput(configuration, ActionType.EDIT, rng),
9971
9969
  annotation: input.annotation ?? generateActionAnnotationInput(configuration, ActionType.EDIT, rng),
@@ -10471,55 +10469,21 @@ var LocationTypeV1 = z43.enum([
10471
10469
  "CRVS_OFFICE",
10472
10470
  "HEALTH_FACILITY"
10473
10471
  ]);
10474
- var LocationStatus = z43.enum(["active", "inactive"]);
10475
- var LocationVersion = z43.object({
10476
- versionId: UUID,
10477
- effectiveFrom: z43.iso.date(),
10478
- name: z43.string(),
10479
- externalId: z43.string().nullish(),
10480
- status: LocationStatus
10481
- });
10482
10472
  var AdministrativeArea = z43.object({
10483
10473
  id: UUID,
10484
10474
  name: z43.string(),
10485
10475
  externalId: z43.string().nullish(),
10486
10476
  parentId: UUID.nullable(),
10487
- status: LocationStatus,
10488
- effectiveFrom: z43.iso.date(),
10489
- versions: z43.array(LocationVersion)
10477
+ validUntil: z43.iso.datetime().nullable()
10490
10478
  });
10491
10479
  var Location = z43.object({
10492
10480
  id: UUID,
10493
10481
  name: z43.string(),
10494
10482
  externalId: z43.string().nullish(),
10495
10483
  administrativeAreaId: UUID.nullable(),
10496
- locationType: z43.string().nullable(),
10497
- status: LocationStatus,
10498
- effectiveFrom: z43.iso.date(),
10499
- versions: z43.array(LocationVersion)
10500
- });
10501
- var SetLocationPayload = z43.object({
10502
- id: UUID,
10503
- name: z43.string(),
10504
- externalId: z43.string().nullish(),
10505
- administrativeAreaId: UUID.nullable(),
10484
+ validUntil: z43.iso.datetime().nullable(),
10506
10485
  locationType: z43.string().nullable()
10507
10486
  });
10508
- var SetAdministrativeAreaPayload = z43.object({
10509
- id: UUID,
10510
- name: z43.string(),
10511
- externalId: z43.string().nullish(),
10512
- parentId: UUID.nullable()
10513
- });
10514
- function resolveVersion(versions, anchor) {
10515
- let resolved = versions[0];
10516
- for (const version of versions) {
10517
- if (version.effectiveFrom <= anchor) {
10518
- resolved = version;
10519
- }
10520
- }
10521
- return resolved;
10522
- }
10523
10487
  function matchesJurisdictionFilter(locationIds, filter, user2) {
10524
10488
  if (!locationIds) {
10525
10489
  return false;
@@ -10999,81 +10963,75 @@ function getFilePathsFromEvent(event2) {
10999
10963
  }
11000
10964
 
11001
10965
  // ../commons/src/events/mocks.test.utils.ts
11002
- function withVersionFields(entity) {
11003
- return {
11004
- ...entity,
11005
- status: "active",
11006
- effectiveFrom: "0001-01-01",
11007
- versions: [
11008
- {
11009
- versionId: entity.id,
11010
- effectiveFrom: "0001-01-01",
11011
- name: entity.name,
11012
- externalId: entity.externalId ?? null,
11013
- status: "active"
11014
- }
11015
- ]
11016
- };
11017
- }
11018
- var MOCK_ADMINISTRATIVE_AREAS_BASE = [
10966
+ var V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS = [
11019
10967
  {
11020
10968
  id: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
11021
10969
  name: "Central",
11022
10970
  parentId: null,
10971
+ validUntil: null,
11023
10972
  externalId: "ydyJb1RAy4U1"
11024
10973
  },
11025
10974
  {
11026
10975
  id: "c599b691-fd2d-45e1-abf4-d185de727fb5",
11027
10976
  name: "Sulaka",
11028
10977
  parentId: null,
10978
+ validUntil: null,
11029
10979
  externalId: "pQ8nGxWmZ2Q3"
11030
10980
  },
11031
10981
  {
11032
10982
  id: "7ef2b9c7-5e6d-49f6-ae05-656207d0fc64",
11033
10983
  name: "Pualula",
11034
10984
  parentId: null,
10985
+ validUntil: null,
11035
10986
  externalId: "Aq91DweLmT8k"
11036
10987
  },
11037
10988
  {
11038
10989
  id: "6d1a59df-988c-4021-a846-ccbc021931a7",
11039
10990
  name: "Chuminga",
11040
10991
  parentId: null,
10992
+ validUntil: null,
11041
10993
  externalId: "Rw0fYNh2Xk9a"
11042
10994
  },
11043
10995
  {
11044
10996
  id: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11045
10997
  name: "Ibombo",
11046
10998
  parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
10999
+ validUntil: null,
11047
11000
  externalId: "k7DsP4vbN1Qe"
11048
11001
  },
11049
11002
  {
11050
11003
  id: "27160bbd-32d1-4625-812f-860226bfb92a",
11051
11004
  name: "Isango",
11052
11005
  parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
11006
+ validUntil: null,
11053
11007
  externalId: "Gm3Z9eQpHw4L"
11054
11008
  },
11055
11009
  {
11056
11010
  id: "967032fd-3f81-478a-826c-30cb8fe121bd",
11057
11011
  name: "Isamba",
11058
11012
  parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
11013
+ validUntil: null,
11059
11014
  externalId: "sT0xVu1KqJ7r"
11060
11015
  },
11061
11016
  {
11062
11017
  id: "89a33893-b17d-481d-a26d-6461e7ac1651",
11063
11018
  name: "Itambo",
11064
11019
  parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
11020
+ validUntil: null,
11065
11021
  externalId: "Nq6Bv2HpL9Te"
11066
11022
  },
11067
11023
  {
11068
11024
  id: "d42ab2fe-e7ed-470e-8b31-4fb27f9b8250",
11069
11025
  name: "Ezhi",
11070
11026
  parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
11027
+ validUntil: null,
11071
11028
  externalId: "xK8cQ0ZRy5Wd"
11072
11029
  },
11073
11030
  {
11074
11031
  id: "8fbd09d2-212b-47f4-beb3-5e1694931d9f",
11075
11032
  name: "Ilanga",
11076
11033
  parentId: "c599b691-fd2d-45e1-abf4-d185de727fb5",
11034
+ validUntil: null,
11077
11035
  externalId: "Cq4Jm1XvN8Ls"
11078
11036
  },
11079
11037
  // Villages under Ibombo (62a0ccb4-880d-4f30-8882-f256007dfff9)
@@ -11081,42 +11039,49 @@ var MOCK_ADMINISTRATIVE_AREAS_BASE = [
11081
11039
  id: "1d4e5f6a-7b8c-4912-8efa-345678901234",
11082
11040
  name: "Klow",
11083
11041
  parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11042
+ validUntil: null,
11084
11043
  externalId: "IkYcYBUcyY2"
11085
11044
  },
11086
11045
  {
11087
11046
  id: "2e5f6a7b-8c9d-4a23-8fab-456789012345",
11088
11047
  name: "Mbondo",
11089
11048
  parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11049
+ validUntil: null,
11090
11050
  externalId: "Qhvv5hvo3mY"
11091
11051
  },
11092
11052
  {
11093
11053
  id: "3f6a7b8c-9d0e-4b34-8abc-567890123456",
11094
11054
  name: "Ndara",
11095
11055
  parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11056
+ validUntil: null,
11096
11057
  externalId: "crXh068O9TR"
11097
11058
  },
11098
11059
  {
11099
11060
  id: "4a7b8c9d-0e1f-4c45-abcd-678901234567",
11100
11061
  name: "Olani",
11101
11062
  parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11063
+ validUntil: null,
11102
11064
  externalId: "r00It8Tvvp7"
11103
11065
  },
11104
11066
  {
11105
11067
  id: "5b8c9d0e-1f2a-4d56-bcde-789012345678",
11106
11068
  name: "Pemba",
11107
11069
  parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11070
+ validUntil: null,
11108
11071
  externalId: "ZnUWsbONIaH"
11109
11072
  },
11110
11073
  {
11111
11074
  id: "6c9d0e1f-2a3b-4e67-8def-890123456789",
11112
11075
  name: "Quanza",
11113
11076
  parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11077
+ validUntil: null,
11114
11078
  externalId: "fDZycvQTa7l"
11115
11079
  },
11116
11080
  {
11117
11081
  id: "7d0e1f2a-3b4c-4f78-8efa-901234567890",
11118
11082
  name: "Rivka",
11119
11083
  parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11084
+ validUntil: null,
11120
11085
  externalId: "KqswxCGTELa"
11121
11086
  },
11122
11087
  // Villages under Isamba (967032fd-3f81-478a-826c-30cb8fe121bd)
@@ -11124,30 +11089,35 @@ var MOCK_ADMINISTRATIVE_AREAS_BASE = [
11124
11089
  id: "8e1f2a3b-4c5d-4089-8fab-012345678901",
11125
11090
  name: "Mbula",
11126
11091
  parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
11092
+ validUntil: null,
11127
11093
  externalId: "osEbKjRc9Kg"
11128
11094
  },
11129
11095
  {
11130
11096
  id: "9f2a3b4c-5d6e-4190-8abf-123456789012",
11131
11097
  name: "Ndoki",
11132
11098
  parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
11099
+ validUntil: null,
11133
11100
  externalId: "aq4daBUAGr3"
11134
11101
  },
11135
11102
  {
11136
11103
  id: "0a3b4c5d-6e7f-4201-abcd-234567890123",
11137
11104
  name: "Tsanga",
11138
11105
  parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
11106
+ validUntil: null,
11139
11107
  externalId: "cqis6Y8trbJ"
11140
11108
  },
11141
11109
  {
11142
11110
  id: "1b4c5d6e-7f8a-4312-bcde-345678901234",
11143
11111
  name: "Waziri",
11144
11112
  parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
11113
+ validUntil: null,
11145
11114
  externalId: "LMijHPyyx6d"
11146
11115
  },
11147
11116
  {
11148
11117
  id: "2c5d6e7f-8a9b-4423-8def-456789012345",
11149
11118
  name: "Zimbi",
11150
11119
  parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
11120
+ validUntil: null,
11151
11121
  externalId: "pcQYbPuKGZ7"
11152
11122
  },
11153
11123
  // Villages under Itambo (89a33893-b17d-481d-a26d-6461e7ac1651)
@@ -11155,59 +11125,67 @@ var MOCK_ADMINISTRATIVE_AREAS_BASE = [
11155
11125
  id: "3d6e7f8a-9b0c-4534-8efa-567890123456",
11156
11126
  name: "Felani",
11157
11127
  parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
11128
+ validUntil: null,
11158
11129
  externalId: "gSqpoCGdMXp"
11159
11130
  },
11160
11131
  {
11161
11132
  id: "4e7f8a9b-0c1d-4645-8fab-678901234567",
11162
11133
  name: "Goroma",
11163
11134
  parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
11135
+ validUntil: null,
11164
11136
  externalId: "KvAAIaNqVrp"
11165
11137
  },
11166
11138
  {
11167
11139
  id: "5f8a9b0c-1d2e-4756-8abc-789012345678",
11168
11140
  name: "Halifu",
11169
11141
  parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
11142
+ validUntil: null,
11170
11143
  externalId: "qe4UnEVt1hv"
11171
11144
  },
11172
11145
  {
11173
11146
  id: "6a9b0c1d-2e3f-4867-abcd-890123456789",
11174
11147
  name: "Jabari",
11175
11148
  parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
11149
+ validUntil: null,
11176
11150
  externalId: "yHH9Nz4rLOt"
11177
11151
  },
11178
11152
  {
11179
11153
  id: "7b0c1d2e-3f4a-4978-bcde-901234567890",
11180
11154
  name: "Kifani",
11181
11155
  parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
11156
+ validUntil: null,
11182
11157
  externalId: "eSWmXIGeu1I"
11183
11158
  },
11184
11159
  {
11185
11160
  id: "8c1d2e3f-4a5b-4089-8def-012345678901",
11186
11161
  name: "Lumela",
11187
11162
  parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
11163
+ validUntil: null,
11188
11164
  externalId: "bh0b3aI1uP3"
11189
11165
  }
11190
11166
  ];
11191
- var V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS = MOCK_ADMINISTRATIVE_AREAS_BASE.map(withVersionFields);
11192
- var MOCK_LOCATIONS_BASE = [
11167
+ var V2_DEFAULT_MOCK_LOCATIONS = [
11193
11168
  {
11194
11169
  id: "6f6186ce-cd5f-4a5f-810a-2d99e7c4ba12",
11195
11170
  name: "Central Provincial Office",
11196
11171
  locationType: "CRVS_OFFICE",
11197
11172
  administrativeAreaId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
11173
+ validUntil: null,
11198
11174
  externalId: "Xr3Df8WpK6Ys"
11199
11175
  },
11200
11176
  {
11201
11177
  id: "b1c2d3e4-f5a6-7890-bcde-f12345678901",
11202
11178
  name: "Central Health Post",
11203
11179
  locationType: "HEALTH_FACILITY",
11204
- administrativeAreaId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c"
11180
+ administrativeAreaId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
11181
+ validUntil: null
11205
11182
  },
11206
11183
  {
11207
11184
  id: "028d2c85-ca31-426d-b5d1-2cef545a4902",
11208
11185
  name: "Ibombo District Office",
11209
11186
  locationType: "CRVS_OFFICE",
11210
11187
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11188
+ validUntil: null,
11211
11189
  externalId: "Sm4Nw7GrD2Vy"
11212
11190
  },
11213
11191
  {
@@ -11215,6 +11193,7 @@ var MOCK_LOCATIONS_BASE = [
11215
11193
  name: "Isamba District Office",
11216
11194
  locationType: "CRVS_OFFICE",
11217
11195
  administrativeAreaId: "967032fd-3f81-478a-826c-30cb8fe121bd",
11196
+ validUntil: null,
11218
11197
  externalId: "Vg1Bq5XeH9Lt"
11219
11198
  },
11220
11199
  {
@@ -11222,6 +11201,7 @@ var MOCK_LOCATIONS_BASE = [
11222
11201
  name: "Isango District Office",
11223
11202
  locationType: "CRVS_OFFICE",
11224
11203
  administrativeAreaId: "27160bbd-32d1-4625-812f-860226bfb92a",
11204
+ validUntil: null,
11225
11205
  externalId: "Je7Lm2XqN9Vz"
11226
11206
  },
11227
11207
  {
@@ -11229,6 +11209,7 @@ var MOCK_LOCATIONS_BASE = [
11229
11209
  name: "Sulaka Provincial Office",
11230
11210
  locationType: "CRVS_OFFICE",
11231
11211
  administrativeAreaId: "c599b691-fd2d-45e1-abf4-d185de727fb5",
11212
+ validUntil: null,
11232
11213
  externalId: "Ht2Wp9KcX5Qv"
11233
11214
  },
11234
11215
  {
@@ -11236,6 +11217,7 @@ var MOCK_LOCATIONS_BASE = [
11236
11217
  name: "Ilanga District Office",
11237
11218
  locationType: "CRVS_OFFICE",
11238
11219
  administrativeAreaId: "8fbd09d2-212b-47f4-beb3-5e1694931d9f",
11220
+ validUntil: null,
11239
11221
  externalId: "Yp6Ds1WqN3Xz"
11240
11222
  },
11241
11223
  {
@@ -11243,6 +11225,7 @@ var MOCK_LOCATIONS_BASE = [
11243
11225
  name: "Chamakubi Health Post",
11244
11226
  locationType: "HEALTH_FACILITY",
11245
11227
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11228
+ validUntil: null,
11246
11229
  externalId: "M1nFr8LbC2Qy"
11247
11230
  },
11248
11231
  {
@@ -11250,6 +11233,7 @@ var MOCK_LOCATIONS_BASE = [
11250
11233
  name: "Ibombo Rural Health Centre",
11251
11234
  locationType: "HEALTH_FACILITY",
11252
11235
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11236
+ validUntil: null,
11253
11237
  externalId: "bT7pV6YrW0Xc"
11254
11238
  },
11255
11239
  {
@@ -11257,6 +11241,7 @@ var MOCK_LOCATIONS_BASE = [
11257
11241
  name: "Chikobo Rural Health Centre",
11258
11242
  locationType: "HEALTH_FACILITY",
11259
11243
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11244
+ validUntil: null,
11260
11245
  externalId: "zE4qPn2SgJ5d"
11261
11246
  },
11262
11247
  {
@@ -11264,6 +11249,7 @@ var MOCK_LOCATIONS_BASE = [
11264
11249
  name: "Chilochabalenje Health Post",
11265
11250
  locationType: "HEALTH_FACILITY",
11266
11251
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11252
+ validUntil: null,
11267
11253
  externalId: "H8vDs1MqR4Uf"
11268
11254
  },
11269
11255
  {
@@ -11271,6 +11257,7 @@ var MOCK_LOCATIONS_BASE = [
11271
11257
  name: "Chipeso Rural Health Centre",
11272
11258
  locationType: "HEALTH_FACILITY",
11273
11259
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11260
+ validUntil: null,
11274
11261
  externalId: "Qw3uZ9KfX6Lm"
11275
11262
  },
11276
11263
  {
@@ -11278,6 +11265,7 @@ var MOCK_LOCATIONS_BASE = [
11278
11265
  name: "Chisamba Rural Health Centre",
11279
11266
  locationType: "HEALTH_FACILITY",
11280
11267
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11268
+ validUntil: null,
11281
11269
  externalId: "Yr0pCg8LdM2s"
11282
11270
  },
11283
11271
  {
@@ -11285,6 +11273,7 @@ var MOCK_LOCATIONS_BASE = [
11285
11273
  name: "Chitanda Rural Health Centre",
11286
11274
  locationType: "HEALTH_FACILITY",
11287
11275
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11276
+ validUntil: null,
11288
11277
  externalId: "tS9gJ4PwB1Qx"
11289
11278
  },
11290
11279
  {
@@ -11292,6 +11281,7 @@ var MOCK_LOCATIONS_BASE = [
11292
11281
  name: "Golden Valley Rural Health Centre",
11293
11282
  locationType: "HEALTH_FACILITY",
11294
11283
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11284
+ validUntil: null,
11295
11285
  externalId: "Ld7Qm3XsA8Vr"
11296
11286
  },
11297
11287
  {
@@ -11299,6 +11289,7 @@ var MOCK_LOCATIONS_BASE = [
11299
11289
  name: "Ipongo Rural Health Centre",
11300
11290
  locationType: "HEALTH_FACILITY",
11301
11291
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11292
+ validUntil: null,
11302
11293
  externalId: "kF2sW9DmH0Bt"
11303
11294
  },
11304
11295
  {
@@ -11306,6 +11297,7 @@ var MOCK_LOCATIONS_BASE = [
11306
11297
  name: "Itumbwe Health Post",
11307
11298
  locationType: "HEALTH_FACILITY",
11308
11299
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11300
+ validUntil: null,
11309
11301
  externalId: "Ue5Xb3VaC7Pq"
11310
11302
  },
11311
11303
  {
@@ -11313,6 +11305,7 @@ var MOCK_LOCATIONS_BASE = [
11313
11305
  name: "Kabangalala Rural Health Centre",
11314
11306
  locationType: "HEALTH_FACILITY",
11315
11307
  administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
11308
+ validUntil: null,
11316
11309
  externalId: "Pz8Kc1TqH6Jn"
11317
11310
  },
11318
11311
  // Village offices
@@ -11321,10 +11314,10 @@ var MOCK_LOCATIONS_BASE = [
11321
11314
  name: "Klow Village Office",
11322
11315
  locationType: "CRVS_OFFICE",
11323
11316
  administrativeAreaId: "1d4e5f6a-7b8c-4912-8efa-345678901234",
11317
+ validUntil: null,
11324
11318
  externalId: "PmAyxAJkxiJ"
11325
11319
  }
11326
11320
  ];
11327
- var V2_DEFAULT_MOCK_LOCATIONS = MOCK_LOCATIONS_BASE.map(withVersionFields);
11328
11321
  var V2_DEFAULT_MOCK_LOCATIONS_MAP = new Map(
11329
11322
  V2_DEFAULT_MOCK_LOCATIONS.map((l) => [l.id, l])
11330
11323
  );
@@ -25,23 +25,13 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
25
25
  }) : function(o, v) {
26
26
  o["default"] = v;
27
27
  });
28
- var __importStar = (this && this.__importStar) || (function () {
29
- var ownKeys = function(o) {
30
- ownKeys = Object.getOwnPropertyNames || function (o) {
31
- var ar = [];
32
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
33
- return ar;
34
- };
35
- return ownKeys(o);
36
- };
37
- return function (mod) {
38
- if (mod && mod.__esModule) return mod;
39
- var result = {};
40
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
41
- __setModuleDefault(result, mod);
42
- return result;
43
- };
44
- })();
28
+ var __importStar = (this && this.__importStar) || function (mod) {
29
+ if (mod && mod.__esModule) return mod;
30
+ var result = {};
31
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
32
+ __setModuleDefault(result, mod);
33
+ return result;
34
+ };
45
35
  var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
46
36
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
47
37
  return new (P || (P = Promise))(function (resolve, reject) {