@opencrvs/toolkit 1.9.22 → 1.9.23-rc.12be0ca
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/events/index.js
CHANGED
|
@@ -5621,8 +5621,8 @@ function getActionRequests(actionType, actions) {
|
|
|
5621
5621
|
(action) => action.status === ActionStatus.Accepted
|
|
5622
5622
|
);
|
|
5623
5623
|
const request = filtered.find(
|
|
5624
|
-
(action) => action.status === ActionStatus.Requested
|
|
5625
|
-
);
|
|
5624
|
+
(action) => action.status === ActionStatus.Requested && action.id === accept?.originalActionId
|
|
5625
|
+
) ?? filtered.find((action) => action.status === ActionStatus.Requested);
|
|
5626
5626
|
const reject = filtered.find(
|
|
5627
5627
|
(action) => action.status === ActionStatus.Rejected
|
|
5628
5628
|
);
|
|
@@ -9470,6 +9470,8 @@ var AVAILABLE_ACTIONS_BY_EVENT_STATUS = {
|
|
|
9470
9470
|
]
|
|
9471
9471
|
};
|
|
9472
9472
|
var ACTION_FILTERS = {
|
|
9473
|
+
[ActionType.NOTIFY]: (flags) => !flags.some((flag) => flag.endsWith(":requested")),
|
|
9474
|
+
[ActionType.DECLARE]: (flags) => !flags.some((flag) => flag.endsWith(":requested")),
|
|
9473
9475
|
[ActionType.PRINT_CERTIFICATE]: (flags) => !flags.includes(InherentFlags.CORRECTION_REQUESTED) && !flags.some((flag) => flag.endsWith(":requested")),
|
|
9474
9476
|
[ActionType.REQUEST_CORRECTION]: (flags) => !flags.includes(InherentFlags.CORRECTION_REQUESTED) && !flags.some((flag) => flag.endsWith(":requested")),
|
|
9475
9477
|
[ClientSpecificAction.REVIEW_CORRECTION_REQUEST]: (flags) => flags.includes(InherentFlags.CORRECTION_REQUESTED) && !flags.some((flag) => flag.endsWith(":requested")),
|
|
@@ -6712,6 +6712,8 @@ var AVAILABLE_ACTIONS_BY_EVENT_STATUS = {
|
|
|
6712
6712
|
]
|
|
6713
6713
|
};
|
|
6714
6714
|
var ACTION_FILTERS = {
|
|
6715
|
+
[ActionType.NOTIFY]: (flags) => !flags.some((flag) => flag.endsWith(":requested")),
|
|
6716
|
+
[ActionType.DECLARE]: (flags) => !flags.some((flag) => flag.endsWith(":requested")),
|
|
6715
6717
|
[ActionType.PRINT_CERTIFICATE]: (flags) => !flags.includes(InherentFlags.CORRECTION_REQUESTED) && !flags.some((flag) => flag.endsWith(":requested")),
|
|
6716
6718
|
[ActionType.REQUEST_CORRECTION]: (flags) => !flags.includes(InherentFlags.CORRECTION_REQUESTED) && !flags.some((flag) => flag.endsWith(":requested")),
|
|
6717
6719
|
[ClientSpecificAction.REVIEW_CORRECTION_REQUEST]: (flags) => flags.includes(InherentFlags.CORRECTION_REQUESTED) && !flags.some((flag) => flag.endsWith(":requested")),
|