@opencrvs/toolkit 2.0.0-rc.edc01c2 → 2.0.0-rc.ede6db8

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.
@@ -7374,13 +7374,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7374
7374
  output: void;
7375
7375
  meta: import("trpc-to-openapi").OpenApiMeta;
7376
7376
  }>;
7377
- requestContactChange: import("@trpc/server").TRPCMutationProcedure<{
7377
+ sendVerifyCode: import("@trpc/server").TRPCMutationProcedure<{
7378
7378
  input: {
7379
- notificationEvent: "change-email-address";
7380
- email: string;
7381
- } | {
7382
- notificationEvent: "change-phone-number";
7383
- phoneNumber: string;
7379
+ notificationEvent: "change-phone-number" | "change-email-address";
7384
7380
  };
7385
7381
  output: {
7386
7382
  nonce: string;
@@ -10623,19 +10623,18 @@ var ACTION_FILTERS = {
10623
10623
  function filterActionsByFlags(actions, flags) {
10624
10624
  return actions.filter((action) => ACTION_FILTERS[action]?.(flags) ?? true);
10625
10625
  }
10626
- var REJECTED_ACTIONS = [
10627
- ActionType.READ,
10628
- ActionType.NOTIFY,
10629
- ActionType.CUSTOM,
10630
- ActionType.EDIT,
10631
- ActionType.ARCHIVE
10632
- ];
10633
10626
  function getAvailableActionsWithoutFlagFilters(status2, flags) {
10634
10627
  if (flags.includes(InherentFlags.EDIT_IN_PROGRESS)) {
10635
10628
  return [ActionType.NOTIFY, ActionType.DECLARE, ActionType.REGISTER];
10636
10629
  }
10637
- if (flags.includes(InherentFlags.REJECTED) && status2 !== EventStatus.enum.ARCHIVED) {
10638
- return REJECTED_ACTIONS;
10630
+ if (flags.includes(InherentFlags.REJECTED)) {
10631
+ return [
10632
+ ActionType.READ,
10633
+ ActionType.NOTIFY,
10634
+ ActionType.CUSTOM,
10635
+ ActionType.EDIT,
10636
+ ActionType.ARCHIVE
10637
+ ];
10639
10638
  }
10640
10639
  return AVAILABLE_ACTIONS_BY_EVENT_STATUS[status2];
10641
10640
  }
@@ -7241,13 +7241,6 @@ var ACTION_FILTERS = {
7241
7241
  [ActionType.UNASSIGN]: (flags) => !flags.some((flag) => flag.endsWith(":requested")),
7242
7242
  [ActionType.CUSTOM]: (flags) => !flags.some((flag) => flag.endsWith(":requested"))
7243
7243
  };
7244
- var REJECTED_ACTIONS = [
7245
- ActionType.READ,
7246
- ActionType.NOTIFY,
7247
- ActionType.CUSTOM,
7248
- ActionType.EDIT,
7249
- ActionType.ARCHIVE
7250
- ];
7251
7244
 
7252
7245
  // ../commons/src/events/FileUtils.ts
7253
7246
  var import_lodash7 = require("lodash");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opencrvs/toolkit",
3
- "version": "2.0.0-rc.edc01c2",
3
+ "version": "2.0.0-rc.ede6db8",
4
4
  "description": "OpenCRVS toolkit for building country configurations",
5
5
  "license": "MPL-2.0",
6
6
  "bin": {