@rytass/bpm-core-nestjs-module 0.16.2 → 0.17.0

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.
Files changed (60) hide show
  1. package/CHANGELOG.md +52 -0
  2. package/README.md +415 -261
  3. package/package.json +2 -2
  4. package/src/lib/delegation/delegation-rule.entity.js +3 -1
  5. package/src/lib/delegation/delegation-rule.entity.js.map +1 -1
  6. package/src/lib/delegation/delegation.service.d.ts +4 -0
  7. package/src/lib/delegation/delegation.service.js +19 -3
  8. package/src/lib/delegation/delegation.service.js.map +1 -1
  9. package/src/lib/delegation/dto/delegation-rule.input.js +6 -2
  10. package/src/lib/delegation/dto/delegation-rule.input.js.map +1 -1
  11. package/src/lib/migrations/0000000000001-enable-postgres-extensions.js +6 -2
  12. package/src/lib/migrations/0000000000001-enable-postgres-extensions.js.map +1 -1
  13. package/src/lib/notification/notification-options.d.ts +5 -5
  14. package/src/lib/notification/notification.service.js +5 -2
  15. package/src/lib/notification/notification.service.js.map +1 -1
  16. package/src/lib/organization/index.d.ts +1 -0
  17. package/src/lib/organization/index.js +1 -0
  18. package/src/lib/organization/index.js.map +1 -1
  19. package/src/lib/organization/org-unit-retirement-impact.object.d.ts +18 -0
  20. package/src/lib/organization/org-unit-retirement-impact.object.js +34 -0
  21. package/src/lib/organization/org-unit-retirement-impact.object.js.map +1 -0
  22. package/src/lib/organization/organization.mutations.d.ts +1 -1
  23. package/src/lib/organization/organization.mutations.js +7 -4
  24. package/src/lib/organization/organization.mutations.js.map +1 -1
  25. package/src/lib/organization/organization.queries.d.ts +2 -0
  26. package/src/lib/organization/organization.queries.js +13 -0
  27. package/src/lib/organization/organization.queries.js.map +1 -1
  28. package/src/lib/organization/organization.service.d.ts +32 -1
  29. package/src/lib/organization/organization.service.js +157 -16
  30. package/src/lib/organization/organization.service.js.map +1 -1
  31. package/src/lib/template/template.service.js +91 -57
  32. package/src/lib/template/template.service.js.map +1 -1
  33. package/src/lib/template/workflow-definition.validator.js +11 -0
  34. package/src/lib/template/workflow-definition.validator.js.map +1 -1
  35. package/src/lib/workflow-engine/dto/reassign-member-tasks.input.d.ts +7 -0
  36. package/src/lib/workflow-engine/dto/reassign-member-tasks.input.js +34 -0
  37. package/src/lib/workflow-engine/dto/reassign-member-tasks.input.js.map +1 -0
  38. package/src/lib/workflow-engine/dto/reassign-task.input.d.ts +8 -0
  39. package/src/lib/workflow-engine/dto/reassign-task.input.js +39 -0
  40. package/src/lib/workflow-engine/dto/reassign-task.input.js.map +1 -0
  41. package/src/lib/workflow-engine/index.d.ts +3 -0
  42. package/src/lib/workflow-engine/index.js +3 -0
  43. package/src/lib/workflow-engine/index.js.map +1 -1
  44. package/src/lib/workflow-engine/task-reassignment.object.d.ts +26 -0
  45. package/src/lib/workflow-engine/task-reassignment.object.js +97 -0
  46. package/src/lib/workflow-engine/task-reassignment.object.js.map +1 -0
  47. package/src/lib/workflow-engine/workflow-engine.enums.d.ts +29 -0
  48. package/src/lib/workflow-engine/workflow-engine.enums.js +42 -1
  49. package/src/lib/workflow-engine/workflow-engine.enums.js.map +1 -1
  50. package/src/lib/workflow-engine/workflow-engine.mutations.d.ts +5 -0
  51. package/src/lib/workflow-engine/workflow-engine.mutations.js +48 -0
  52. package/src/lib/workflow-engine/workflow-engine.mutations.js.map +1 -1
  53. package/src/lib/workflow-engine/workflow-engine.queries.d.ts +2 -0
  54. package/src/lib/workflow-engine/workflow-engine.queries.js +15 -0
  55. package/src/lib/workflow-engine/workflow-engine.queries.js.map +1 -1
  56. package/src/lib/workflow-engine/workflow-engine.service.d.ts +150 -1
  57. package/src/lib/workflow-engine/workflow-engine.service.js +716 -45
  58. package/src/lib/workflow-engine/workflow-engine.service.js.map +1 -1
  59. package/src/lib/workflow-engine/workflow-engine.tokens.d.ts +2 -1
  60. package/src/lib/workflow-engine/workflow-engine.tokens.js.map +1 -1
package/CHANGELOG.md CHANGED
@@ -1,3 +1,55 @@
1
+ ## 0.17.0 (2026-10-15)
2
+
3
+ ### 🚀 Features
4
+
5
+ - ⚠️ **workflow-engine:** end SLA-terminated instances as EXPIRED ([7dcca4e](https://github.com/Rytass/BPMCore/commit/7dcca4e))
6
+ - **template:** allow lastDecision in edge conditions ([e8b4788](https://github.com/Rytass/BPMCore/commit/e8b4788))
7
+ - **workflow-engine:** add administrator in-place task reassignment ([02ce920](https://github.com/Rytass/BPMCore/commit/02ce920))
8
+ - **template:** lint blank POSITION fallback position ids ([2a29ece](https://github.com/Rytass/BPMCore/commit/2a29ece))
9
+ - **workflow-engine:** resolve POSITION fallbacks to every current holder ([a42bf54](https://github.com/Rytass/BPMCore/commit/a42bf54))
10
+ - ⚠️ **organization:** retire org units into a successor unit ([514e0b2](https://github.com/Rytass/BPMCore/commit/514e0b2))
11
+
12
+ ### 🩹 Fixes
13
+
14
+ - **migrations:** check pg_trgm with the other required extensions ([30a1e58](https://github.com/Rytass/BPMCore/commit/30a1e58))
15
+ - **template:** check CEL roots per call site on publish ([868d236](https://github.com/Rytass/BPMCore/commit/868d236))
16
+ - **delegation:** check scope condition roots when a rule is saved ([bc8af75](https://github.com/Rytass/BPMCore/commit/bc8af75))
17
+ - ⚠️ **delegation:** order rules by priority, higher first ([96cca55](https://github.com/Rytass/BPMCore/commit/96cca55))
18
+ - **workflow-engine:** keep the task holder and reject decided targets on group transfer ([515b3c2](https://github.com/Rytass/BPMCore/commit/515b3c2))
19
+ - **organization:** keep a continued membership's original end date ([ce1f84f](https://github.com/Rytass/BPMCore/commit/ce1f84f))
20
+ - **workflow-engine:** keep a group stage open when a holder transfers ([2cb0a96](https://github.com/Rytass/BPMCore/commit/2cb0a96))
21
+ - **workflow-engine:** refuse unknown approver fallback types by name ([15b8d1c](https://github.com/Rytass/BPMCore/commit/15b8d1c))
22
+
23
+ ### 🔥 Performance
24
+
25
+ - **workflow-engine:** read member open task templates in one query ([49ae231](https://github.com/Rytass/BPMCore/commit/49ae231))
26
+
27
+ ### ⚠️ Breaking Changes
28
+
29
+ - **workflow-engine:** end SLA-terminated instances as EXPIRED ([7dcca4e](https://github.com/Rytass/BPMCore/commit/7dcca4e))
30
+ an instance ended by SLA `TERMINATE_INSTANCE` is now
31
+ `EXPIRED` instead of `CANCELLED`, and its activity log is
32
+ `INSTANCE_EXPIRED` with a null actor instead of `INSTANCE_CANCELLED` in
33
+ the initiator's name. Instances terminated before this change stay
34
+ CANCELLED. A host implementing `BPMWorkflowEngineService` itself must add
35
+ `expireApprovalInstance`.
36
+ - **delegation:** order rules by priority, higher first ([96cca55](https://github.com/Rytass/BPMCore/commit/96cca55))
37
+ when several active delegation rules of one principal
38
+ match a task, the rule with the highest priority now applies instead of
39
+ the oldest. No data migration is needed: priority had no effect before,
40
+ but principals with overlapping rules may now be delegated differently,
41
+ so review their priorities.
42
+ - **organization:** retire org units into a successor unit ([514e0b2](https://github.com/Rytass/BPMCore/commit/514e0b2))
43
+ deleteOrgUnit now also refuses a unit that has no open
44
+ memberships but still has an open ORG_UNIT-scoped manager rule; it used to
45
+ retire it and leave the rule silently dormant. Pass transferToOrgUnitId (or
46
+ end the rule first) to retire such a unit. The refusal message keeps its
47
+ leading "Org unit with memberships cannot be deleted" sentence.
48
+
49
+ ### ❤️ Thank You
50
+
51
+ - Chia Yu Pai @fantasywind
52
+
1
53
  ## 0.16.2 (2026-10-14)
2
54
 
3
55
  ### 🚀 Features