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