@opencrvs/toolkit 2.1.0-rc.93572dd → 2.1.0-rc.954dd73
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 +202 -191
- package/dist/commons/api/router.d.ts +86 -1
- package/dist/commons/conditionals/conditionals.d.ts +6 -6
- package/dist/commons/conditionals/validate.d.ts +16 -1
- package/dist/commons/events/ActionDocument.d.ts +1 -7
- package/dist/commons/events/ActionStatus.d.ts +14 -0
- package/dist/commons/events/AdvancedSearchConfig.d.ts +12 -0
- package/dist/commons/events/AuditLog.d.ts +37 -0
- package/dist/commons/events/EventConfig.d.ts +3 -0
- package/dist/commons/events/EventIndex.d.ts +1 -24
- package/dist/commons/events/FieldConfig.d.ts +62 -52
- package/dist/commons/events/FieldTypeMapping.d.ts +27 -27
- package/dist/commons/events/Flag.d.ts +42 -0
- package/dist/commons/events/WorkqueueConfig.d.ts +17 -14
- package/dist/commons/events/event.d.ts +12 -0
- package/dist/commons/events/index.d.ts +1 -0
- package/dist/commons/events/locationPayloads.d.ts +95 -0
- package/dist/commons/events/locations.d.ts +7 -0
- package/dist/conditionals/index.js +303 -55
- package/dist/events/index.js +3393 -3219
- package/dist/notification/index.js +1672 -995
- package/dist/scopes/index.d.ts +226 -1
- package/dist/scopes/index.js +304 -55
- package/opencrvs-toolkit-2.1.0-rc.954dd73.tgz +0 -0
- package/package.json +3 -2
- package/tsconfig.tsbuildinfo +1 -1
- package/opencrvs-toolkit-2.1.0-rc.93572dd.tgz +0 -0
|
@@ -8242,6 +8242,37 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
8242
8242
|
responseSummary: {
|
|
8243
8243
|
clientId: string;
|
|
8244
8244
|
};
|
|
8245
|
+
} | {
|
|
8246
|
+
id: string;
|
|
8247
|
+
clientId: string;
|
|
8248
|
+
clientType: "system" | "user";
|
|
8249
|
+
createdAt: string;
|
|
8250
|
+
operation: "locations.create";
|
|
8251
|
+
requestData: {
|
|
8252
|
+
id: string;
|
|
8253
|
+
versionId: string;
|
|
8254
|
+
name: string;
|
|
8255
|
+
externalId?: string | null | undefined;
|
|
8256
|
+
effectiveFrom: string;
|
|
8257
|
+
status: string;
|
|
8258
|
+
administrativeAreaId?: string | null | undefined;
|
|
8259
|
+
locationType?: string | null | undefined;
|
|
8260
|
+
};
|
|
8261
|
+
} | {
|
|
8262
|
+
id: string;
|
|
8263
|
+
clientId: string;
|
|
8264
|
+
clientType: "system" | "user";
|
|
8265
|
+
createdAt: string;
|
|
8266
|
+
operation: "administrativeAreas.create";
|
|
8267
|
+
requestData: {
|
|
8268
|
+
id: string;
|
|
8269
|
+
versionId: string;
|
|
8270
|
+
name: string;
|
|
8271
|
+
externalId?: string | null | undefined;
|
|
8272
|
+
effectiveFrom: string;
|
|
8273
|
+
status: string;
|
|
8274
|
+
parentId?: string | null | undefined;
|
|
8275
|
+
};
|
|
8245
8276
|
} | {
|
|
8246
8277
|
id: string;
|
|
8247
8278
|
clientId: string;
|
|
@@ -8374,6 +8405,34 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
8374
8405
|
output: void;
|
|
8375
8406
|
meta: object;
|
|
8376
8407
|
}>;
|
|
8408
|
+
create: import("@trpc/server").TRPCMutationProcedure<{
|
|
8409
|
+
input: {
|
|
8410
|
+
id?: string | undefined;
|
|
8411
|
+
versionId?: string | undefined;
|
|
8412
|
+
name: string;
|
|
8413
|
+
externalId?: string | null | undefined;
|
|
8414
|
+
administrativeAreaId: string | null;
|
|
8415
|
+
locationType: string | null;
|
|
8416
|
+
effectiveFrom?: string | undefined;
|
|
8417
|
+
status?: "active" | "inactive" | undefined;
|
|
8418
|
+
};
|
|
8419
|
+
output: {
|
|
8420
|
+
id: string & import("zod").$brand<"UUID">;
|
|
8421
|
+
name: string;
|
|
8422
|
+
externalId?: string | null | undefined;
|
|
8423
|
+
administrativeAreaId: (string & import("zod").$brand<"UUID">) | null;
|
|
8424
|
+
locationType: string | null;
|
|
8425
|
+
status: "active" | "inactive";
|
|
8426
|
+
versions: {
|
|
8427
|
+
versionId: string & import("zod").$brand<"UUID">;
|
|
8428
|
+
effectiveFrom: string;
|
|
8429
|
+
name: string;
|
|
8430
|
+
externalId?: string | null | undefined;
|
|
8431
|
+
status: "active" | "inactive";
|
|
8432
|
+
}[];
|
|
8433
|
+
};
|
|
8434
|
+
meta: import("trpc-to-openapi").OpenApiMeta;
|
|
8435
|
+
}>;
|
|
8377
8436
|
get: import("@trpc/server").TRPCQueryProcedure<{
|
|
8378
8437
|
input: {
|
|
8379
8438
|
id: string;
|
|
@@ -8748,7 +8807,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
8748
8807
|
$event: "assignedTo" | "createdAt" | "createdAtLocation" | "createdBy" | "createdByUserType" | "dateOfEvent" | "flags" | "id" | "legalStatuses" | "outbox" | "placeOfEvent" | "status" | "title" | "trackingId" | "type" | "updatedAt" | "updatedAtLocation" | "updatedBy" | "updatedByUserRole";
|
|
8749
8808
|
};
|
|
8750
8809
|
}[];
|
|
8751
|
-
icon: "Activity" | "Archive" | "ArchiveBox" | "ArchiveTray" | "Archived" | "ArrowCircleDown" | "ArrowCounterClockwise" | "ArrowLeft" | "ArrowRight" | "Assigned" | "Briefcase" | "Buildings" | "CaretDown" | "CaretLeft" | "CaretRight" | "Certified" | "ChartActivity" | "ChartBar" | "ChartLine" | "ChatCircle" | "ChatText" | "Check" | "CheckSquare" | "Circle" | "CircleWavyCheck" | "CircleWavyQuestion" | "Clock" | "Close" | "Collapse" | "Compass" | "Copy" | "Database" | "DeviceTabletCamera" | "DotsThreeVertical" | "Draft" | "DuplicateYellow" | "Envelope" | "Expand" | "Export" | "ExternalValidate" | "Eye" | "EyeSlash" | "File" | "FileArrowUp" | "FileDotted" | "FileMinus" | "FilePlus" | "FileSearch" | "FileText" | "FileX" | "Files" | "FilledCheck" | "Fingerprint" | "Gear" | "GitBranch" | "Globe" | "Handshake" | "IdentificationCard" | "InReview" | "List" | "ListBullets" | "Lock" | "MagnifyingGlass" | "MagnifyingGlassMinus" | "MagnifyingGlassPlus" | "MapPin" | "Medal" | "NotePencil" | "Offline" | "PaperPlaneTilt" | "Paperclip" | "Pen" | "PenNib" | "Pencil" | "PencilCircle" | "PencilLine" | "PencilSimpleLine" | "Phone" | "Plus" | "Printer" | "PushPin" | "QrCode" | "Registered" | "RequiresUpdates" | "Sent" | "SignOut" | "Stamp" | "Star" | "Sun" | "Target" | "TextT" | "Timer" | "Trash" | "UploadSimple" | "User" | "UserCircle" | "UserPlus" | "Users" | "Validated" | "WaitingApproval" | "WarningCircle" | "Webcam" | "X";
|
|
8810
|
+
icon: "Activity" | "Archive" | "ArchiveBox" | "ArchiveTray" | "Archived" | "ArrowCircleDown" | "ArrowCounterClockwise" | "ArrowLeft" | "ArrowRight" | "Assigned" | "Briefcase" | "Buildings" | "CaretDown" | "CaretLeft" | "CaretRight" | "Certified" | "ChartActivity" | "ChartBar" | "ChartLine" | "ChatCircle" | "ChatText" | "Check" | "CheckSquare" | "Circle" | "CircleWavyCheck" | "CircleWavyQuestion" | "Clock" | "Close" | "Collapse" | "Compass" | "Copy" | "Database" | "DeviceTabletCamera" | "DotsThreeVertical" | "Draft" | "DuplicateYellow" | "Envelope" | "Expand" | "Export" | "ExternalValidate" | "Eye" | "EyeSlash" | "File" | "FileArrowUp" | "FileDotted" | "FileLock" | "FileMinus" | "FilePlus" | "FileSearch" | "FileText" | "FileX" | "Files" | "FilledCheck" | "Fingerprint" | "Gear" | "GitBranch" | "Globe" | "Handshake" | "IdentificationCard" | "InReview" | "List" | "ListBullets" | "Lock" | "MagnifyingGlass" | "MagnifyingGlassMinus" | "MagnifyingGlassPlus" | "MapPin" | "Medal" | "NotePencil" | "Offline" | "PaperPlaneTilt" | "Paperclip" | "Pen" | "PenNib" | "Pencil" | "PencilCircle" | "PencilLine" | "PencilSimpleLine" | "Phone" | "Plus" | "Printer" | "PushPin" | "QrCode" | "Registered" | "RequiresUpdates" | "Sent" | "SignOut" | "Stamp" | "Star" | "Sun" | "Target" | "TextT" | "Timer" | "Trash" | "UploadSimple" | "User" | "UserCircle" | "UserPlus" | "Users" | "Validated" | "WaitingApproval" | "WarningCircle" | "Webcam" | "X";
|
|
8752
8811
|
emptyMessage?: {
|
|
8753
8812
|
id: string;
|
|
8754
8813
|
defaultMessage: string;
|
|
@@ -8820,6 +8879,32 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
8820
8879
|
output: void;
|
|
8821
8880
|
meta: object;
|
|
8822
8881
|
}>;
|
|
8882
|
+
create: import("@trpc/server").TRPCMutationProcedure<{
|
|
8883
|
+
input: {
|
|
8884
|
+
id?: string | undefined;
|
|
8885
|
+
versionId?: string | undefined;
|
|
8886
|
+
name: string;
|
|
8887
|
+
externalId?: string | null | undefined;
|
|
8888
|
+
parentId: string | null;
|
|
8889
|
+
effectiveFrom?: string | undefined;
|
|
8890
|
+
status?: "active" | "inactive" | undefined;
|
|
8891
|
+
};
|
|
8892
|
+
output: {
|
|
8893
|
+
id: string & import("zod").$brand<"UUID">;
|
|
8894
|
+
name: string;
|
|
8895
|
+
externalId?: string | null | undefined;
|
|
8896
|
+
parentId: (string & import("zod").$brand<"UUID">) | null;
|
|
8897
|
+
status: "active" | "inactive";
|
|
8898
|
+
versions: {
|
|
8899
|
+
versionId: string & import("zod").$brand<"UUID">;
|
|
8900
|
+
effectiveFrom: string;
|
|
8901
|
+
name: string;
|
|
8902
|
+
externalId?: string | null | undefined;
|
|
8903
|
+
status: "active" | "inactive";
|
|
8904
|
+
}[];
|
|
8905
|
+
};
|
|
8906
|
+
meta: import("trpc-to-openapi").OpenApiMeta;
|
|
8907
|
+
}>;
|
|
8823
8908
|
}>>;
|
|
8824
8909
|
integrations: import("@trpc/server").TRPCBuiltRouter<{
|
|
8825
8910
|
ctx: Partial<{
|
|
@@ -85,17 +85,17 @@ export declare const now: typeof todayDateTimeValueSerializer;
|
|
|
85
85
|
export declare const user: typeof userSerializer & {
|
|
86
86
|
scope: (scope: import("../scopes").ScopeType) => {
|
|
87
87
|
attribute: (option: import("../scopes").ScopeOptionKey) => {
|
|
88
|
-
$scope: "attachment.upload" | "bypassratelimit" | "config.update-all" | "dashboard.view" | "integration.create" | "organisation.read-locations" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "profile.electronic-signature" | "record.archive" | "record.confirm-registration" | "record.correct" | "record.create" | "record.custom-action" | "record.declare" | "record.edit" | "record.import" | "record.notify" | "record.print-certified-copies" | "record.read" | "record.register" | "record.reindex" | "record.reject" | "record.reject-registration" | "record.request-correction" | "record.review-duplicates" | "record.search" | "record.unarchive" | "record.unassign-others" | "user.create" | "user.data-seeding" | "user.edit" | "user.read" | "user.read-only-my-audit" | "user.search" | "workqueue";
|
|
89
|
-
$option: "accessLevel" | "declaredBy" | "declaredIn" | "event" | "ids" | "notifiedBy" | "notifiedIn" | "placeOfEvent" | "registeredBy" | "registeredIn" | "role";
|
|
88
|
+
$scope: "attachment.upload" | "bypassratelimit" | "config.update-all" | "dashboard.view" | "integration.create" | "location.edit" | "organisation.read-locations" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "profile.electronic-signature" | "record.archive" | "record.confirm-registration" | "record.correct" | "record.create" | "record.custom-action" | "record.declare" | "record.edit" | "record.import" | "record.notify" | "record.print-certified-copies" | "record.read" | "record.register" | "record.reindex" | "record.reject" | "record.reject-registration" | "record.request-correction" | "record.review-duplicates" | "record.search" | "record.unarchive" | "record.unassign-others" | "user.create" | "user.data-seeding" | "user.edit" | "user.read" | "user.read-only-my-audit" | "user.search" | "workqueue";
|
|
89
|
+
$option: "accessLevel" | "declaredBy" | "declaredIn" | "event" | "flags" | "ids" | "notifiedBy" | "notifiedIn" | "placeOfEvent" | "registeredBy" | "registeredIn" | "role";
|
|
90
90
|
};
|
|
91
91
|
};
|
|
92
92
|
jurisdiction: (jurisdiction: import("../scopes").JurisdictionFilter | {
|
|
93
|
-
$scope: "attachment.upload" | "bypassratelimit" | "config.update-all" | "dashboard.view" | "integration.create" | "organisation.read-locations" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "profile.electronic-signature" | "record.archive" | "record.confirm-registration" | "record.correct" | "record.create" | "record.custom-action" | "record.declare" | "record.edit" | "record.import" | "record.notify" | "record.print-certified-copies" | "record.read" | "record.register" | "record.reindex" | "record.reject" | "record.reject-registration" | "record.request-correction" | "record.review-duplicates" | "record.search" | "record.unarchive" | "record.unassign-others" | "user.create" | "user.data-seeding" | "user.edit" | "user.read" | "user.read-only-my-audit" | "user.search" | "workqueue";
|
|
94
|
-
$option: "accessLevel" | "declaredBy" | "declaredIn" | "event" | "ids" | "notifiedBy" | "notifiedIn" | "placeOfEvent" | "registeredBy" | "registeredIn" | "role";
|
|
93
|
+
$scope: "attachment.upload" | "bypassratelimit" | "config.update-all" | "dashboard.view" | "integration.create" | "location.edit" | "organisation.read-locations" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "profile.electronic-signature" | "record.archive" | "record.confirm-registration" | "record.correct" | "record.create" | "record.custom-action" | "record.declare" | "record.edit" | "record.import" | "record.notify" | "record.print-certified-copies" | "record.read" | "record.register" | "record.reindex" | "record.reject" | "record.reject-registration" | "record.request-correction" | "record.review-duplicates" | "record.search" | "record.unarchive" | "record.unassign-others" | "user.create" | "user.data-seeding" | "user.edit" | "user.read" | "user.read-only-my-audit" | "user.search" | "workqueue";
|
|
94
|
+
$option: "accessLevel" | "declaredBy" | "declaredIn" | "event" | "flags" | "ids" | "notifiedBy" | "notifiedIn" | "placeOfEvent" | "registeredBy" | "registeredIn" | "role";
|
|
95
95
|
}) => {
|
|
96
96
|
$jurisdiction: "administrativeArea" | "all" | "location" | {
|
|
97
|
-
$scope: "attachment.upload" | "bypassratelimit" | "config.update-all" | "dashboard.view" | "integration.create" | "organisation.read-locations" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "profile.electronic-signature" | "record.archive" | "record.confirm-registration" | "record.correct" | "record.create" | "record.custom-action" | "record.declare" | "record.edit" | "record.import" | "record.notify" | "record.print-certified-copies" | "record.read" | "record.register" | "record.reindex" | "record.reject" | "record.reject-registration" | "record.request-correction" | "record.review-duplicates" | "record.search" | "record.unarchive" | "record.unassign-others" | "user.create" | "user.data-seeding" | "user.edit" | "user.read" | "user.read-only-my-audit" | "user.search" | "workqueue";
|
|
98
|
-
$option: "accessLevel" | "declaredBy" | "declaredIn" | "event" | "ids" | "notifiedBy" | "notifiedIn" | "placeOfEvent" | "registeredBy" | "registeredIn" | "role";
|
|
97
|
+
$scope: "attachment.upload" | "bypassratelimit" | "config.update-all" | "dashboard.view" | "integration.create" | "location.edit" | "organisation.read-locations" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "profile.electronic-signature" | "record.archive" | "record.confirm-registration" | "record.correct" | "record.create" | "record.custom-action" | "record.declare" | "record.edit" | "record.import" | "record.notify" | "record.print-certified-copies" | "record.read" | "record.register" | "record.reindex" | "record.reject" | "record.reject-registration" | "record.request-correction" | "record.review-duplicates" | "record.search" | "record.unarchive" | "record.unassign-others" | "user.create" | "user.data-seeding" | "user.edit" | "user.read" | "user.read-only-my-audit" | "user.search" | "workqueue";
|
|
98
|
+
$option: "accessLevel" | "declaredBy" | "declaredIn" | "event" | "flags" | "ids" | "notifiedBy" | "notifiedIn" | "placeOfEvent" | "registeredBy" | "registeredIn" | "role";
|
|
99
99
|
};
|
|
100
100
|
};
|
|
101
101
|
hasScope: (scope: string) => JSONSchema;
|
|
@@ -14,6 +14,7 @@ import { EventDocument } from '../events/EventDocument';
|
|
|
14
14
|
import { EventIndex } from '../events/EventIndex';
|
|
15
15
|
import { Location } from '../events/locations';
|
|
16
16
|
import { SystemVariables } from '../events/TemplateConfig';
|
|
17
|
+
import { AvailableIcons } from '../icons';
|
|
17
18
|
/** Returns today's date as an ISO date string (YYYY-MM-DD). */
|
|
18
19
|
export declare function todayISO(): string;
|
|
19
20
|
/**
|
|
@@ -69,13 +70,27 @@ export declare function validate(schema: JSONSchema, data: ConditionalParameters
|
|
|
69
70
|
export declare function validateValue(schema: JSONSchema, data: unknown): boolean;
|
|
70
71
|
export declare function isOnline(): boolean;
|
|
71
72
|
export declare function isConditionMet(conditional: JSONSchema, values: EventState | ActionUpdate, context: ValidatorContext): boolean;
|
|
72
|
-
export declare function areConditionsMet(conditions: FieldConditional[], values: Record<string, FieldValue>, context: ValidatorContext,
|
|
73
|
+
export declare function areConditionsMet(conditions: FieldConditional[], values: Record<string, FieldValue>, context: ValidatorContext, event: EventIndex): boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Given an EventConfig's `icon` map (icon name -> conditional) and a real
|
|
76
|
+
* event, returns the name of the first icon (in definition order) whose
|
|
77
|
+
* conditional matches, or `undefined` if there's no icon config or nothing
|
|
78
|
+
* matches — callers should fall back to a default icon in that case.
|
|
79
|
+
*/
|
|
80
|
+
export declare function resolveEventIcon(iconConfig: EventConfig['icon'], event: EventIndex, context: ValidatorContext): AvailableIcons | undefined;
|
|
81
|
+
/**
|
|
82
|
+
* Given a field's `secured` property (a boolean, or a JSONSchema conditional
|
|
83
|
+
* evaluated against the event, e.g. `flag('sealed')`), returns whether the
|
|
84
|
+
* field is currently secured for the given event.
|
|
85
|
+
*/
|
|
86
|
+
export declare function isFieldSecured(field: Pick<FieldConfig, 'secured'>, event: EventIndex, context?: ValidatorContext): boolean;
|
|
73
87
|
export type ValidatorContext = {
|
|
74
88
|
user?: ITokenPayload;
|
|
75
89
|
leafAdminStructureLocationIds?: Array<{
|
|
76
90
|
id: UUID;
|
|
77
91
|
}>;
|
|
78
92
|
event?: EventDocument;
|
|
93
|
+
eventConfig?: EventConfig;
|
|
79
94
|
baseFormState?: EventState;
|
|
80
95
|
};
|
|
81
96
|
export declare function isFieldVisible(field: FieldConfig, form: Partial<ActionUpdate | EventState>, context: ValidatorContext): boolean;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as z from 'zod/v4';
|
|
2
2
|
import { FieldValue, FieldUpdateValue } from './FieldValue';
|
|
3
|
+
export { ActionStatus } from './ActionStatus';
|
|
3
4
|
/**
|
|
4
5
|
* ActionUpdate is a record of a specific action that updated data fields.
|
|
5
6
|
*/
|
|
@@ -10,12 +11,6 @@ export type ActionUpdate = z.infer<typeof ActionUpdate>;
|
|
|
10
11
|
*/
|
|
11
12
|
export declare const EventState: z.ZodRecord<z.ZodString, z.ZodType<FieldValue, unknown, z.core.$ZodTypeInternals<FieldValue, unknown>>>;
|
|
12
13
|
export type EventState = z.infer<typeof EventState>;
|
|
13
|
-
export declare const ActionStatus: {
|
|
14
|
-
readonly Requested: 'Requested';
|
|
15
|
-
readonly Accepted: 'Accepted';
|
|
16
|
-
readonly Rejected: 'Rejected';
|
|
17
|
-
};
|
|
18
|
-
export type ActionStatus = keyof typeof ActionStatus;
|
|
19
14
|
export declare const ActionBase: z.ZodObject<{
|
|
20
15
|
id: z.core.$ZodBranded<z.ZodUUID, "UUID", "out">;
|
|
21
16
|
transactionId: z.ZodString;
|
|
@@ -1173,5 +1168,4 @@ export declare const Action: z.ZodUnion<readonly [z.ZodDiscriminatedUnion<[z.Zod
|
|
|
1173
1168
|
export type Action = z.infer<typeof Action>;
|
|
1174
1169
|
export type CreatedAction = z.infer<typeof CreatedAction>;
|
|
1175
1170
|
export type AssignedAction = z.infer<typeof AssignedAction>;
|
|
1176
|
-
export {};
|
|
1177
1171
|
//# sourceMappingURL=ActionDocument.d.ts.map
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Deliberately dependency-free (aside from language builtins) so that files
|
|
3
|
+
* like Flag.ts can depend on ActionStatus without being pulled into the
|
|
4
|
+
* commons/scopes.ts <-> commons/authentication.ts import cycle that
|
|
5
|
+
* ActionDocument.ts participates in (it imports TokenUserType from
|
|
6
|
+
* '../authentication').
|
|
7
|
+
*/
|
|
8
|
+
export declare const ActionStatus: {
|
|
9
|
+
readonly Requested: 'Requested';
|
|
10
|
+
readonly Accepted: 'Accepted';
|
|
11
|
+
readonly Rejected: 'Rejected';
|
|
12
|
+
};
|
|
13
|
+
export type ActionStatus = keyof typeof ActionStatus;
|
|
14
|
+
//# sourceMappingURL=ActionStatus.d.ts.map
|
|
@@ -103,6 +103,7 @@ export declare const FieldConfigSchema: z.ZodObject<{
|
|
|
103
103
|
"config.update-all": "config.update-all";
|
|
104
104
|
"dashboard.view": "dashboard.view";
|
|
105
105
|
"integration.create": "integration.create";
|
|
106
|
+
"location.edit": "location.edit";
|
|
106
107
|
"organisation.read-locations": "organisation.read-locations";
|
|
107
108
|
"performance.read": "performance.read";
|
|
108
109
|
"performance.read-dashboards": "performance.read-dashboards";
|
|
@@ -141,6 +142,7 @@ export declare const FieldConfigSchema: z.ZodObject<{
|
|
|
141
142
|
declaredBy: "declaredBy";
|
|
142
143
|
declaredIn: "declaredIn";
|
|
143
144
|
event: "event";
|
|
145
|
+
flags: "flags";
|
|
144
146
|
ids: "ids";
|
|
145
147
|
notifiedBy: "notifiedBy";
|
|
146
148
|
notifiedIn: "notifiedIn";
|
|
@@ -283,6 +285,7 @@ export declare const EventFieldConfigSchema: z.ZodObject<{
|
|
|
283
285
|
"config.update-all": "config.update-all";
|
|
284
286
|
"dashboard.view": "dashboard.view";
|
|
285
287
|
"integration.create": "integration.create";
|
|
288
|
+
"location.edit": "location.edit";
|
|
286
289
|
"organisation.read-locations": "organisation.read-locations";
|
|
287
290
|
"performance.read": "performance.read";
|
|
288
291
|
"performance.read-dashboards": "performance.read-dashboards";
|
|
@@ -321,6 +324,7 @@ export declare const EventFieldConfigSchema: z.ZodObject<{
|
|
|
321
324
|
declaredBy: "declaredBy";
|
|
322
325
|
declaredIn: "declaredIn";
|
|
323
326
|
event: "event";
|
|
327
|
+
flags: "flags";
|
|
324
328
|
ids: "ids";
|
|
325
329
|
notifiedBy: "notifiedBy";
|
|
326
330
|
notifiedIn: "notifiedIn";
|
|
@@ -439,6 +443,7 @@ export declare const AdvancedSearchField: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
439
443
|
"config.update-all": "config.update-all";
|
|
440
444
|
"dashboard.view": "dashboard.view";
|
|
441
445
|
"integration.create": "integration.create";
|
|
446
|
+
"location.edit": "location.edit";
|
|
442
447
|
"organisation.read-locations": "organisation.read-locations";
|
|
443
448
|
"performance.read": "performance.read";
|
|
444
449
|
"performance.read-dashboards": "performance.read-dashboards";
|
|
@@ -477,6 +482,7 @@ export declare const AdvancedSearchField: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
477
482
|
declaredBy: "declaredBy";
|
|
478
483
|
declaredIn: "declaredIn";
|
|
479
484
|
event: "event";
|
|
485
|
+
flags: "flags";
|
|
480
486
|
ids: "ids";
|
|
481
487
|
notifiedBy: "notifiedBy";
|
|
482
488
|
notifiedIn: "notifiedIn";
|
|
@@ -587,6 +593,7 @@ export declare const AdvancedSearchField: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
587
593
|
"config.update-all": "config.update-all";
|
|
588
594
|
"dashboard.view": "dashboard.view";
|
|
589
595
|
"integration.create": "integration.create";
|
|
596
|
+
"location.edit": "location.edit";
|
|
590
597
|
"organisation.read-locations": "organisation.read-locations";
|
|
591
598
|
"performance.read": "performance.read";
|
|
592
599
|
"performance.read-dashboards": "performance.read-dashboards";
|
|
@@ -625,6 +632,7 @@ export declare const AdvancedSearchField: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
625
632
|
declaredBy: "declaredBy";
|
|
626
633
|
declaredIn: "declaredIn";
|
|
627
634
|
event: "event";
|
|
635
|
+
flags: "flags";
|
|
628
636
|
ids: "ids";
|
|
629
637
|
notifiedBy: "notifiedBy";
|
|
630
638
|
notifiedIn: "notifiedIn";
|
|
@@ -746,6 +754,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
|
|
|
746
754
|
"config.update-all": "config.update-all";
|
|
747
755
|
"dashboard.view": "dashboard.view";
|
|
748
756
|
"integration.create": "integration.create";
|
|
757
|
+
"location.edit": "location.edit";
|
|
749
758
|
"organisation.read-locations": "organisation.read-locations";
|
|
750
759
|
"performance.read": "performance.read";
|
|
751
760
|
"performance.read-dashboards": "performance.read-dashboards";
|
|
@@ -784,6 +793,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
|
|
|
784
793
|
declaredBy: "declaredBy";
|
|
785
794
|
declaredIn: "declaredIn";
|
|
786
795
|
event: "event";
|
|
796
|
+
flags: "flags";
|
|
787
797
|
ids: "ids";
|
|
788
798
|
notifiedBy: "notifiedBy";
|
|
789
799
|
notifiedIn: "notifiedIn";
|
|
@@ -894,6 +904,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
|
|
|
894
904
|
"config.update-all": "config.update-all";
|
|
895
905
|
"dashboard.view": "dashboard.view";
|
|
896
906
|
"integration.create": "integration.create";
|
|
907
|
+
"location.edit": "location.edit";
|
|
897
908
|
"organisation.read-locations": "organisation.read-locations";
|
|
898
909
|
"performance.read": "performance.read";
|
|
899
910
|
"performance.read-dashboards": "performance.read-dashboards";
|
|
@@ -932,6 +943,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
|
|
|
932
943
|
declaredBy: "declaredBy";
|
|
933
944
|
declaredIn: "declaredIn";
|
|
934
945
|
event: "event";
|
|
946
|
+
flags: "flags";
|
|
935
947
|
ids: "ids";
|
|
936
948
|
notifiedBy: "notifiedBy";
|
|
937
949
|
notifiedIn: "notifiedIn";
|
|
@@ -281,6 +281,43 @@ export declare const AuditLogEntrySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
281
281
|
responseSummary: z.ZodObject<{
|
|
282
282
|
clientId: z.ZodString;
|
|
283
283
|
}, z.core.$strip>;
|
|
284
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
285
|
+
id: z.ZodString;
|
|
286
|
+
clientId: z.ZodString;
|
|
287
|
+
clientType: z.ZodEnum<{
|
|
288
|
+
system: "system";
|
|
289
|
+
user: "user";
|
|
290
|
+
}>;
|
|
291
|
+
createdAt: z.ZodString;
|
|
292
|
+
operation: z.ZodLiteral<"locations.create">;
|
|
293
|
+
requestData: z.ZodObject<{
|
|
294
|
+
id: z.ZodString;
|
|
295
|
+
versionId: z.ZodString;
|
|
296
|
+
name: z.ZodString;
|
|
297
|
+
externalId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
298
|
+
effectiveFrom: z.ZodString;
|
|
299
|
+
status: z.ZodString;
|
|
300
|
+
administrativeAreaId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
301
|
+
locationType: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
302
|
+
}, z.core.$strip>;
|
|
303
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
304
|
+
id: z.ZodString;
|
|
305
|
+
clientId: z.ZodString;
|
|
306
|
+
clientType: z.ZodEnum<{
|
|
307
|
+
system: "system";
|
|
308
|
+
user: "user";
|
|
309
|
+
}>;
|
|
310
|
+
createdAt: z.ZodString;
|
|
311
|
+
operation: z.ZodLiteral<"administrativeAreas.create">;
|
|
312
|
+
requestData: z.ZodObject<{
|
|
313
|
+
id: z.ZodString;
|
|
314
|
+
versionId: z.ZodString;
|
|
315
|
+
name: z.ZodString;
|
|
316
|
+
externalId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
317
|
+
effectiveFrom: z.ZodString;
|
|
318
|
+
status: z.ZodString;
|
|
319
|
+
parentId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
320
|
+
}, z.core.$strip>;
|
|
284
321
|
}, z.core.$strip>, z.ZodObject<{
|
|
285
322
|
id: z.ZodString;
|
|
286
323
|
clientId: z.ZodString;
|
|
@@ -6,6 +6,8 @@ import { AdvancedSearchConfig } from './AdvancedSearchConfig';
|
|
|
6
6
|
import { DeclarationFormConfig, DeclarationFormConfigInput } from './FormConfig';
|
|
7
7
|
import { FieldReference } from './FieldConfig';
|
|
8
8
|
import { FlagConfig } from './Flag';
|
|
9
|
+
import type { JSONSchema } from '../conditionals/conditionals';
|
|
10
|
+
import { AvailableIcons } from '../icons';
|
|
9
11
|
export declare const EventFieldReference: z.ZodObject<{
|
|
10
12
|
$$event: z.ZodEnum<{
|
|
11
13
|
createdAt: "createdAt";
|
|
@@ -32,6 +34,7 @@ export type EventConfig = {
|
|
|
32
34
|
advancedSearch: AdvancedSearchConfig[];
|
|
33
35
|
flags: FlagConfig[];
|
|
34
36
|
analytics: boolean;
|
|
37
|
+
icon?: Partial<Record<AvailableIcons, JSONSchema>>;
|
|
35
38
|
};
|
|
36
39
|
export type EventConfigInput = Omit<EventConfig, 'advancedSearch' | 'flags' | 'declaration' | 'actions' | 'dateOfEvent' | 'placeOfEvent' | 'analytics'> & {
|
|
37
40
|
dateOfEvent?: z.input<typeof FieldReference> | z.infer<typeof EventFieldReference>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z, ZodType } from 'zod/v4';
|
|
2
|
+
export { ContainsFlags } from './Flag';
|
|
2
3
|
export declare const EventIndex: z.ZodObject<{
|
|
3
4
|
id: z.core.$ZodBranded<z.ZodUUID, "UUID", "out">;
|
|
4
5
|
type: z.ZodString;
|
|
@@ -123,29 +124,6 @@ export declare const Range: z.ZodObject<{
|
|
|
123
124
|
gte: z.ZodString;
|
|
124
125
|
lte: z.ZodString;
|
|
125
126
|
}, z.core.$strip>;
|
|
126
|
-
export declare const ContainsFlags: z.ZodObject<{
|
|
127
|
-
anyOf: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodEnum<{
|
|
128
|
-
readonly INCOMPLETE: 'incomplete';
|
|
129
|
-
readonly REJECTED: 'rejected';
|
|
130
|
-
readonly CORRECTION_REQUESTED: 'correction-requested';
|
|
131
|
-
readonly POTENTIAL_DUPLICATE: 'potential-duplicate';
|
|
132
|
-
readonly EDIT_IN_PROGRESS: 'edit-in-progress';
|
|
133
|
-
}>]>, z.ZodString]>>>;
|
|
134
|
-
noneOf: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodEnum<{
|
|
135
|
-
readonly INCOMPLETE: 'incomplete';
|
|
136
|
-
readonly REJECTED: 'rejected';
|
|
137
|
-
readonly CORRECTION_REQUESTED: 'correction-requested';
|
|
138
|
-
readonly POTENTIAL_DUPLICATE: 'potential-duplicate';
|
|
139
|
-
readonly EDIT_IN_PROGRESS: 'edit-in-progress';
|
|
140
|
-
}>]>, z.ZodString]>>>;
|
|
141
|
-
allOf: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodEnum<{
|
|
142
|
-
readonly INCOMPLETE: 'incomplete';
|
|
143
|
-
readonly REJECTED: 'rejected';
|
|
144
|
-
readonly CORRECTION_REQUESTED: 'correction-requested';
|
|
145
|
-
readonly POTENTIAL_DUPLICATE: 'potential-duplicate';
|
|
146
|
-
readonly EDIT_IN_PROGRESS: 'edit-in-progress';
|
|
147
|
-
}>]>, z.ZodString]>>>;
|
|
148
|
-
}, z.core.$strip>;
|
|
149
127
|
export declare const Within: z.ZodObject<{
|
|
150
128
|
type: z.ZodLiteral<"within">;
|
|
151
129
|
location: z.ZodString;
|
|
@@ -354,5 +332,4 @@ export declare const SearchQuery: z.ZodObject<{
|
|
|
354
332
|
export type SearchQuery = z.infer<typeof SearchQuery>;
|
|
355
333
|
export type QueryType = z.infer<typeof QueryType>;
|
|
356
334
|
export type QueryExpression = z.infer<typeof QueryExpression>;
|
|
357
|
-
export {};
|
|
358
335
|
//# sourceMappingURL=EventIndex.d.ts.map
|