@opencrvs/toolkit 2.0.0-rc.a928ed6 → 2.0.0-rc.aa3ef7c
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/create-countryconfig/package.json +12 -2
- package/dist/application-config/index.js +27 -14
- package/dist/cli.js +3 -1
- package/dist/commons/api/router.d.ts +14 -3
- package/dist/commons/events/ActionInput.d.ts +36 -36
- package/dist/commons/events/Draft.d.ts +2 -3
- package/dist/commons/events/index.d.ts +1 -0
- package/dist/conditionals/index.js +3 -1
- package/dist/events/index.js +456 -33
- package/dist/migrations/v2.0/index.js +3 -1
- package/dist/notification/index.js +452 -33
- package/dist/scopes/index.js +3 -1
- package/opencrvs-toolkit-2.0.0-rc.aa3ef7c.tgz +0 -0
- package/package.json +5 -1
- package/opencrvs-toolkit-2.0.0-rc.a928ed6.tgz +0 -0
package/dist/events/index.js
CHANGED
|
@@ -213,6 +213,10 @@ __export(events_exports, {
|
|
|
213
213
|
UUID: () => UUID,
|
|
214
214
|
UnassignActionInput: () => UnassignActionInput,
|
|
215
215
|
UserAuditRecordInput: () => UserAuditRecordInput,
|
|
216
|
+
V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS: () => V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS,
|
|
217
|
+
V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS_MAP: () => V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS_MAP,
|
|
218
|
+
V2_DEFAULT_MOCK_LOCATIONS: () => V2_DEFAULT_MOCK_LOCATIONS,
|
|
219
|
+
V2_DEFAULT_MOCK_LOCATIONS_MAP: () => V2_DEFAULT_MOCK_LOCATIONS_MAP,
|
|
216
220
|
ValidationConfig: () => ValidationConfig,
|
|
217
221
|
VerificationActionConfig: () => VerificationActionConfig,
|
|
218
222
|
VerificationPageConfig: () => VerificationPageConfig,
|
|
@@ -704,7 +708,9 @@ var decodeScope = (query) => {
|
|
|
704
708
|
};
|
|
705
709
|
var DEFAULT_SCOPE_OPTIONS = {
|
|
706
710
|
placeOfEvent: JurisdictionFilter.enum.all,
|
|
707
|
-
accessLevel: JurisdictionFilter.enum.all
|
|
711
|
+
accessLevel: JurisdictionFilter.enum.all,
|
|
712
|
+
registeredIn: JurisdictionFilter.enum.all,
|
|
713
|
+
declaredIn: JurisdictionFilter.enum.all
|
|
708
714
|
};
|
|
709
715
|
function getAcceptedScopesByType({
|
|
710
716
|
acceptedScopes,
|
|
@@ -1078,8 +1084,8 @@ var ActionConditional = z7.discriminatedUnion("type", [
|
|
|
1078
1084
|
// Action can be shown to the user in the list but as disabled
|
|
1079
1085
|
EnableConditional
|
|
1080
1086
|
]).meta({
|
|
1081
|
-
|
|
1082
|
-
|
|
1087
|
+
id: "ActionConditional",
|
|
1088
|
+
description: "Conditional gating whether an action is shown (SHOW) or enabled (ENABLE). When omitted from an action, the action is shown and enabled for everyone."
|
|
1083
1089
|
});
|
|
1084
1090
|
var DisplayOnReviewConditional = z7.object({
|
|
1085
1091
|
type: z7.literal(ConditionalType.DISPLAY_ON_REVIEW),
|
|
@@ -1095,8 +1101,8 @@ var FieldConditional = z7.discriminatedUnion("type", [
|
|
|
1095
1101
|
// Field output can be shown / hidden on the review page
|
|
1096
1102
|
DisplayOnReviewConditional
|
|
1097
1103
|
]).meta({
|
|
1098
|
-
|
|
1099
|
-
|
|
1104
|
+
id: "FieldConditional",
|
|
1105
|
+
description: "Conditional gating whether a form field is shown (SHOW), enabled (ENABLE), or displayed on the review page (DISPLAY_ON_REVIEW). When omitted, the field is shown and enabled for everyone, and is displayed on review whenever it has a value."
|
|
1100
1106
|
});
|
|
1101
1107
|
|
|
1102
1108
|
// ../commons/src/events/FieldType.ts
|
|
@@ -1740,8 +1746,8 @@ var FlagConfig = z15.object({
|
|
|
1740
1746
|
),
|
|
1741
1747
|
label: TranslationConfig.describe("Human readable label of the flag.")
|
|
1742
1748
|
}).meta({
|
|
1743
|
-
|
|
1744
|
-
|
|
1749
|
+
id: "FlagConfig",
|
|
1750
|
+
description: "Configuration for a custom flag that can be added to or removed from records by event actions."
|
|
1745
1751
|
});
|
|
1746
1752
|
var ActionFlagConfig = z15.object({
|
|
1747
1753
|
id: Flag,
|
|
@@ -1750,8 +1756,8 @@ var ActionFlagConfig = z15.object({
|
|
|
1750
1756
|
"When conditional is met, the operation is performed on the flag. If not provided, the operation is performed unconditionally."
|
|
1751
1757
|
)
|
|
1752
1758
|
}).meta({
|
|
1753
|
-
|
|
1754
|
-
|
|
1759
|
+
id: "ActionFlagConfig",
|
|
1760
|
+
description: "Add or remove operation applied to a flag when the parent action is accepted. Optionally gated by a conditional."
|
|
1755
1761
|
});
|
|
1756
1762
|
|
|
1757
1763
|
// ../commons/src/events/EventMetadata.ts
|
|
@@ -2181,8 +2187,15 @@ var FieldReference = import_v43.default.object({
|
|
|
2181
2187
|
)
|
|
2182
2188
|
}).describe("Reference to a field by its ID");
|
|
2183
2189
|
var ValidationConfig = import_v43.default.object({
|
|
2184
|
-
validator: Conditional
|
|
2185
|
-
|
|
2190
|
+
validator: Conditional.describe(
|
|
2191
|
+
"Conditional expression that must hold for the field value to be considered valid."
|
|
2192
|
+
),
|
|
2193
|
+
message: TranslationConfig.describe(
|
|
2194
|
+
"Error message displayed when the validator does not hold."
|
|
2195
|
+
)
|
|
2196
|
+
}).meta({
|
|
2197
|
+
id: "ValidationConfig",
|
|
2198
|
+
description: "Validation rule applied to a form field. The validator is a conditional expression that must hold for the field value to be considered valid."
|
|
2186
2199
|
});
|
|
2187
2200
|
var requiredSchema = import_v43.default.union([
|
|
2188
2201
|
import_v43.default.boolean(),
|
|
@@ -2772,17 +2785,21 @@ var HttpField = BaseField.extend({
|
|
|
2772
2785
|
var AutocompleteField = BaseField.extend({
|
|
2773
2786
|
type: import_v43.default.literal(FieldType.AUTOCOMPLETE),
|
|
2774
2787
|
configuration: import_v43.default.object({
|
|
2775
|
-
url: import_v43.default.string().describe(
|
|
2788
|
+
url: import_v43.default.string().describe(
|
|
2789
|
+
"URL to fetch autocomplete suggestions from. This should be a country config server endpoint."
|
|
2790
|
+
).optional(),
|
|
2776
2791
|
method: import_v43.default.enum(["GET", "POST"]).default("GET").optional(),
|
|
2777
2792
|
defaultOptions: import_v43.default.array(
|
|
2778
2793
|
import_v43.default.object({
|
|
2779
2794
|
label: import_v43.default.string(),
|
|
2780
2795
|
value: import_v43.default.string()
|
|
2781
2796
|
})
|
|
2782
|
-
).optional()
|
|
2797
|
+
).optional().describe(
|
|
2798
|
+
"Manual entry is supported through configuration, allowing users to provide values not currently represented in the dataset."
|
|
2799
|
+
)
|
|
2783
2800
|
})
|
|
2784
2801
|
}).meta({
|
|
2785
|
-
description: "
|
|
2802
|
+
description: "Generic autocomplete component designed for use with large dictionary-based datasets. The component supports dynamic retrieval of options from configurable data sources and is intended for datasets that may contain tens or hundreds of thousands of records.",
|
|
2786
2803
|
id: "AutocompleteField"
|
|
2787
2804
|
});
|
|
2788
2805
|
var SearchField = HttpField.extend({
|
|
@@ -3012,15 +3029,18 @@ var VerificationPageConfig = FormPageConfig.extend({
|
|
|
3012
3029
|
actions: VerificationActionConfig
|
|
3013
3030
|
});
|
|
3014
3031
|
var PageConfig = z21.discriminatedUnion("type", [FormPageConfig, VerificationPageConfig]).meta({
|
|
3015
|
-
|
|
3016
|
-
|
|
3032
|
+
id: "PageConfig",
|
|
3033
|
+
description: "Configuration for a single page in a form. Either a form page with fields and a continue button, or a verification page with verify/cancel options."
|
|
3017
3034
|
});
|
|
3018
3035
|
|
|
3019
3036
|
// ../commons/src/events/FormConfig.ts
|
|
3020
3037
|
var DeclarationFormConfig = z22.object({
|
|
3021
3038
|
label: TranslationConfig.describe("Human readable description of the form"),
|
|
3022
3039
|
pages: z22.array(FormPageConfig)
|
|
3023
|
-
}).
|
|
3040
|
+
}).meta({
|
|
3041
|
+
id: "DeclarationFormConfig",
|
|
3042
|
+
description: "Configuration of the declaration form."
|
|
3043
|
+
});
|
|
3024
3044
|
var ActionFormConfig = z22.object({
|
|
3025
3045
|
label: TranslationConfig.describe("Human readable description of the form"),
|
|
3026
3046
|
pages: z22.array(PageConfig)
|
|
@@ -3120,6 +3140,9 @@ var DeduplicationConfig = z23.object({
|
|
|
3120
3140
|
id: z23.string(),
|
|
3121
3141
|
label: TranslationConfig,
|
|
3122
3142
|
query: Clause
|
|
3143
|
+
}).meta({
|
|
3144
|
+
id: "DeduplicationConfig",
|
|
3145
|
+
description: "Configuration for duplicate detection on a declare or register action. The query is built from fuzzy / strict / date-range matchers combined with and/or/not."
|
|
3123
3146
|
});
|
|
3124
3147
|
|
|
3125
3148
|
// ../commons/src/events/ActionConfig.ts
|
|
@@ -3237,17 +3260,42 @@ var ActionConfig = z24.discriminatedUnion("type", [
|
|
|
3237
3260
|
* OpenAPI references are defined here so our generated OpenAPI spec knows to reuse the models
|
|
3238
3261
|
* and treat them as "models" instead of duplicating the data structure in each endpoint.
|
|
3239
3262
|
*/
|
|
3240
|
-
ReadActionConfig.meta({
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3263
|
+
ReadActionConfig.meta({
|
|
3264
|
+
id: "ReadActionConfig",
|
|
3265
|
+
description: "Configuration for the read action \u2014 defines the record-tab content displayed on the event overview page."
|
|
3266
|
+
}),
|
|
3267
|
+
DeclareConfig.meta({
|
|
3268
|
+
id: "DeclareActionConfig",
|
|
3269
|
+
description: "Configuration for the declare action. Includes review-page fields. Shared with the notify action (ActionType.NOTIFY)."
|
|
3270
|
+
}),
|
|
3271
|
+
RejectConfig.meta({
|
|
3272
|
+
id: "RejectActionConfig",
|
|
3273
|
+
description: "Configuration for rejecting a record before registration."
|
|
3274
|
+
}),
|
|
3275
|
+
RegisterConfig.meta({
|
|
3276
|
+
id: "RegisterActionConfig",
|
|
3277
|
+
description: "Configuration for registering a record."
|
|
3278
|
+
}),
|
|
3244
3279
|
PrintCertificateActionConfig.meta({
|
|
3245
|
-
id: "PrintCertificateActionConfig"
|
|
3280
|
+
id: "PrintCertificateActionConfig",
|
|
3281
|
+
description: "Configuration for printing a certificate of a registered record."
|
|
3282
|
+
}),
|
|
3283
|
+
RequestCorrectionConfig.meta({
|
|
3284
|
+
id: "RequestCorrectionActionConfig",
|
|
3285
|
+
description: "Configuration for requesting a correction on a registered record."
|
|
3286
|
+
}),
|
|
3287
|
+
EditActionConfig.meta({
|
|
3288
|
+
id: "EditActionConfig",
|
|
3289
|
+
description: "Configuration for editing a record before registration."
|
|
3290
|
+
}),
|
|
3291
|
+
ArchiveConfig.meta({
|
|
3292
|
+
id: "ArchiveActionConfig",
|
|
3293
|
+
description: "Configuration for archiving a record."
|
|
3246
3294
|
}),
|
|
3247
|
-
|
|
3248
|
-
|
|
3249
|
-
|
|
3250
|
-
|
|
3295
|
+
CustomActionConfig.meta({
|
|
3296
|
+
id: "CustomActionConfig",
|
|
3297
|
+
description: "Configuration for a country-defined custom action. An event may include any number of these."
|
|
3298
|
+
})
|
|
3251
3299
|
]).describe(
|
|
3252
3300
|
"Configuration of an action available for an event. Data collected depends on the action type and is accessible through the annotation property in ActionDocument."
|
|
3253
3301
|
).meta({ id: "ActionConfig" });
|
|
@@ -3323,7 +3371,10 @@ var Field = BaseField2.extend({
|
|
|
3323
3371
|
}).describe("Custom field defined for the summary view.");
|
|
3324
3372
|
var SummaryConfig = z27.object({
|
|
3325
3373
|
fields: z27.array(z27.union([Field, ReferenceField])).describe("Fields displayed in the event summary view.")
|
|
3326
|
-
}).
|
|
3374
|
+
}).meta({
|
|
3375
|
+
id: "SummaryConfig",
|
|
3376
|
+
description: "Configuration of the event overview page. Defines which declaration fields appear in the record summary, optionally with custom labels, empty-value messages, and templated values."
|
|
3377
|
+
});
|
|
3327
3378
|
|
|
3328
3379
|
// ../commons/src/events/AdvancedSearchConfig.ts
|
|
3329
3380
|
var z28 = __toESM(require("zod/v4"));
|
|
@@ -3447,6 +3498,9 @@ var AdvancedSearchField = z28.discriminatedUnion("fieldType", [FieldConfigSchema
|
|
|
3447
3498
|
var AdvancedSearchConfig = z28.object({
|
|
3448
3499
|
title: TranslationConfig.describe("Advanced search tab title"),
|
|
3449
3500
|
fields: z28.array(AdvancedSearchField).describe("Advanced search fields within the tab.")
|
|
3501
|
+
}).meta({
|
|
3502
|
+
id: "AdvancedSearchConfig",
|
|
3503
|
+
description: "Configuration of one advanced search tab. Each tab has a title and a list of searchable fields \u2014 either declaration fields (via `field()`) or event metadata (via `event()`)."
|
|
3450
3504
|
});
|
|
3451
3505
|
|
|
3452
3506
|
// ../commons/src/events/utils.ts
|
|
@@ -5520,8 +5574,9 @@ var EventConfig = _EventConfigBase.superRefine((event2, ctx) => {
|
|
|
5520
5574
|
validateActionFlags(event2, ctx);
|
|
5521
5575
|
validateActionOrder(event2, ctx);
|
|
5522
5576
|
}).meta({
|
|
5523
|
-
id: "EventConfig"
|
|
5524
|
-
|
|
5577
|
+
id: "EventConfig",
|
|
5578
|
+
description: "Configuration defining an event type registered in OpenCRVS (for example birth or death)."
|
|
5579
|
+
});
|
|
5525
5580
|
|
|
5526
5581
|
// ../commons/src/events/EventConfigInput.ts
|
|
5527
5582
|
var defineDeclarationForm = (form) => DeclarationFormConfig.parse(form);
|
|
@@ -5744,6 +5799,9 @@ var WorkqueueColumnValue = z34.object({
|
|
|
5744
5799
|
var WorkqueueColumn = z34.object({
|
|
5745
5800
|
label: TranslationConfig,
|
|
5746
5801
|
value: WorkqueueColumnValue
|
|
5802
|
+
}).meta({
|
|
5803
|
+
id: "WorkqueueColumn",
|
|
5804
|
+
description: "Configuration for a single workqueue column. The value references an event metadata key (e.g. `dateOfEvent`, `status`, `trackingId`)."
|
|
5747
5805
|
});
|
|
5748
5806
|
function defineWorkqueuesColumns(workqueueColumns) {
|
|
5749
5807
|
return workqueueColumns.map(
|
|
@@ -5949,8 +6007,8 @@ var WorkqueueConfigWithoutQuery = WorkqueueConfig.omit({
|
|
|
5949
6007
|
var WorkqueueConfigInput = WorkqueueConfig.extend({
|
|
5950
6008
|
query: CountryConfigQueryInputType
|
|
5951
6009
|
}).meta({
|
|
5952
|
-
|
|
5953
|
-
|
|
6010
|
+
id: "WorkqueueConfig",
|
|
6011
|
+
description: "Configuration for a single workqueue. Defines the filter applied to the event index, the quick-action button, the columns shown on each row, and the message rendered when the queue is empty."
|
|
5954
6012
|
});
|
|
5955
6013
|
function defineWorkqueue(workqueueInput) {
|
|
5956
6014
|
const queryInput = workqueueInput.query;
|
|
@@ -6013,7 +6071,9 @@ var BaseActionInput = z38.object({
|
|
|
6013
6071
|
keepAssignment: z38.boolean().optional(),
|
|
6014
6072
|
keepAssignmentIfAccepted: z38.boolean().optional(),
|
|
6015
6073
|
keepAssignmentIfRejected: z38.boolean().optional(),
|
|
6016
|
-
waitFor: z38.boolean().
|
|
6074
|
+
waitFor: z38.boolean().default(true).describe(
|
|
6075
|
+
"Whether action waits for the indexing before returning. Defaults to true. Setting this to to false completes faster but might lead to stale data in the client if the client tries to read the event immediately after performing the action. Use with care."
|
|
6076
|
+
),
|
|
6017
6077
|
// For normal users, the createdAtLocation is resolved on the backend from the user's primaryOfficeId.
|
|
6018
6078
|
// @TODO: createdAtLocation should be limited to actions that system users can perform. For normal users, it should not be part of the base action.
|
|
6019
6079
|
createdAtLocation: UUID.nullish().describe(
|
|
@@ -6193,7 +6253,7 @@ var Draft = z39.object({
|
|
|
6193
6253
|
}).describe(
|
|
6194
6254
|
"A temporary storage for an action. Stored with details of the event, creator and creation time."
|
|
6195
6255
|
);
|
|
6196
|
-
var DraftInput = BaseActionInput.extend({
|
|
6256
|
+
var DraftInput = BaseActionInput.omit({ waitFor: true }).extend({
|
|
6197
6257
|
type: ActionTypes.exclude([ActionTypes.enum.DELETE]),
|
|
6198
6258
|
status: z39.enum([
|
|
6199
6259
|
ActionStatus.Requested,
|
|
@@ -10433,3 +10493,366 @@ function getFilePathsFromEvent(event2) {
|
|
|
10433
10493
|
});
|
|
10434
10494
|
return (0, import_lodash7.uniq)(filepaths);
|
|
10435
10495
|
}
|
|
10496
|
+
|
|
10497
|
+
// ../commons/src/events/mocks.test.utils.ts
|
|
10498
|
+
var V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS = [
|
|
10499
|
+
{
|
|
10500
|
+
id: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10501
|
+
name: "Central",
|
|
10502
|
+
parentId: null,
|
|
10503
|
+
validUntil: null,
|
|
10504
|
+
externalId: "ydyJb1RAy4U1"
|
|
10505
|
+
},
|
|
10506
|
+
{
|
|
10507
|
+
id: "c599b691-fd2d-45e1-abf4-d185de727fb5",
|
|
10508
|
+
name: "Sulaka",
|
|
10509
|
+
parentId: null,
|
|
10510
|
+
validUntil: null,
|
|
10511
|
+
externalId: "pQ8nGxWmZ2Q3"
|
|
10512
|
+
},
|
|
10513
|
+
{
|
|
10514
|
+
id: "7ef2b9c7-5e6d-49f6-ae05-656207d0fc64",
|
|
10515
|
+
name: "Pualula",
|
|
10516
|
+
parentId: null,
|
|
10517
|
+
validUntil: null,
|
|
10518
|
+
externalId: "Aq91DweLmT8k"
|
|
10519
|
+
},
|
|
10520
|
+
{
|
|
10521
|
+
id: "6d1a59df-988c-4021-a846-ccbc021931a7",
|
|
10522
|
+
name: "Chuminga",
|
|
10523
|
+
parentId: null,
|
|
10524
|
+
validUntil: null,
|
|
10525
|
+
externalId: "Rw0fYNh2Xk9a"
|
|
10526
|
+
},
|
|
10527
|
+
{
|
|
10528
|
+
id: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10529
|
+
name: "Ibombo",
|
|
10530
|
+
parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10531
|
+
validUntil: null,
|
|
10532
|
+
externalId: "k7DsP4vbN1Qe"
|
|
10533
|
+
},
|
|
10534
|
+
{
|
|
10535
|
+
id: "27160bbd-32d1-4625-812f-860226bfb92a",
|
|
10536
|
+
name: "Isango",
|
|
10537
|
+
parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10538
|
+
validUntil: null,
|
|
10539
|
+
externalId: "Gm3Z9eQpHw4L"
|
|
10540
|
+
},
|
|
10541
|
+
{
|
|
10542
|
+
id: "967032fd-3f81-478a-826c-30cb8fe121bd",
|
|
10543
|
+
name: "Isamba",
|
|
10544
|
+
parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10545
|
+
validUntil: null,
|
|
10546
|
+
externalId: "sT0xVu1KqJ7r"
|
|
10547
|
+
},
|
|
10548
|
+
{
|
|
10549
|
+
id: "89a33893-b17d-481d-a26d-6461e7ac1651",
|
|
10550
|
+
name: "Itambo",
|
|
10551
|
+
parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10552
|
+
validUntil: null,
|
|
10553
|
+
externalId: "Nq6Bv2HpL9Te"
|
|
10554
|
+
},
|
|
10555
|
+
{
|
|
10556
|
+
id: "d42ab2fe-e7ed-470e-8b31-4fb27f9b8250",
|
|
10557
|
+
name: "Ezhi",
|
|
10558
|
+
parentId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10559
|
+
validUntil: null,
|
|
10560
|
+
externalId: "xK8cQ0ZRy5Wd"
|
|
10561
|
+
},
|
|
10562
|
+
{
|
|
10563
|
+
id: "8fbd09d2-212b-47f4-beb3-5e1694931d9f",
|
|
10564
|
+
name: "Ilanga",
|
|
10565
|
+
parentId: "c599b691-fd2d-45e1-abf4-d185de727fb5",
|
|
10566
|
+
validUntil: null,
|
|
10567
|
+
externalId: "Cq4Jm1XvN8Ls"
|
|
10568
|
+
},
|
|
10569
|
+
// Villages under Ibombo (62a0ccb4-880d-4f30-8882-f256007dfff9)
|
|
10570
|
+
{
|
|
10571
|
+
id: "1d4e5f6a-7b8c-4912-8efa-345678901234",
|
|
10572
|
+
name: "Klow",
|
|
10573
|
+
parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10574
|
+
validUntil: null,
|
|
10575
|
+
externalId: "IkYcYBUcyY2"
|
|
10576
|
+
},
|
|
10577
|
+
{
|
|
10578
|
+
id: "2e5f6a7b-8c9d-4a23-8fab-456789012345",
|
|
10579
|
+
name: "Mbondo",
|
|
10580
|
+
parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10581
|
+
validUntil: null,
|
|
10582
|
+
externalId: "Qhvv5hvo3mY"
|
|
10583
|
+
},
|
|
10584
|
+
{
|
|
10585
|
+
id: "3f6a7b8c-9d0e-4b34-8abc-567890123456",
|
|
10586
|
+
name: "Ndara",
|
|
10587
|
+
parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10588
|
+
validUntil: null,
|
|
10589
|
+
externalId: "crXh068O9TR"
|
|
10590
|
+
},
|
|
10591
|
+
{
|
|
10592
|
+
id: "4a7b8c9d-0e1f-4c45-abcd-678901234567",
|
|
10593
|
+
name: "Olani",
|
|
10594
|
+
parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10595
|
+
validUntil: null,
|
|
10596
|
+
externalId: "r00It8Tvvp7"
|
|
10597
|
+
},
|
|
10598
|
+
{
|
|
10599
|
+
id: "5b8c9d0e-1f2a-4d56-bcde-789012345678",
|
|
10600
|
+
name: "Pemba",
|
|
10601
|
+
parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10602
|
+
validUntil: null,
|
|
10603
|
+
externalId: "ZnUWsbONIaH"
|
|
10604
|
+
},
|
|
10605
|
+
{
|
|
10606
|
+
id: "6c9d0e1f-2a3b-4e67-8def-890123456789",
|
|
10607
|
+
name: "Quanza",
|
|
10608
|
+
parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10609
|
+
validUntil: null,
|
|
10610
|
+
externalId: "fDZycvQTa7l"
|
|
10611
|
+
},
|
|
10612
|
+
{
|
|
10613
|
+
id: "7d0e1f2a-3b4c-4f78-8efa-901234567890",
|
|
10614
|
+
name: "Rivka",
|
|
10615
|
+
parentId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10616
|
+
validUntil: null,
|
|
10617
|
+
externalId: "KqswxCGTELa"
|
|
10618
|
+
},
|
|
10619
|
+
// Villages under Isamba (967032fd-3f81-478a-826c-30cb8fe121bd)
|
|
10620
|
+
{
|
|
10621
|
+
id: "8e1f2a3b-4c5d-4089-8fab-012345678901",
|
|
10622
|
+
name: "Mbula",
|
|
10623
|
+
parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
|
|
10624
|
+
validUntil: null,
|
|
10625
|
+
externalId: "osEbKjRc9Kg"
|
|
10626
|
+
},
|
|
10627
|
+
{
|
|
10628
|
+
id: "9f2a3b4c-5d6e-4190-8abf-123456789012",
|
|
10629
|
+
name: "Ndoki",
|
|
10630
|
+
parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
|
|
10631
|
+
validUntil: null,
|
|
10632
|
+
externalId: "aq4daBUAGr3"
|
|
10633
|
+
},
|
|
10634
|
+
{
|
|
10635
|
+
id: "0a3b4c5d-6e7f-4201-abcd-234567890123",
|
|
10636
|
+
name: "Tsanga",
|
|
10637
|
+
parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
|
|
10638
|
+
validUntil: null,
|
|
10639
|
+
externalId: "cqis6Y8trbJ"
|
|
10640
|
+
},
|
|
10641
|
+
{
|
|
10642
|
+
id: "1b4c5d6e-7f8a-4312-bcde-345678901234",
|
|
10643
|
+
name: "Waziri",
|
|
10644
|
+
parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
|
|
10645
|
+
validUntil: null,
|
|
10646
|
+
externalId: "LMijHPyyx6d"
|
|
10647
|
+
},
|
|
10648
|
+
{
|
|
10649
|
+
id: "2c5d6e7f-8a9b-4423-8def-456789012345",
|
|
10650
|
+
name: "Zimbi",
|
|
10651
|
+
parentId: "967032fd-3f81-478a-826c-30cb8fe121bd",
|
|
10652
|
+
validUntil: null,
|
|
10653
|
+
externalId: "pcQYbPuKGZ7"
|
|
10654
|
+
},
|
|
10655
|
+
// Villages under Itambo (89a33893-b17d-481d-a26d-6461e7ac1651)
|
|
10656
|
+
{
|
|
10657
|
+
id: "3d6e7f8a-9b0c-4534-8efa-567890123456",
|
|
10658
|
+
name: "Felani",
|
|
10659
|
+
parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
|
|
10660
|
+
validUntil: null,
|
|
10661
|
+
externalId: "gSqpoCGdMXp"
|
|
10662
|
+
},
|
|
10663
|
+
{
|
|
10664
|
+
id: "4e7f8a9b-0c1d-4645-8fab-678901234567",
|
|
10665
|
+
name: "Goroma",
|
|
10666
|
+
parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
|
|
10667
|
+
validUntil: null,
|
|
10668
|
+
externalId: "KvAAIaNqVrp"
|
|
10669
|
+
},
|
|
10670
|
+
{
|
|
10671
|
+
id: "5f8a9b0c-1d2e-4756-8abc-789012345678",
|
|
10672
|
+
name: "Halifu",
|
|
10673
|
+
parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
|
|
10674
|
+
validUntil: null,
|
|
10675
|
+
externalId: "qe4UnEVt1hv"
|
|
10676
|
+
},
|
|
10677
|
+
{
|
|
10678
|
+
id: "6a9b0c1d-2e3f-4867-abcd-890123456789",
|
|
10679
|
+
name: "Jabari",
|
|
10680
|
+
parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
|
|
10681
|
+
validUntil: null,
|
|
10682
|
+
externalId: "yHH9Nz4rLOt"
|
|
10683
|
+
},
|
|
10684
|
+
{
|
|
10685
|
+
id: "7b0c1d2e-3f4a-4978-bcde-901234567890",
|
|
10686
|
+
name: "Kifani",
|
|
10687
|
+
parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
|
|
10688
|
+
validUntil: null,
|
|
10689
|
+
externalId: "eSWmXIGeu1I"
|
|
10690
|
+
},
|
|
10691
|
+
{
|
|
10692
|
+
id: "8c1d2e3f-4a5b-4089-8def-012345678901",
|
|
10693
|
+
name: "Lumela",
|
|
10694
|
+
parentId: "89a33893-b17d-481d-a26d-6461e7ac1651",
|
|
10695
|
+
validUntil: null,
|
|
10696
|
+
externalId: "bh0b3aI1uP3"
|
|
10697
|
+
}
|
|
10698
|
+
];
|
|
10699
|
+
var V2_DEFAULT_MOCK_LOCATIONS = [
|
|
10700
|
+
{
|
|
10701
|
+
id: "6f6186ce-cd5f-4a5f-810a-2d99e7c4ba12",
|
|
10702
|
+
name: "Central Provincial Office",
|
|
10703
|
+
locationType: "CRVS_OFFICE",
|
|
10704
|
+
administrativeAreaId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10705
|
+
validUntil: null,
|
|
10706
|
+
externalId: "Xr3Df8WpK6Ys"
|
|
10707
|
+
},
|
|
10708
|
+
{
|
|
10709
|
+
id: "b1c2d3e4-f5a6-7890-bcde-f12345678901",
|
|
10710
|
+
name: "Central Health Post",
|
|
10711
|
+
locationType: "HEALTH_FACILITY",
|
|
10712
|
+
administrativeAreaId: "a45b982a-5c7b-4bd9-8fd8-a42d0994054c",
|
|
10713
|
+
validUntil: null
|
|
10714
|
+
},
|
|
10715
|
+
{
|
|
10716
|
+
id: "028d2c85-ca31-426d-b5d1-2cef545a4902",
|
|
10717
|
+
name: "Ibombo District Office",
|
|
10718
|
+
locationType: "CRVS_OFFICE",
|
|
10719
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10720
|
+
validUntil: null,
|
|
10721
|
+
externalId: "Sm4Nw7GrD2Vy"
|
|
10722
|
+
},
|
|
10723
|
+
{
|
|
10724
|
+
id: "62a0ccb4-4f30-4f30-8882-f256007dff9f",
|
|
10725
|
+
name: "Isamba District Office",
|
|
10726
|
+
locationType: "CRVS_OFFICE",
|
|
10727
|
+
administrativeAreaId: "967032fd-3f81-478a-826c-30cb8fe121bd",
|
|
10728
|
+
validUntil: null,
|
|
10729
|
+
externalId: "Vg1Bq5XeH9Lt"
|
|
10730
|
+
},
|
|
10731
|
+
{
|
|
10732
|
+
id: "954c93e1-13f7-4435-bb82-35e0e215e07d",
|
|
10733
|
+
name: "Isango District Office",
|
|
10734
|
+
locationType: "CRVS_OFFICE",
|
|
10735
|
+
administrativeAreaId: "27160bbd-32d1-4625-812f-860226bfb92a",
|
|
10736
|
+
validUntil: null,
|
|
10737
|
+
externalId: "Je7Lm2XqN9Vz"
|
|
10738
|
+
},
|
|
10739
|
+
{
|
|
10740
|
+
id: "2884f5b9-17b4-49ce-bf4d-f538228935df",
|
|
10741
|
+
name: "Sulaka Provincial Office",
|
|
10742
|
+
locationType: "CRVS_OFFICE",
|
|
10743
|
+
administrativeAreaId: "c599b691-fd2d-45e1-abf4-d185de727fb5",
|
|
10744
|
+
validUntil: null,
|
|
10745
|
+
externalId: "Ht2Wp9KcX5Qv"
|
|
10746
|
+
},
|
|
10747
|
+
{
|
|
10748
|
+
id: "030358c6-54af-44be-821b-8e4af963a49c",
|
|
10749
|
+
name: "Ilanga District Office",
|
|
10750
|
+
locationType: "CRVS_OFFICE",
|
|
10751
|
+
administrativeAreaId: "8fbd09d2-212b-47f4-beb3-5e1694931d9f",
|
|
10752
|
+
validUntil: null,
|
|
10753
|
+
externalId: "Yp6Ds1WqN3Xz"
|
|
10754
|
+
},
|
|
10755
|
+
{
|
|
10756
|
+
id: "423d000f-101b-47c0-8b86-21a908067cee",
|
|
10757
|
+
name: "Chamakubi Health Post",
|
|
10758
|
+
locationType: "HEALTH_FACILITY",
|
|
10759
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10760
|
+
validUntil: null,
|
|
10761
|
+
externalId: "M1nFr8LbC2Qy"
|
|
10762
|
+
},
|
|
10763
|
+
{
|
|
10764
|
+
id: "4d3279be-d026-420c-88f7-f0a4ae986973",
|
|
10765
|
+
name: "Ibombo Rural Health Centre",
|
|
10766
|
+
locationType: "HEALTH_FACILITY",
|
|
10767
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10768
|
+
validUntil: null,
|
|
10769
|
+
externalId: "bT7pV6YrW0Xc"
|
|
10770
|
+
},
|
|
10771
|
+
{
|
|
10772
|
+
id: "190902f4-1d77-476a-8947-41145af1db7d",
|
|
10773
|
+
name: "Chikobo Rural Health Centre",
|
|
10774
|
+
locationType: "HEALTH_FACILITY",
|
|
10775
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10776
|
+
validUntil: null,
|
|
10777
|
+
externalId: "zE4qPn2SgJ5d"
|
|
10778
|
+
},
|
|
10779
|
+
{
|
|
10780
|
+
id: "f5ecbd9b-a01e-4a65-910e-70e86ab41b71",
|
|
10781
|
+
name: "Chilochabalenje Health Post",
|
|
10782
|
+
locationType: "HEALTH_FACILITY",
|
|
10783
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10784
|
+
validUntil: null,
|
|
10785
|
+
externalId: "H8vDs1MqR4Uf"
|
|
10786
|
+
},
|
|
10787
|
+
{
|
|
10788
|
+
id: "dbfc178f-7295-4b90-b28d-111c95b03127",
|
|
10789
|
+
name: "Chipeso Rural Health Centre",
|
|
10790
|
+
locationType: "HEALTH_FACILITY",
|
|
10791
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10792
|
+
validUntil: null,
|
|
10793
|
+
externalId: "Qw3uZ9KfX6Lm"
|
|
10794
|
+
},
|
|
10795
|
+
{
|
|
10796
|
+
id: "09862bfe-c7ac-46cd-987b-668681533c80",
|
|
10797
|
+
name: "Chisamba Rural Health Centre",
|
|
10798
|
+
locationType: "HEALTH_FACILITY",
|
|
10799
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10800
|
+
validUntil: null,
|
|
10801
|
+
externalId: "Yr0pCg8LdM2s"
|
|
10802
|
+
},
|
|
10803
|
+
{
|
|
10804
|
+
id: "834ce389-e95b-4fb0-96a0-33e9ab323059",
|
|
10805
|
+
name: "Chitanda Rural Health Centre",
|
|
10806
|
+
locationType: "HEALTH_FACILITY",
|
|
10807
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10808
|
+
validUntil: null,
|
|
10809
|
+
externalId: "tS9gJ4PwB1Qx"
|
|
10810
|
+
},
|
|
10811
|
+
{
|
|
10812
|
+
id: "0431c433-6062-4a4c-aee9-25271aec61ee",
|
|
10813
|
+
name: "Golden Valley Rural Health Centre",
|
|
10814
|
+
locationType: "HEALTH_FACILITY",
|
|
10815
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10816
|
+
validUntil: null,
|
|
10817
|
+
externalId: "Ld7Qm3XsA8Vr"
|
|
10818
|
+
},
|
|
10819
|
+
{
|
|
10820
|
+
id: "bc84d0b6-7ba7-480d-a339-5d9920d90eb2",
|
|
10821
|
+
name: "Ipongo Rural Health Centre",
|
|
10822
|
+
locationType: "HEALTH_FACILITY",
|
|
10823
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10824
|
+
validUntil: null,
|
|
10825
|
+
externalId: "kF2sW9DmH0Bt"
|
|
10826
|
+
},
|
|
10827
|
+
{
|
|
10828
|
+
id: "4cf1f53b-b730-41d2-8649-dff7eeed970d",
|
|
10829
|
+
name: "Itumbwe Health Post",
|
|
10830
|
+
locationType: "HEALTH_FACILITY",
|
|
10831
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10832
|
+
validUntil: null,
|
|
10833
|
+
externalId: "Ue5Xb3VaC7Pq"
|
|
10834
|
+
},
|
|
10835
|
+
{
|
|
10836
|
+
id: "4b3676cb-9355-4942-9eb9-2ce46acaf0e0",
|
|
10837
|
+
name: "Kabangalala Rural Health Centre",
|
|
10838
|
+
locationType: "HEALTH_FACILITY",
|
|
10839
|
+
administrativeAreaId: "62a0ccb4-880d-4f30-8882-f256007dfff9",
|
|
10840
|
+
validUntil: null,
|
|
10841
|
+
externalId: "Pz8Kc1TqH6Jn"
|
|
10842
|
+
},
|
|
10843
|
+
// Village offices
|
|
10844
|
+
{
|
|
10845
|
+
id: "1f4a5b6c-7d8e-4312-8abc-345678901234",
|
|
10846
|
+
name: "Klow Village Office",
|
|
10847
|
+
locationType: "CRVS_OFFICE",
|
|
10848
|
+
administrativeAreaId: "1d4e5f6a-7b8c-4912-8efa-345678901234",
|
|
10849
|
+
validUntil: null,
|
|
10850
|
+
externalId: "PmAyxAJkxiJ"
|
|
10851
|
+
}
|
|
10852
|
+
];
|
|
10853
|
+
var V2_DEFAULT_MOCK_LOCATIONS_MAP = new Map(
|
|
10854
|
+
V2_DEFAULT_MOCK_LOCATIONS.map((l) => [l.id, l])
|
|
10855
|
+
);
|
|
10856
|
+
var V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS_MAP = new Map(
|
|
10857
|
+
V2_DEFAULT_MOCK_ADMINISTRATIVE_AREAS.map((a) => [a.id, a])
|
|
10858
|
+
);
|
|
@@ -2405,7 +2405,9 @@ var decodeScope = (query) => {
|
|
|
2405
2405
|
};
|
|
2406
2406
|
var DEFAULT_SCOPE_OPTIONS = {
|
|
2407
2407
|
placeOfEvent: JurisdictionFilter.enum.all,
|
|
2408
|
-
accessLevel: JurisdictionFilter.enum.all
|
|
2408
|
+
accessLevel: JurisdictionFilter.enum.all,
|
|
2409
|
+
registeredIn: JurisdictionFilter.enum.all,
|
|
2410
|
+
declaredIn: JurisdictionFilter.enum.all
|
|
2409
2411
|
};
|
|
2410
2412
|
|
|
2411
2413
|
// ../commons/src/scopes.deprecated.do-not-use.ts
|