@opencrvs/toolkit 1.9.2-rc.f5cc2a4 → 1.9.2-rc.f5e3efd
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 +4 -1
- package/package.json +1 -1
package/dist/events/index.js
CHANGED
|
@@ -8943,12 +8943,15 @@ function getAvailableActionsWithoutFlagFilters(status2, flags) {
|
|
|
8943
8943
|
return AVAILABLE_ACTIONS_BY_EVENT_STATUS[status2];
|
|
8944
8944
|
}
|
|
8945
8945
|
case EventStatus.enum.DECLARED: {
|
|
8946
|
-
if (flags.includes(InherentFlags.REJECTED)
|
|
8946
|
+
if (flags.includes(InherentFlags.REJECTED)) {
|
|
8947
8947
|
return getAvailableActionsWithoutFlagFilters(
|
|
8948
8948
|
EventStatus.enum.CREATED,
|
|
8949
8949
|
flags.filter((flag2) => flag2 !== InherentFlags.REJECTED)
|
|
8950
8950
|
).filter((action) => action !== ActionType.DELETE).concat(ActionType.ARCHIVE);
|
|
8951
8951
|
}
|
|
8952
|
+
if (flags.includes(InherentFlags.EDIT_IN_PROGRESS)) {
|
|
8953
|
+
return [ActionType.DECLARE, ActionType.REGISTER];
|
|
8954
|
+
}
|
|
8952
8955
|
return AVAILABLE_ACTIONS_BY_EVENT_STATUS[status2];
|
|
8953
8956
|
}
|
|
8954
8957
|
case EventStatus.enum.REGISTERED: {
|