@opencrvs/toolkit 1.9.6-rc.5746ef3 → 1.9.6-rc.58ef0a0
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.
|
@@ -31023,7 +31023,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
31023
31023
|
}[];
|
|
31024
31024
|
};
|
|
31025
31025
|
actions: {
|
|
31026
|
-
type: "DELETE" | "READ" | "DECLARE" | "REJECT" | "REGISTER" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "EDIT" | "ARCHIVE" | "MARK_AS_DUPLICATE" | "ASSIGN" | "UNASSIGN"
|
|
31026
|
+
type: "DELETE" | "READ" | "DECLARE" | "REJECT" | "REGISTER" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "EDIT" | "ARCHIVE" | "MARK_AS_DUPLICATE" | "ASSIGN" | "UNASSIGN";
|
|
31027
31027
|
}[];
|
|
31028
31028
|
columns: {
|
|
31029
31029
|
label: {
|
|
@@ -9,7 +9,8 @@ export declare const mandatoryColumns: {
|
|
|
9
9
|
$event: "type" | "id" | "status" | "title" | "createdByUserType" | "createdAt" | "createdBy" | "createdAtLocation" | "assignedTo" | "trackingId" | "placeOfEvent" | "legalStatuses" | "dateOfEvent" | "updatedByUserRole" | "updatedAtLocation" | "updatedAt" | "updatedBy" | "flags" | "outbox";
|
|
10
10
|
};
|
|
11
11
|
}[];
|
|
12
|
-
|
|
12
|
+
/** Workqueue Call-to-action -button action type */
|
|
13
|
+
export declare const CtaActionType: z.ZodEnum<{
|
|
13
14
|
DELETE: "DELETE";
|
|
14
15
|
DECLARE: "DECLARE";
|
|
15
16
|
REGISTER: "REGISTER";
|
|
@@ -22,9 +23,8 @@ export declare const WorkqueueActionsWithDefault: z.ZodEnum<{
|
|
|
22
23
|
READ: "READ";
|
|
23
24
|
ASSIGN: "ASSIGN";
|
|
24
25
|
UNASSIGN: "UNASSIGN";
|
|
25
|
-
DEFAULT: "DEFAULT";
|
|
26
26
|
}>;
|
|
27
|
-
export type
|
|
27
|
+
export type CtaActionType = z.infer<typeof CtaActionType>;
|
|
28
28
|
/**
|
|
29
29
|
* Configuration for workqueue. Workqueues are used to display a list of events.
|
|
30
30
|
*/
|
|
@@ -534,7 +534,6 @@ export declare const WorkqueueConfig: z.ZodObject<{
|
|
|
534
534
|
READ: "READ";
|
|
535
535
|
ASSIGN: "ASSIGN";
|
|
536
536
|
UNASSIGN: "UNASSIGN";
|
|
537
|
-
DEFAULT: "DEFAULT";
|
|
538
537
|
}>;
|
|
539
538
|
}, z.core.$strip>>;
|
|
540
539
|
columns: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
@@ -791,7 +790,6 @@ export declare const WorkqueueConfigWithoutQuery: z.ZodObject<{
|
|
|
791
790
|
READ: "READ";
|
|
792
791
|
ASSIGN: "ASSIGN";
|
|
793
792
|
UNASSIGN: "UNASSIGN";
|
|
794
|
-
DEFAULT: "DEFAULT";
|
|
795
793
|
}>;
|
|
796
794
|
}, z.core.$strip>>;
|
|
797
795
|
slug: z.ZodString;
|
|
@@ -1544,7 +1542,6 @@ export declare const WorkqueueConfigInput: z.ZodObject<{
|
|
|
1544
1542
|
READ: "READ";
|
|
1545
1543
|
ASSIGN: "ASSIGN";
|
|
1546
1544
|
UNASSIGN: "UNASSIGN";
|
|
1547
|
-
DEFAULT: "DEFAULT";
|
|
1548
1545
|
}>;
|
|
1549
1546
|
}, z.core.$strip>>;
|
|
1550
1547
|
columns: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
@@ -1914,7 +1911,7 @@ export declare function defineWorkqueue(workqueueInput: WorkqueueConfigInput): {
|
|
|
1914
1911
|
}[];
|
|
1915
1912
|
};
|
|
1916
1913
|
actions: {
|
|
1917
|
-
type: "DELETE" | "DECLARE" | "REGISTER" | "EDIT" | "REJECT" | "MARK_AS_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN"
|
|
1914
|
+
type: "DELETE" | "DECLARE" | "REGISTER" | "EDIT" | "REJECT" | "MARK_AS_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN";
|
|
1918
1915
|
}[];
|
|
1919
1916
|
columns: {
|
|
1920
1917
|
label: {
|
|
@@ -2164,7 +2161,7 @@ export declare function defineWorkqueues(workqueues: WorkqueueConfigInput[]): {
|
|
|
2164
2161
|
}[];
|
|
2165
2162
|
};
|
|
2166
2163
|
actions: {
|
|
2167
|
-
type: "DELETE" | "DECLARE" | "REGISTER" | "EDIT" | "REJECT" | "MARK_AS_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN"
|
|
2164
|
+
type: "DELETE" | "DECLARE" | "REGISTER" | "EDIT" | "REJECT" | "MARK_AS_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN";
|
|
2168
2165
|
}[];
|
|
2169
2166
|
columns: {
|
|
2170
2167
|
label: {
|
package/dist/events/index.js
CHANGED
|
@@ -75,6 +75,7 @@ __export(events_exports, {
|
|
|
75
75
|
ConditionalType: () => ConditionalType,
|
|
76
76
|
ConfirmableActions: () => ConfirmableActions,
|
|
77
77
|
ContainsFlags: () => ContainsFlags,
|
|
78
|
+
CtaActionType: () => CtaActionType,
|
|
78
79
|
CustomActionInput: () => CustomActionInput,
|
|
79
80
|
CustomFieldValue: () => CustomFieldValue,
|
|
80
81
|
CustomFlag: () => CustomFlag,
|
|
@@ -210,7 +211,6 @@ __export(events_exports, {
|
|
|
210
211
|
VerificationPageConfig: () => VerificationPageConfig,
|
|
211
212
|
VerificationStatusValue: () => VerificationStatusValue,
|
|
212
213
|
Within: () => Within,
|
|
213
|
-
WorkqueueActionsWithDefault: () => WorkqueueActionsWithDefault,
|
|
214
214
|
WorkqueueColumn: () => WorkqueueColumn,
|
|
215
215
|
WorkqueueColumnKeys: () => WorkqueueColumnKeys,
|
|
216
216
|
WorkqueueColumnKeysArray: () => WorkqueueColumnKeysArray,
|
|
@@ -4009,6 +4009,9 @@ var getActionAnnotationFields = (actionConfig) => {
|
|
|
4009
4009
|
if (actionConfig.type === ActionType.PRINT_CERTIFICATE) {
|
|
4010
4010
|
return actionConfig.printForm.pages.flatMap(({ fields }) => fields);
|
|
4011
4011
|
}
|
|
4012
|
+
if (actionConfig.type === ActionType.CUSTOM) {
|
|
4013
|
+
return actionConfig.form;
|
|
4014
|
+
}
|
|
4012
4015
|
if ("review" in actionConfig) {
|
|
4013
4016
|
return actionConfig.review.fields;
|
|
4014
4017
|
}
|
|
@@ -5342,9 +5345,8 @@ var mandatoryColumns = defineWorkqueuesColumns([
|
|
|
5342
5345
|
value: event.field("updatedAt")
|
|
5343
5346
|
}
|
|
5344
5347
|
]);
|
|
5345
|
-
var
|
|
5348
|
+
var CtaActionType = z33.enum([
|
|
5346
5349
|
...workqueueActions.options,
|
|
5347
|
-
"DEFAULT",
|
|
5348
5350
|
ActionType.READ
|
|
5349
5351
|
]);
|
|
5350
5352
|
var WorkqueueConfig = z33.object({
|
|
@@ -5355,7 +5357,7 @@ var WorkqueueConfig = z33.object({
|
|
|
5355
5357
|
query: CountryConfigQueryType,
|
|
5356
5358
|
/** This action object used to contain a conditionals option, but it was not used anywhere.
|
|
5357
5359
|
* It's also debatable whether it should be an array, or just a single action. */
|
|
5358
|
-
actions: z33.array(z33.object({ type:
|
|
5360
|
+
actions: z33.array(z33.object({ type: CtaActionType })).describe("Workqueue call-to-action button configuration."),
|
|
5359
5361
|
columns: z33.array(WorkqueueColumn).default(mandatoryColumns),
|
|
5360
5362
|
icon: AvailableIcons,
|
|
5361
5363
|
emptyMessage: TranslationConfig.optional()
|
|
@@ -5370,7 +5372,7 @@ var WorkqueueConfigInput = z33.object({
|
|
|
5370
5372
|
"Title of the workflow (both in navigation and on the page)"
|
|
5371
5373
|
),
|
|
5372
5374
|
query: CountryConfigQueryInputType,
|
|
5373
|
-
actions: z33.array(z33.object({ type:
|
|
5375
|
+
actions: z33.array(z33.object({ type: CtaActionType })).describe("Workqueue call-to-action button configuration."),
|
|
5374
5376
|
columns: z33.array(WorkqueueColumn).default(mandatoryColumns),
|
|
5375
5377
|
icon: AvailableIcons,
|
|
5376
5378
|
emptyMessage: TranslationConfig.optional()
|
|
@@ -9160,7 +9162,7 @@ var generateWorkqueues = (slug = "all-events") => defineWorkqueues([
|
|
|
9160
9162
|
type: "and",
|
|
9161
9163
|
clauses: [{ eventType: tennisClubMembershipEvent.id }]
|
|
9162
9164
|
},
|
|
9163
|
-
actions: [{ type:
|
|
9165
|
+
actions: [{ type: ActionType.READ }],
|
|
9164
9166
|
icon: "Draft"
|
|
9165
9167
|
}
|
|
9166
9168
|
]);
|
|
@@ -2805,6 +2805,9 @@ var getActionAnnotationFields = (actionConfig) => {
|
|
|
2805
2805
|
if (actionConfig.type === ActionType.PRINT_CERTIFICATE) {
|
|
2806
2806
|
return actionConfig.printForm.pages.flatMap(({ fields }) => fields);
|
|
2807
2807
|
}
|
|
2808
|
+
if (actionConfig.type === ActionType.CUSTOM) {
|
|
2809
|
+
return actionConfig.form;
|
|
2810
|
+
}
|
|
2808
2811
|
if ("review" in actionConfig) {
|
|
2809
2812
|
return actionConfig.review.fields;
|
|
2810
2813
|
}
|
|
@@ -3816,9 +3819,8 @@ var mandatoryColumns = defineWorkqueuesColumns([
|
|
|
3816
3819
|
value: event.field("updatedAt")
|
|
3817
3820
|
}
|
|
3818
3821
|
]);
|
|
3819
|
-
var
|
|
3822
|
+
var CtaActionType = z33.enum([
|
|
3820
3823
|
...workqueueActions.options,
|
|
3821
|
-
"DEFAULT",
|
|
3822
3824
|
ActionType.READ
|
|
3823
3825
|
]);
|
|
3824
3826
|
var WorkqueueConfig = z33.object({
|
|
@@ -3829,7 +3831,7 @@ var WorkqueueConfig = z33.object({
|
|
|
3829
3831
|
query: CountryConfigQueryType,
|
|
3830
3832
|
/** This action object used to contain a conditionals option, but it was not used anywhere.
|
|
3831
3833
|
* It's also debatable whether it should be an array, or just a single action. */
|
|
3832
|
-
actions: z33.array(z33.object({ type:
|
|
3834
|
+
actions: z33.array(z33.object({ type: CtaActionType })).describe("Workqueue call-to-action button configuration."),
|
|
3833
3835
|
columns: z33.array(WorkqueueColumn).default(mandatoryColumns),
|
|
3834
3836
|
icon: AvailableIcons,
|
|
3835
3837
|
emptyMessage: TranslationConfig.optional()
|
|
@@ -3844,7 +3846,7 @@ var WorkqueueConfigInput = z33.object({
|
|
|
3844
3846
|
"Title of the workflow (both in navigation and on the page)"
|
|
3845
3847
|
),
|
|
3846
3848
|
query: CountryConfigQueryInputType,
|
|
3847
|
-
actions: z33.array(z33.object({ type:
|
|
3849
|
+
actions: z33.array(z33.object({ type: CtaActionType })).describe("Workqueue call-to-action button configuration."),
|
|
3848
3850
|
columns: z33.array(WorkqueueColumn).default(mandatoryColumns),
|
|
3849
3851
|
icon: AvailableIcons,
|
|
3850
3852
|
emptyMessage: TranslationConfig.optional()
|