verben-workflow-ui 0.6.5 → 0.6.6
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/ng-package.json +15 -0
- package/package.json +8 -193
- package/src/lib/base/core/base-data-page.facade.ts +533 -0
- package/src/lib/base/core/base-data-page.service.ts +222 -0
- package/src/lib/base/core/base-data-page.state.ts +287 -0
- package/src/lib/base/handlers/filter-handler.service.ts +169 -0
- package/src/lib/base/handlers/search-handler.service.ts +33 -0
- package/src/lib/base/handlers/sort-handler.service.ts +93 -0
- package/src/lib/base/models/api-payload.ts +13 -0
- package/src/lib/base/models/page-config.interface.ts +49 -0
- package/src/lib/base/models/page-filter-tab-option.interface.ts +20 -0
- package/src/lib/base/ng-package.json +6 -0
- package/src/lib/base/public-api.ts +16 -0
- package/src/lib/base/utils/column-helpers.ts +77 -0
- package/src/lib/components/actors/actors.columns.ts +40 -0
- package/src/lib/components/actors/actors.component.css +0 -0
- package/src/lib/components/actors/actors.component.html +320 -0
- package/src/lib/components/actors/actors.component.spec.ts +23 -0
- package/src/lib/components/actors/actors.component.ts +221 -0
- package/src/lib/components/actors/actors.config.ts +55 -0
- package/src/lib/components/actors/actors.facade.ts +71 -0
- package/src/lib/components/actors/actors.form.component.html +37 -0
- package/src/lib/components/actors/actors.form.component.ts +69 -0
- package/src/lib/components/actors/actors.model.ts +4 -0
- package/src/lib/components/actors/actors.module.ts +13 -0
- package/src/lib/components/actors/actors.service.ts +85 -0
- package/src/lib/components/actors/actors.state.ts +31 -0
- package/src/lib/components/actors/ng-package.json +6 -0
- package/src/lib/components/designer/components/label-editor.component.ts +188 -0
- package/src/lib/components/designer/components/node-selector.component.ts +208 -0
- package/src/lib/components/designer/components/swimlane-label.component.ts +102 -0
- package/src/lib/components/designer/components/swimlane-popup.component.ts +51 -0
- package/src/lib/components/designer/components/wf-canvas.component.ts +495 -0
- package/src/lib/components/designer/components/wf-designer.component.ts +182 -0
- package/src/lib/components/designer/components/wf-node.component.ts +91 -0
- package/src/lib/components/designer/components/wf-properties-popup.component.ts +257 -0
- package/src/lib/components/designer/components/wf-toolbar.component.ts +84 -0
- package/src/lib/components/designer/models/types.ts +133 -0
- package/src/lib/components/designer/ng-package.json +6 -0
- package/src/lib/components/designer/services/canvas-state.service.ts +63 -0
- package/src/lib/components/designer/services/connection-segment-interaction.service.ts +141 -0
- package/src/lib/components/designer/services/connection.service.ts +351 -0
- package/src/lib/components/designer/services/keyboard-handler.service.ts +39 -0
- package/src/lib/components/designer/services/label-management.service.ts +72 -0
- package/src/lib/components/designer/services/node-finder.service.ts +34 -0
- package/src/lib/components/designer/services/node-interaction.service.ts +135 -0
- package/src/lib/components/designer/services/node-placement.service.ts +77 -0
- package/src/lib/components/designer/services/node-precondition.service.ts +138 -0
- package/src/lib/components/designer/services/node-renderer.service.ts +97 -0
- package/src/lib/components/designer/services/node-selection.service.ts +110 -0
- package/src/lib/components/designer/services/orthogonal-router.service.ts +233 -0
- package/src/lib/components/designer/services/position-update.service.ts +56 -0
- package/src/lib/components/designer/services/rendering.service.ts +296 -0
- package/src/lib/components/designer/services/swimlane-management.service.ts +189 -0
- package/src/lib/components/designer/services/swimlane-stats.service.ts +53 -0
- package/src/lib/components/designer/services/tag-helper.service.ts +80 -0
- package/src/lib/components/designer/services/viewport.service.ts +30 -0
- package/src/lib/components/designer/services/wf-facade.service.ts +287 -0
- package/src/lib/components/designer/services/wf-mapper.service.ts +450 -0
- package/src/lib/components/designer/services/wf-persistence.service.ts +184 -0
- package/src/lib/components/designer/services/wf-state.service.ts +143 -0
- package/src/lib/components/expiration/expiration.component.css +0 -0
- package/src/lib/components/expiration/expiration.component.html +21 -0
- package/src/lib/components/expiration/expiration.component.spec.ts +23 -0
- package/src/lib/components/expiration/expiration.component.ts +52 -0
- package/src/lib/components/expiration/expiration.module.ts +11 -0
- package/src/lib/components/expiration/ng-package.json +6 -0
- package/src/lib/components/file-render/file-render.component.css +4 -0
- package/src/lib/components/file-render/file-render.component.html +21 -0
- package/src/lib/components/file-render/file-render.component.spec.ts +23 -0
- package/src/lib/components/file-render/file-render.component.ts +34 -0
- package/src/lib/components/file-render/file-render.module.ts +19 -0
- package/src/lib/components/file-render/ng-package.json +6 -0
- package/src/lib/components/file-upload/file-upload.component.css +0 -0
- package/src/lib/components/file-upload/file-upload.component.html +69 -0
- package/src/lib/components/file-upload/file-upload.component.spec.ts +23 -0
- package/src/lib/components/file-upload/file-upload.component.ts +87 -0
- package/src/lib/components/file-upload/file-upload.module.ts +40 -0
- package/src/lib/components/file-upload/ng-package.json +6 -0
- package/src/lib/components/flowable-status/flowable-status.columns.ts +23 -0
- package/src/lib/components/flowable-status/flowable-status.component.css +1 -0
- package/src/lib/components/flowable-status/flowable-status.component.html +166 -0
- package/src/lib/components/flowable-status/flowable-status.component.ts +247 -0
- package/src/lib/components/flowable-status/flowable-status.config.ts +54 -0
- package/src/lib/components/flowable-status/flowable-status.facade.ts +70 -0
- package/src/lib/components/flowable-status/flowable-status.form.component.html +13 -0
- package/src/lib/components/flowable-status/flowable-status.form.component.ts +51 -0
- package/src/lib/components/flowable-status/flowable-status.model.ts +3 -0
- package/src/lib/components/flowable-status/flowable-status.module.ts +13 -0
- package/src/lib/components/flowable-status/flowable-status.service.ts +39 -0
- package/src/lib/components/flowable-status/flowable-status.state.ts +10 -0
- package/src/lib/components/flowable-status/ng-package.json +6 -0
- package/src/lib/components/flowable-status/public-api.ts +3 -0
- package/src/lib/components/form-control/form-control.component.css +0 -0
- package/src/lib/components/form-control/form-control.component.html +259 -0
- package/src/lib/components/form-control/form-control.component.spec.ts +23 -0
- package/src/lib/components/form-control/form-control.component.ts +197 -0
- package/src/lib/components/form-control/form-control.module.ts +47 -0
- package/src/lib/components/form-control/ng-package.json +6 -0
- package/src/lib/components/form-group/base-table-style.ts +52 -0
- package/src/lib/components/form-group/form-fields/form-fields.component.css +114 -0
- package/src/lib/components/form-group/form-fields/form-fields.component.html +621 -0
- package/src/lib/components/form-group/form-fields/form-fields.component.spec.ts +23 -0
- package/src/lib/components/form-group/form-fields/form-fields.component.ts +1115 -0
- package/src/lib/components/form-group/form-fields/form-fields.module.ts +48 -0
- package/src/lib/components/form-group/form-fields/form-fields.service.ts +70 -0
- package/src/lib/components/form-group/form-fields/helper.ts +45 -0
- package/src/lib/components/form-group/form-group.component.css +113 -0
- package/src/lib/components/form-group/form-group.component.html +486 -0
- package/src/lib/components/form-group/form-group.component.spec.ts +22 -0
- package/src/lib/components/form-group/form-group.component.ts +789 -0
- package/src/lib/components/form-group/form-group.module.ts +54 -0
- package/src/lib/components/form-group/form-group.service.ts +53 -0
- package/src/lib/components/form-group/helper.ts +45 -0
- package/src/lib/components/form-group/ng-package.json +6 -0
- package/src/lib/components/form-response/form-response.component.css +114 -0
- package/src/lib/components/form-response/form-response.component.html +188 -0
- package/src/lib/components/form-response/form-response.component.spec.ts +23 -0
- package/src/lib/components/form-response/form-response.component.ts +735 -0
- package/src/lib/components/form-response/form-response.module.ts +48 -0
- package/src/lib/components/form-response/form-response.service.ts +52 -0
- package/src/lib/components/form-response/helper.ts +222 -0
- package/src/lib/components/form-response/ng-package.json +6 -0
- package/src/lib/components/form-timer/form-timer.component.css +0 -0
- package/src/lib/components/form-timer/form-timer.component.html +47 -0
- package/src/lib/components/form-timer/form-timer.component.spec.ts +23 -0
- package/src/lib/components/form-timer/form-timer.component.ts +50 -0
- package/src/lib/components/form-timer/form-timer.module.ts +19 -0
- package/src/lib/components/form-timer/ng-package.json +6 -0
- package/src/lib/components/form-values/form-values.component.css +48 -0
- package/src/lib/components/form-values/form-values.component.html +225 -0
- package/src/lib/components/form-values/form-values.component.ts +1437 -0
- package/src/lib/components/form-values/form-values.module.ts +13 -0
- package/src/lib/components/form-values/form-values.service.ts +45 -0
- package/src/lib/components/form-values/ng-package.json +6 -0
- package/src/lib/components/form-values/public-api.ts +3 -0
- package/src/lib/components/form-viewer/form-viewer.component.css +4 -0
- package/src/lib/components/form-viewer/form-viewer.component.html +62 -0
- package/src/lib/components/form-viewer/form-viewer.component.spec.ts +23 -0
- package/src/lib/components/form-viewer/form-viewer.component.ts +31 -0
- package/src/lib/components/form-viewer/form-viewer.module.ts +52 -0
- package/src/lib/components/form-viewer/ng-package.json +6 -0
- package/src/lib/components/forms/base-table-style.ts +52 -0
- package/src/lib/components/forms/forms.component.css +126 -0
- package/src/lib/components/forms/forms.component.html +538 -0
- package/src/lib/components/forms/forms.component.spec.ts +23 -0
- package/src/lib/components/forms/forms.component.ts +810 -0
- package/src/lib/components/forms/forms.module.ts +10 -0
- package/src/lib/components/forms/forms.service.spec.ts +16 -0
- package/src/lib/components/forms/forms.service.ts +65 -0
- package/src/lib/components/forms/ng-package.json +6 -0
- package/src/lib/components/journal/journal.component.css +0 -0
- package/src/lib/components/journal/journal.component.html +1 -0
- package/src/lib/components/journal/journal.component.spec.ts +23 -0
- package/src/lib/components/journal/journal.component.ts +10 -0
- package/src/lib/components/journal/journal.module.ts +10 -0
- package/src/lib/components/journal/ng-package.json +6 -0
- package/src/lib/components/my-queue/my-queue.columns.ts +37 -0
- package/src/lib/components/my-queue/my-queue.component.css +8 -0
- package/src/lib/components/my-queue/my-queue.component.html +319 -0
- package/src/lib/components/my-queue/my-queue.component.spec.ts +23 -0
- package/src/lib/components/my-queue/my-queue.component.ts +409 -0
- package/src/lib/components/my-queue/my-queue.facade.ts +670 -0
- package/src/lib/components/my-queue/my-queue.helper.ts +71 -0
- package/src/lib/components/my-queue/my-queue.module.ts +28 -0
- package/src/lib/components/my-queue/my-queue.service.spec.ts +16 -0
- package/src/lib/components/my-queue/my-queue.service.ts +262 -0
- package/src/lib/components/my-queue/my-queue.state.ts +133 -0
- package/src/lib/components/my-queue/ng-package.json +6 -0
- package/src/lib/components/my-queue/tasks.form.component.html +168 -0
- package/src/lib/components/my-queue/tasks.form.component.ts +201 -0
- package/src/lib/components/operation-popup/ng-package.json +6 -0
- package/src/lib/components/operation-popup/operation-popup.component.css +1 -0
- package/src/lib/components/operation-popup/operation-popup.component.html +107 -0
- package/src/lib/components/operation-popup/operation-popup.component.ts +476 -0
- package/src/lib/components/operation-popup/operation-popup.facade.ts +435 -0
- package/src/lib/components/operation-popup/operation-popup.service.ts +143 -0
- package/src/lib/components/operation-popup/operation-popup.state.ts +49 -0
- package/src/lib/components/stage-details/ng-package.json +6 -0
- package/src/lib/components/stage-details/stage-details.component.css +0 -0
- package/src/lib/components/stage-details/stage-details.component.html +95 -0
- package/src/lib/components/stage-details/stage-details.component.spec.ts +23 -0
- package/src/lib/components/stage-details/stage-details.component.ts +43 -0
- package/src/lib/components/stage-details/stage-details.module.ts +11 -0
- package/src/lib/components/task-form/ng-package.json +6 -0
- package/src/lib/components/task-form/task-form.component.css +0 -0
- package/src/lib/components/task-form/task-form.component.html +38 -0
- package/src/lib/components/task-form/task-form.component.spec.ts +23 -0
- package/src/lib/components/task-form/task-form.component.ts +15 -0
- package/src/lib/components/task-form/task-form.module.ts +31 -0
- package/src/lib/components/task-history/ng-package.json +6 -0
- package/src/lib/components/task-history/task-history.component.css +334 -0
- package/src/lib/components/task-history/task-history.component.html +292 -0
- package/src/lib/components/task-history/task-history.component.spec.ts +23 -0
- package/src/lib/components/task-history/task-history.component.ts +284 -0
- package/src/lib/components/task-history/task-history.module.ts +12 -0
- package/src/lib/components/task-history/task-history.service.ts +32 -0
- package/src/lib/components/task-notification/base-table-style.ts +52 -0
- package/src/lib/components/task-notification/ng-package.json +6 -0
- package/src/lib/components/task-notification/task-notification.component.css +94 -0
- package/src/lib/components/task-notification/task-notification.component.html +585 -0
- package/src/lib/components/task-notification/task-notification.component.spec.ts +23 -0
- package/src/lib/components/task-notification/task-notification.component.ts +793 -0
- package/src/lib/components/task-notification/task-notification.module.ts +10 -0
- package/src/lib/components/task-notification/task-notification.service.spec.ts +16 -0
- package/src/lib/components/task-notification/task-notification.service.ts +397 -0
- package/src/lib/components/tasks/ng-package.json +6 -0
- package/src/lib/components/tasks/tasks.columns.ts +50 -0
- package/src/lib/components/tasks/tasks.component.css +4 -0
- package/src/lib/components/tasks/tasks.component.html +385 -0
- package/src/lib/components/tasks/tasks.component.spec.ts +23 -0
- package/src/lib/components/tasks/tasks.component.ts +212 -0
- package/src/lib/components/tasks/tasks.facade.ts +482 -0
- package/src/lib/components/tasks/tasks.form.component.html +181 -0
- package/src/lib/components/tasks/tasks.form.component.ts +174 -0
- package/src/lib/components/tasks/tasks.helper.ts +71 -0
- package/src/lib/components/tasks/tasks.models.ts +4 -0
- package/src/lib/components/tasks/tasks.module.ts +29 -0
- package/src/lib/components/tasks/tasks.service.spec.ts +16 -0
- package/src/lib/components/tasks/tasks.service.ts +215 -0
- package/src/lib/components/tasks/tasks.state.ts +144 -0
- package/src/lib/components/wf/ng-package.json +6 -0
- package/src/lib/components/wf/wf.columns.ts +36 -0
- package/src/lib/components/wf/wf.component.css +0 -0
- package/src/lib/components/wf/wf.component.html +35 -0
- package/src/lib/components/wf/wf.component.spec.ts +23 -0
- package/src/lib/components/wf/wf.component.ts +71 -0
- package/src/lib/components/wf/wf.facade.ts +266 -0
- package/src/lib/components/wf/wf.helper.ts +25 -0
- package/src/lib/components/wf/wf.module.ts +14 -0
- package/src/lib/components/wf/wf.service.spec.ts +16 -0
- package/src/lib/components/wf/wf.service.ts +98 -0
- package/src/lib/components/wf/wf.state.ts +99 -0
- package/src/lib/components/workflow/column.ts +40 -0
- package/src/lib/components/workflow/helper.ts +53 -0
- package/src/lib/components/workflow/ng-package.json +6 -0
- package/src/lib/components/workflow/table-style.ts +53 -0
- package/src/lib/components/workflow/workflow.component.css +0 -0
- package/src/lib/components/workflow/workflow.component.html +226 -0
- package/src/lib/components/workflow/workflow.component.spec.ts +23 -0
- package/src/lib/components/workflow/workflow.component.ts +224 -0
- package/src/lib/components/workflow/workflow.module.ts +11 -0
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.css +9 -0
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.html +134 -0
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.ts +147 -0
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.css +0 -0
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.html +45 -0
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.ts +83 -0
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.css +7 -0
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.html +89 -0
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.ts +87 -0
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.css +11 -0
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.html +74 -0
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.ts +80 -0
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.css +70 -0
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.html +454 -0
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.ts +1654 -0
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.connection-drop.spec.ts +100 -0
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.css +63 -0
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.html +49 -0
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.ts +86 -0
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.types.ts +7 -0
- package/src/lib/components/workflow-designer/docs/01-architecture.md +145 -0
- package/src/lib/components/workflow-designer/docs/02-coordinate-system.md +171 -0
- package/src/lib/components/workflow-designer/docs/03-data-model.md +163 -0
- package/src/lib/components/workflow-designer/docs/04-interactions.md +156 -0
- package/src/lib/components/workflow-designer/docs/05-persistence.md +117 -0
- package/src/lib/components/workflow-designer/docs/06-known-issues.md +181 -0
- package/src/lib/components/workflow-designer/docs/07-integration.md +178 -0
- package/src/lib/components/workflow-designer/docs/08-api-reference.md +187 -0
- package/src/lib/components/workflow-designer/docs/09-development.md +141 -0
- package/src/lib/components/workflow-designer/docs/README.md +81 -0
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.css +13 -0
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.html +204 -0
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.ts +308 -0
- package/src/lib/components/workflow-designer/ng-package.json +6 -0
- package/src/lib/components/workflow-designer/services/connection.service.ts +325 -0
- package/src/lib/components/workflow-designer/services/node-management.service.ts +372 -0
- package/src/lib/components/workflow-designer/services/popup.service.ts +276 -0
- package/src/lib/components/workflow-designer/services/swimlane.service.ts +176 -0
- package/src/lib/components/workflow-designer/services/transformer.service.ts +318 -0
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.css +0 -0
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.html +208 -0
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.ts +194 -0
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.css +15 -0
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.html +93 -0
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.ts +258 -0
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.css +0 -0
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.html +150 -0
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.ts +153 -0
- package/src/lib/components/workflow-designer/workflow-data.service.spec.ts +16 -0
- package/src/lib/components/workflow-designer/workflow-data.service.ts +290 -0
- package/src/lib/components/workflow-designer/workflow-designer.component.css +59 -0
- package/src/lib/components/workflow-designer/workflow-designer.component.html +29 -0
- package/src/lib/components/workflow-designer/workflow-designer.component.spec.ts +23 -0
- package/src/lib/components/workflow-designer/workflow-designer.component.ts +548 -0
- package/src/lib/components/workflow-designer/workflow-designer.models.ts +114 -0
- package/src/lib/components/workflow-designer/workflow-designer.module.ts +90 -0
- package/src/lib/components/workflow-designer/workflow-designer.state.ts +1123 -0
- package/src/lib/components/workflow-designer/workflow-designer.types.ts +141 -0
- package/src/lib/components/workflow-stage/ng-package.json +6 -0
- package/src/lib/components/workflow-stage/workflow-stage.component.css +24 -0
- package/src/lib/components/workflow-stage/workflow-stage.component.html +339 -0
- package/src/lib/components/workflow-stage/workflow-stage.component.spec.ts +23 -0
- package/src/lib/components/workflow-stage/workflow-stage.component.ts +355 -0
- package/src/lib/components/workflow-stage/workflow-stage.module.ts +53 -0
- package/src/lib/components/workflows/ng-package.json +6 -0
- package/src/lib/components/workflows/public-api.ts +6 -0
- package/src/lib/components/workflows/workflow-form/workflow-form.component.css +0 -0
- package/src/lib/components/workflows/workflow-form/workflow-form.component.html +138 -0
- package/src/lib/components/workflows/workflow-form/workflow-form.component.spec.ts +23 -0
- package/src/lib/components/workflows/workflow-form/workflow-form.component.ts +85 -0
- package/src/lib/components/workflows/workflows.api.ts +117 -0
- package/src/lib/components/workflows/workflows.columns.ts +41 -0
- package/src/lib/components/workflows/workflows.component.css +4 -0
- package/src/lib/components/workflows/workflows.component.html +309 -0
- package/src/lib/components/workflows/workflows.component.spec.ts +23 -0
- package/src/lib/components/workflows/workflows.component.ts +303 -0
- package/src/lib/components/workflows/workflows.config.ts +58 -0
- package/src/lib/components/workflows/workflows.facade.ts +147 -0
- package/src/lib/components/workflows/workflows.module.ts +14 -0
- package/src/lib/components/workflows/workflows.service.spec.ts +16 -0
- package/src/lib/components/workflows/workflows.service.ts +88 -0
- package/src/lib/components/workflows/workflows.state.ts +21 -0
- package/src/lib/models/ActionHistory.ts +19 -0
- package/src/lib/models/ActionType.ts +9 -0
- package/src/lib/models/Actor.ts +12 -0
- package/src/lib/models/ActorTag.ts +8 -0
- package/src/lib/models/Coord.ts +4 -0
- package/src/lib/models/DataExtensionValue.ts +5 -0
- package/src/lib/models/DataType.ts +25 -0
- package/src/lib/models/EAVDataType.ts +18 -0
- package/src/lib/models/EAVEntity.ts +5 -0
- package/src/lib/models/EntityDataValue.ts +7 -0
- package/src/lib/models/EntityProperty.ts +8 -0
- package/src/lib/models/ErrorResponse.ts +7 -0
- package/src/lib/models/Escalation.ts +15 -0
- package/src/lib/models/EscalationCycle.ts +13 -0
- package/src/lib/models/EscalationStage.ts +11 -0
- package/src/lib/models/EscalationType.ts +5 -0
- package/src/lib/models/File.ts +8 -0
- package/src/lib/models/FilterTypes.ts +8 -0
- package/src/lib/models/FlowableStatus.ts +6 -0
- package/src/lib/models/Form.ts +14 -0
- package/src/lib/models/FormEntity.ts +14 -0
- package/src/lib/models/FormFill.ts +16 -0
- package/src/lib/models/FormProperty.ts +16 -0
- package/src/lib/models/FormValue.ts +19 -0
- package/src/lib/models/MailConfig.ts +13 -0
- package/src/lib/models/MessageConfig.ts +5 -0
- package/src/lib/models/MessageMedium.ts +4 -0
- package/src/lib/models/OperationAction.ts +15 -0
- package/src/lib/models/PagedResult.ts +5 -0
- package/src/lib/models/PeriodMode.ts +10 -0
- package/src/lib/models/PermissionConfig.ts +8 -0
- package/src/lib/models/Property.ts +6 -0
- package/src/lib/models/ReportSchedule.ts +23 -0
- package/src/lib/models/ReportType.ts +5 -0
- package/src/lib/models/Resource.ts +57 -0
- package/src/lib/models/ResponseKeyValue.ts +5 -0
- package/src/lib/models/SMSConfig.ts +11 -0
- package/src/lib/models/SearchDynamicWrapper.ts +6 -0
- package/src/lib/models/SearchOperator.ts +4 -0
- package/src/lib/models/SearchPropertySign.ts +9 -0
- package/src/lib/models/SearchPropertyValue.ts +13 -0
- package/src/lib/models/SearchPropertyValueType.ts +9 -0
- package/src/lib/models/Size.ts +4 -0
- package/src/lib/models/SortDirection.ts +5 -0
- package/src/lib/models/StageActorRule.ts +6 -0
- package/src/lib/models/SwimLane.ts +14 -0
- package/src/lib/models/Tag.ts +7 -0
- package/src/lib/models/Task.ts +33 -0
- package/src/lib/models/TaskAssignmentType.ts +4 -0
- package/src/lib/models/TaskNotification.ts +16 -0
- package/src/lib/models/TaskNotificationMessageType.ts +4 -0
- package/src/lib/models/TaskNotificationType.ts +7 -0
- package/src/lib/models/TaskStatus.ts +7 -0
- package/src/lib/models/Workflow.ts +22 -0
- package/src/lib/models/WorkflowAction.ts +15 -0
- package/src/lib/models/WorkflowOperation.ts +7 -0
- package/src/lib/models/WorkflowStage.ts +27 -0
- package/src/lib/models/actors.ts +10 -0
- package/src/lib/models/auth-mechanism.ts +14 -0
- package/src/lib/models/base.ts +14 -0
- package/src/lib/models/ng-package.json +6 -0
- package/src/lib/models/object-state.ts +6 -0
- package/src/lib/models/operation-type.ts +6 -0
- package/src/lib/models/paged.ts +9 -0
- package/src/lib/models/public-api.ts +65 -0
- package/src/lib/models/query-params.ts +9 -0
- package/src/lib/models/status.ts +5 -0
- package/src/lib/models/task-history.ts +14 -0
- package/src/lib/models/user-access-request-status.ts +5 -0
- package/src/lib/models/user.ts +25 -0
- package/src/lib/pipes/async-label.pipe.spec.ts +12 -0
- package/src/lib/pipes/async-label.pipe.ts +30 -0
- package/src/lib/pipes/ng-package.json +6 -0
- package/src/lib/services/environment.service.spec.ts +16 -0
- package/src/lib/services/environment.service.ts +31 -0
- package/src/lib/services/http-web-request.service.spec.ts +16 -0
- package/src/lib/services/http-web-request.service.ts +154 -0
- package/src/lib/services/index.ts +1 -0
- package/src/lib/services/label.service.spec.ts +16 -0
- package/src/lib/services/label.service.ts +182 -0
- package/src/lib/services/ng-package.json +6 -0
- package/src/lib/services/public-api.ts +5 -0
- package/src/lib/services/util.service.spec.ts +16 -0
- package/src/lib/services/util.service.ts +72 -0
- package/src/lib/shared/base-table-style.ts +56 -0
- package/src/lib/shared/components/base-data-view.component.ts +187 -0
- package/src/lib/shared/components/base-model-field.ts +31 -0
- package/src/lib/shared/models/DataViewConfig.ts +19 -0
- package/src/lib/shared/ng-package.json +6 -0
- package/src/lib/shared/public-api.ts +14 -0
- package/src/lib/shared/shared.module.ts +67 -0
- package/src/lib/utils/index.ts +1 -0
- package/src/lib/utils/public-api.ts +2 -0
- package/src/lib/utils/store.ts +50 -0
- package/src/public-api.ts +58 -0
- package/src/styles.css +96 -0
- package/tailwind.config copy.js +33 -0
- package/tailwind.config.js +20 -0
- package/tsconfig.lib.json +15 -0
- package/tsconfig.lib.prod.json +11 -0
- package/tsconfig.spec.json +15 -0
- package/esm2022/public-api.mjs +0 -41
- package/esm2022/src/lib/base/core/base-data-page.facade.mjs +0 -412
- package/esm2022/src/lib/base/core/base-data-page.service.mjs +0 -140
- package/esm2022/src/lib/base/core/base-data-page.state.mjs +0 -216
- package/esm2022/src/lib/base/handlers/filter-handler.service.mjs +0 -138
- package/esm2022/src/lib/base/handlers/search-handler.service.mjs +0 -31
- package/esm2022/src/lib/base/handlers/sort-handler.service.mjs +0 -73
- package/esm2022/src/lib/base/index.mjs +0 -2
- package/esm2022/src/lib/base/models/api-payload.mjs +0 -7
- package/esm2022/src/lib/base/models/page-config.interface.mjs +0 -2
- package/esm2022/src/lib/base/models/page-filter-tab-option.interface.mjs +0 -2
- package/esm2022/src/lib/base/public-api.mjs +0 -14
- package/esm2022/src/lib/base/utils/column-helpers.mjs +0 -55
- package/esm2022/src/lib/base/verben-workflow-ui-src-lib-base.mjs +0 -5
- package/esm2022/src/lib/components/actors/actors.columns.mjs +0 -39
- package/esm2022/src/lib/components/actors/actors.component.mjs +0 -175
- package/esm2022/src/lib/components/actors/actors.config.mjs +0 -49
- package/esm2022/src/lib/components/actors/actors.facade.mjs +0 -57
- package/esm2022/src/lib/components/actors/actors.form.component.mjs +0 -74
- package/esm2022/src/lib/components/actors/actors.module.mjs +0 -21
- package/esm2022/src/lib/components/actors/actors.service.mjs +0 -65
- package/esm2022/src/lib/components/actors/actors.state.mjs +0 -31
- package/esm2022/src/lib/components/actors/index.mjs +0 -2
- package/esm2022/src/lib/components/actors/public-api.mjs +0 -3
- package/esm2022/src/lib/components/actors/verben-workflow-ui-src-lib-components-actors.mjs +0 -5
- package/esm2022/src/lib/components/designer/components/label-editor.component.mjs +0 -148
- package/esm2022/src/lib/components/designer/components/node-selector.component.mjs +0 -317
- package/esm2022/src/lib/components/designer/components/swimlane-label.component.mjs +0 -161
- package/esm2022/src/lib/components/designer/components/swimlane-popup.component.mjs +0 -85
- package/esm2022/src/lib/components/designer/components/wf-canvas.component.mjs +0 -715
- package/esm2022/src/lib/components/designer/components/wf-designer.component.mjs +0 -135
- package/esm2022/src/lib/components/designer/components/wf-toolbar.component.mjs +0 -56
- package/esm2022/src/lib/components/designer/index.mjs +0 -2
- package/esm2022/src/lib/components/designer/models/types.mjs +0 -2
- package/esm2022/src/lib/components/designer/public-api.mjs +0 -3
- package/esm2022/src/lib/components/designer/services/canvas-state.service.mjs +0 -50
- package/esm2022/src/lib/components/designer/services/connection-segment-interaction.service.mjs +0 -108
- package/esm2022/src/lib/components/designer/services/connection.service.mjs +0 -267
- package/esm2022/src/lib/components/designer/services/keyboard-handler.service.mjs +0 -43
- package/esm2022/src/lib/components/designer/services/label-management.service.mjs +0 -66
- package/esm2022/src/lib/components/designer/services/node-finder.service.mjs +0 -30
- package/esm2022/src/lib/components/designer/services/node-interaction.service.mjs +0 -108
- package/esm2022/src/lib/components/designer/services/node-precondition.service.mjs +0 -108
- package/esm2022/src/lib/components/designer/services/node-selection.service.mjs +0 -96
- package/esm2022/src/lib/components/designer/services/orthogonal-router.service.mjs +0 -167
- package/esm2022/src/lib/components/designer/services/position-update.service.mjs +0 -45
- package/esm2022/src/lib/components/designer/services/rendering.service.mjs +0 -236
- package/esm2022/src/lib/components/designer/services/swimlane-management.service.mjs +0 -145
- package/esm2022/src/lib/components/designer/services/swimlane-stats.service.mjs +0 -44
- package/esm2022/src/lib/components/designer/services/viewport.service.mjs +0 -30
- package/esm2022/src/lib/components/designer/services/wf-facade.service.mjs +0 -239
- package/esm2022/src/lib/components/designer/services/wf-mapper.service.mjs +0 -326
- package/esm2022/src/lib/components/designer/services/wf-persistence.service.mjs +0 -169
- package/esm2022/src/lib/components/designer/services/wf-state.service.mjs +0 -108
- package/esm2022/src/lib/components/designer/verben-workflow-ui-src-lib-components-designer.mjs +0 -5
- package/esm2022/src/lib/components/expiration/expiration.component.mjs +0 -49
- package/esm2022/src/lib/components/expiration/expiration.module.mjs +0 -19
- package/esm2022/src/lib/components/expiration/index.mjs +0 -2
- package/esm2022/src/lib/components/expiration/public-api.mjs +0 -3
- package/esm2022/src/lib/components/expiration/verben-workflow-ui-src-lib-components-expiration.mjs +0 -5
- package/esm2022/src/lib/components/file-render/file-render.component.mjs +0 -45
- package/esm2022/src/lib/components/file-render/file-render.module.mjs +0 -35
- package/esm2022/src/lib/components/file-render/index.mjs +0 -2
- package/esm2022/src/lib/components/file-render/public-api.mjs +0 -3
- package/esm2022/src/lib/components/file-render/verben-workflow-ui-src-lib-components-file-render.mjs +0 -5
- package/esm2022/src/lib/components/file-upload/file-upload.component.mjs +0 -93
- package/esm2022/src/lib/components/file-upload/file-upload.module.mjs +0 -63
- package/esm2022/src/lib/components/file-upload/index.mjs +0 -2
- package/esm2022/src/lib/components/file-upload/public-api.mjs +0 -3
- package/esm2022/src/lib/components/file-upload/verben-workflow-ui-src-lib-components-file-upload.mjs +0 -5
- package/esm2022/src/lib/components/flowable-status/flowable-status.columns.mjs +0 -21
- package/esm2022/src/lib/components/flowable-status/flowable-status.component.mjs +0 -203
- package/esm2022/src/lib/components/flowable-status/flowable-status.config.mjs +0 -47
- package/esm2022/src/lib/components/flowable-status/flowable-status.facade.mjs +0 -60
- package/esm2022/src/lib/components/flowable-status/flowable-status.form.component.mjs +0 -52
- package/esm2022/src/lib/components/flowable-status/flowable-status.module.mjs +0 -21
- package/esm2022/src/lib/components/flowable-status/flowable-status.service.mjs +0 -35
- package/esm2022/src/lib/components/flowable-status/flowable-status.state.mjs +0 -15
- package/esm2022/src/lib/components/flowable-status/index.mjs +0 -2
- package/esm2022/src/lib/components/flowable-status/public-api.mjs +0 -3
- package/esm2022/src/lib/components/flowable-status/verben-workflow-ui-src-lib-components-flowable-status.mjs +0 -5
- package/esm2022/src/lib/components/form-control/form-control.component.mjs +0 -180
- package/esm2022/src/lib/components/form-control/form-control.module.mjs +0 -75
- package/esm2022/src/lib/components/form-control/index.mjs +0 -2
- package/esm2022/src/lib/components/form-control/public-api.mjs +0 -3
- package/esm2022/src/lib/components/form-control/verben-workflow-ui-src-lib-components-form-control.mjs +0 -5
- package/esm2022/src/lib/components/form-group/base-table-style.mjs +0 -53
- package/esm2022/src/lib/components/form-group/form-fields/form-fields.component.mjs +0 -952
- package/esm2022/src/lib/components/form-group/form-fields/form-fields.module.mjs +0 -75
- package/esm2022/src/lib/components/form-group/form-fields/form-fields.service.mjs +0 -73
- package/esm2022/src/lib/components/form-group/form-group.component.mjs +0 -699
- package/esm2022/src/lib/components/form-group/form-group.module.mjs +0 -85
- package/esm2022/src/lib/components/form-group/form-group.service.mjs +0 -56
- package/esm2022/src/lib/components/form-group/index.mjs +0 -2
- package/esm2022/src/lib/components/form-group/public-api.mjs +0 -5
- package/esm2022/src/lib/components/form-group/verben-workflow-ui-src-lib-components-form-group.mjs +0 -5
- package/esm2022/src/lib/components/form-response/form-response.component.mjs +0 -641
- package/esm2022/src/lib/components/form-response/form-response.module.mjs +0 -76
- package/esm2022/src/lib/components/form-response/form-response.service.mjs +0 -54
- package/esm2022/src/lib/components/form-response/index.mjs +0 -2
- package/esm2022/src/lib/components/form-response/public-api.mjs +0 -3
- package/esm2022/src/lib/components/form-response/verben-workflow-ui-src-lib-components-form-response.mjs +0 -5
- package/esm2022/src/lib/components/form-timer/form-timer.component.mjs +0 -47
- package/esm2022/src/lib/components/form-timer/form-timer.module.mjs +0 -28
- package/esm2022/src/lib/components/form-timer/index.mjs +0 -2
- package/esm2022/src/lib/components/form-timer/public-api.mjs +0 -3
- package/esm2022/src/lib/components/form-timer/verben-workflow-ui-src-lib-components-form-timer.mjs +0 -5
- package/esm2022/src/lib/components/form-viewer/form-viewer.component.mjs +0 -38
- package/esm2022/src/lib/components/form-viewer/form-viewer.module.mjs +0 -78
- package/esm2022/src/lib/components/form-viewer/index.mjs +0 -2
- package/esm2022/src/lib/components/form-viewer/public-api.mjs +0 -3
- package/esm2022/src/lib/components/form-viewer/verben-workflow-ui-src-lib-components-form-viewer.mjs +0 -5
- package/esm2022/src/lib/components/forms/base-table-style.mjs +0 -53
- package/esm2022/src/lib/components/forms/forms.component.mjs +0 -673
- package/esm2022/src/lib/components/forms/forms.module.mjs +0 -18
- package/esm2022/src/lib/components/forms/forms.service.mjs +0 -68
- package/esm2022/src/lib/components/forms/index.mjs +0 -2
- package/esm2022/src/lib/components/forms/public-api.mjs +0 -3
- package/esm2022/src/lib/components/forms/verben-workflow-ui-src-lib-components-forms.mjs +0 -5
- package/esm2022/src/lib/components/journal/index.mjs +0 -2
- package/esm2022/src/lib/components/journal/journal.component.mjs +0 -11
- package/esm2022/src/lib/components/journal/journal.module.mjs +0 -18
- package/esm2022/src/lib/components/journal/public-api.mjs +0 -3
- package/esm2022/src/lib/components/journal/verben-workflow-ui-src-lib-components-journal.mjs +0 -5
- package/esm2022/src/lib/components/my-queue/index.mjs +0 -2
- package/esm2022/src/lib/components/my-queue/my-queue.columns.mjs +0 -34
- package/esm2022/src/lib/components/my-queue/my-queue.component.mjs +0 -342
- package/esm2022/src/lib/components/my-queue/my-queue.facade.mjs +0 -502
- package/esm2022/src/lib/components/my-queue/my-queue.module.mjs +0 -47
- package/esm2022/src/lib/components/my-queue/my-queue.service.mjs +0 -144
- package/esm2022/src/lib/components/my-queue/my-queue.state.mjs +0 -108
- package/esm2022/src/lib/components/my-queue/public-api.mjs +0 -4
- package/esm2022/src/lib/components/my-queue/tasks.form.component.mjs +0 -191
- package/esm2022/src/lib/components/my-queue/verben-workflow-ui-src-lib-components-my-queue.mjs +0 -5
- package/esm2022/src/lib/components/operation-popup/index.mjs +0 -2
- package/esm2022/src/lib/components/operation-popup/operation-popup.component.mjs +0 -382
- package/esm2022/src/lib/components/operation-popup/operation-popup.facade.mjs +0 -345
- package/esm2022/src/lib/components/operation-popup/operation-popup.service.mjs +0 -82
- package/esm2022/src/lib/components/operation-popup/operation-popup.state.mjs +0 -44
- package/esm2022/src/lib/components/operation-popup/public-api.mjs +0 -3
- package/esm2022/src/lib/components/operation-popup/verben-workflow-ui-src-lib-components-operation-popup.mjs +0 -5
- package/esm2022/src/lib/components/stage-details/index.mjs +0 -2
- package/esm2022/src/lib/components/stage-details/public-api.mjs +0 -3
- package/esm2022/src/lib/components/stage-details/stage-details.component.mjs +0 -49
- package/esm2022/src/lib/components/stage-details/stage-details.module.mjs +0 -19
- package/esm2022/src/lib/components/stage-details/verben-workflow-ui-src-lib-components-stage-details.mjs +0 -5
- package/esm2022/src/lib/components/task-form/index.mjs +0 -2
- package/esm2022/src/lib/components/task-form/public-api.mjs +0 -3
- package/esm2022/src/lib/components/task-form/task-form.component.mjs +0 -18
- package/esm2022/src/lib/components/task-form/task-form.module.mjs +0 -72
- package/esm2022/src/lib/components/task-form/verben-workflow-ui-src-lib-components-task-form.mjs +0 -5
- package/esm2022/src/lib/components/task-history/index.mjs +0 -2
- package/esm2022/src/lib/components/task-history/public-api.mjs +0 -3
- package/esm2022/src/lib/components/task-history/task-history.component.mjs +0 -249
- package/esm2022/src/lib/components/task-history/task-history.module.mjs +0 -21
- package/esm2022/src/lib/components/task-history/task-history.service.mjs +0 -32
- package/esm2022/src/lib/components/task-history/verben-workflow-ui-src-lib-components-task-history.mjs +0 -5
- package/esm2022/src/lib/components/task-notification/base-table-style.mjs +0 -53
- package/esm2022/src/lib/components/task-notification/index.mjs +0 -2
- package/esm2022/src/lib/components/task-notification/public-api.mjs +0 -3
- package/esm2022/src/lib/components/task-notification/task-notification.component.mjs +0 -670
- package/esm2022/src/lib/components/task-notification/task-notification.module.mjs +0 -18
- package/esm2022/src/lib/components/task-notification/task-notification.service.mjs +0 -256
- package/esm2022/src/lib/components/task-notification/verben-workflow-ui-src-lib-components-task-notification.mjs +0 -5
- package/esm2022/src/lib/components/tasks/index.mjs +0 -2
- package/esm2022/src/lib/components/tasks/public-api.mjs +0 -6
- package/esm2022/src/lib/components/tasks/tasks.columns.mjs +0 -48
- package/esm2022/src/lib/components/tasks/tasks.component.mjs +0 -194
- package/esm2022/src/lib/components/tasks/tasks.facade.mjs +0 -372
- package/esm2022/src/lib/components/tasks/tasks.form.component.mjs +0 -164
- package/esm2022/src/lib/components/tasks/tasks.models.mjs +0 -4
- package/esm2022/src/lib/components/tasks/tasks.module.mjs +0 -52
- package/esm2022/src/lib/components/tasks/tasks.service.mjs +0 -137
- package/esm2022/src/lib/components/tasks/tasks.state.mjs +0 -108
- package/esm2022/src/lib/components/tasks/verben-workflow-ui-src-lib-components-tasks.mjs +0 -5
- package/esm2022/src/lib/components/wf/index.mjs +0 -2
- package/esm2022/src/lib/components/wf/public-api.mjs +0 -4
- package/esm2022/src/lib/components/wf/verben-workflow-ui-src-lib-components-wf.mjs +0 -5
- package/esm2022/src/lib/components/wf/wf.columns.mjs +0 -34
- package/esm2022/src/lib/components/wf/wf.component.mjs +0 -68
- package/esm2022/src/lib/components/wf/wf.module.mjs +0 -22
- package/esm2022/src/lib/components/wf/wf.service.mjs +0 -82
- package/esm2022/src/lib/components/workflow/column.mjs +0 -38
- package/esm2022/src/lib/components/workflow/helper.mjs +0 -47
- package/esm2022/src/lib/components/workflow/index.mjs +0 -2
- package/esm2022/src/lib/components/workflow/public-api.mjs +0 -4
- package/esm2022/src/lib/components/workflow/table-style.mjs +0 -53
- package/esm2022/src/lib/components/workflow/verben-workflow-ui-src-lib-components-workflow.mjs +0 -5
- package/esm2022/src/lib/components/workflow/workflow.component.mjs +0 -210
- package/esm2022/src/lib/components/workflow/workflow.module.mjs +0 -19
- package/esm2022/src/lib/components/workflow-designer/action-dialog/action-dialog.component.mjs +0 -127
- package/esm2022/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.mjs +0 -78
- package/esm2022/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.mjs +0 -87
- package/esm2022/src/lib/components/workflow-designer/decision-popup/decision-popup.component.mjs +0 -84
- package/esm2022/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.mjs +0 -1270
- package/esm2022/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.mjs +0 -96
- package/esm2022/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.types.mjs +0 -2
- package/esm2022/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.mjs +0 -260
- package/esm2022/src/lib/components/workflow-designer/index.mjs +0 -2
- package/esm2022/src/lib/components/workflow-designer/public-api.mjs +0 -5
- package/esm2022/src/lib/components/workflow-designer/services/connection.service.mjs +0 -238
- package/esm2022/src/lib/components/workflow-designer/services/node-management.service.mjs +0 -321
- package/esm2022/src/lib/components/workflow-designer/services/popup.service.mjs +0 -240
- package/esm2022/src/lib/components/workflow-designer/services/swimlane.service.mjs +0 -158
- package/esm2022/src/lib/components/workflow-designer/services/transformer.service.mjs +0 -280
- package/esm2022/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.mjs +0 -177
- package/esm2022/src/lib/components/workflow-designer/stage-node/stage-node.component.mjs +0 -226
- package/esm2022/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.mjs +0 -137
- package/esm2022/src/lib/components/workflow-designer/verben-workflow-ui-src-lib-components-workflow-designer.mjs +0 -5
- package/esm2022/src/lib/components/workflow-designer/workflow-data.service.mjs +0 -210
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.component.mjs +0 -460
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.module.mjs +0 -129
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.state.mjs +0 -928
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.types.mjs +0 -2
- package/esm2022/src/lib/components/workflow-stage/index.mjs +0 -2
- package/esm2022/src/lib/components/workflow-stage/public-api.mjs +0 -3
- package/esm2022/src/lib/components/workflow-stage/verben-workflow-ui-src-lib-components-workflow-stage.mjs +0 -5
- package/esm2022/src/lib/components/workflow-stage/workflow-stage.component.mjs +0 -331
- package/esm2022/src/lib/components/workflow-stage/workflow-stage.module.mjs +0 -82
- package/esm2022/src/lib/components/workflows/index.mjs +0 -2
- package/esm2022/src/lib/components/workflows/public-api.mjs +0 -7
- package/esm2022/src/lib/components/workflows/verben-workflow-ui-src-lib-components-workflows.mjs +0 -5
- package/esm2022/src/lib/components/workflows/workflow-form/workflow-form.component.mjs +0 -89
- package/esm2022/src/lib/components/workflows/workflows.api.mjs +0 -63
- package/esm2022/src/lib/components/workflows/workflows.columns.mjs +0 -39
- package/esm2022/src/lib/components/workflows/workflows.component.mjs +0 -236
- package/esm2022/src/lib/components/workflows/workflows.config.mjs +0 -51
- package/esm2022/src/lib/components/workflows/workflows.facade.mjs +0 -114
- package/esm2022/src/lib/components/workflows/workflows.module.mjs +0 -21
- package/esm2022/src/lib/components/workflows/workflows.service.mjs +0 -63
- package/esm2022/src/lib/components/workflows/workflows.state.mjs +0 -23
- package/esm2022/src/lib/models/ActionHistory.mjs +0 -2
- package/esm2022/src/lib/models/ActionType.mjs +0 -11
- package/esm2022/src/lib/models/Actor.mjs +0 -2
- package/esm2022/src/lib/models/ActorTag.mjs +0 -2
- package/esm2022/src/lib/models/Coord.mjs +0 -2
- package/esm2022/src/lib/models/DataType.mjs +0 -27
- package/esm2022/src/lib/models/EAVEntity.mjs +0 -2
- package/esm2022/src/lib/models/ErrorResponse.mjs +0 -11
- package/esm2022/src/lib/models/Escalation.mjs +0 -2
- package/esm2022/src/lib/models/EscalationCycle.mjs +0 -2
- package/esm2022/src/lib/models/EscalationStage.mjs +0 -2
- package/esm2022/src/lib/models/EscalationType.mjs +0 -7
- package/esm2022/src/lib/models/File.mjs +0 -2
- package/esm2022/src/lib/models/FilterTypes.mjs +0 -9
- package/esm2022/src/lib/models/FlowableStatus.mjs +0 -2
- package/esm2022/src/lib/models/Form.mjs +0 -2
- package/esm2022/src/lib/models/FormEntity.mjs +0 -2
- package/esm2022/src/lib/models/FormFill.mjs +0 -6
- package/esm2022/src/lib/models/FormProperty.mjs +0 -2
- package/esm2022/src/lib/models/FormValues.mjs +0 -2
- package/esm2022/src/lib/models/MailConfig.mjs +0 -2
- package/esm2022/src/lib/models/MessageConfig.mjs +0 -2
- package/esm2022/src/lib/models/MessageMedium.mjs +0 -6
- package/esm2022/src/lib/models/OperationAction.mjs +0 -2
- package/esm2022/src/lib/models/PagedResult.mjs +0 -2
- package/esm2022/src/lib/models/PeriodMode.mjs +0 -12
- package/esm2022/src/lib/models/PermissionConfig.mjs +0 -2
- package/esm2022/src/lib/models/ReportSchedule.mjs +0 -2
- package/esm2022/src/lib/models/ReportType.mjs +0 -7
- package/esm2022/src/lib/models/Resource.mjs +0 -47
- package/esm2022/src/lib/models/ResponseKeyValue.mjs +0 -2
- package/esm2022/src/lib/models/SMSConfig.mjs +0 -2
- package/esm2022/src/lib/models/SearchDynamicWrapper.mjs +0 -2
- package/esm2022/src/lib/models/SearchOperator.mjs +0 -6
- package/esm2022/src/lib/models/SearchPropertySign.mjs +0 -11
- package/esm2022/src/lib/models/SearchPropertyValue.mjs +0 -2
- package/esm2022/src/lib/models/SearchPropertyValueType.mjs +0 -11
- package/esm2022/src/lib/models/Size.mjs +0 -2
- package/esm2022/src/lib/models/SortDirection.mjs +0 -7
- package/esm2022/src/lib/models/StageActorRule.mjs +0 -8
- package/esm2022/src/lib/models/SwimLane.mjs +0 -2
- package/esm2022/src/lib/models/Tag.mjs +0 -2
- package/esm2022/src/lib/models/Task.mjs +0 -2
- package/esm2022/src/lib/models/TaskAssignmentType.mjs +0 -6
- package/esm2022/src/lib/models/TaskNotification.mjs +0 -2
- package/esm2022/src/lib/models/TaskNotificationMessageType.mjs +0 -6
- package/esm2022/src/lib/models/TaskNotificationType.mjs +0 -9
- package/esm2022/src/lib/models/TaskStatus.mjs +0 -9
- package/esm2022/src/lib/models/Workflow.mjs +0 -2
- package/esm2022/src/lib/models/WorkflowAction.mjs +0 -2
- package/esm2022/src/lib/models/WorkflowOperation.mjs +0 -2
- package/esm2022/src/lib/models/WorkflowStage.mjs +0 -2
- package/esm2022/src/lib/models/actors.mjs +0 -2
- package/esm2022/src/lib/models/auth-mechanism.mjs +0 -8
- package/esm2022/src/lib/models/base.mjs +0 -2
- package/esm2022/src/lib/models/index.mjs +0 -2
- package/esm2022/src/lib/models/object-state.mjs +0 -8
- package/esm2022/src/lib/models/operation-type.mjs +0 -7
- package/esm2022/src/lib/models/paged.mjs +0 -2
- package/esm2022/src/lib/models/public-api.mjs +0 -64
- package/esm2022/src/lib/models/query-params.mjs +0 -2
- package/esm2022/src/lib/models/status.mjs +0 -6
- package/esm2022/src/lib/models/task-history.mjs +0 -2
- package/esm2022/src/lib/models/user-access-request-status.mjs +0 -7
- package/esm2022/src/lib/models/user.mjs +0 -2
- package/esm2022/src/lib/models/verben-workflow-ui-src-lib-models.mjs +0 -5
- package/esm2022/src/lib/pipes/async-label.pipe.mjs +0 -25
- package/esm2022/src/lib/pipes/index.mjs +0 -2
- package/esm2022/src/lib/pipes/public-api.mjs +0 -2
- package/esm2022/src/lib/pipes/verben-workflow-ui-src-lib-pipes.mjs +0 -5
- package/esm2022/src/lib/services/environment.service.mjs +0 -26
- package/esm2022/src/lib/services/http-web-request.service.mjs +0 -92
- package/esm2022/src/lib/services/index.mjs +0 -2
- package/esm2022/src/lib/services/label.service.mjs +0 -134
- package/esm2022/src/lib/services/public-api.mjs +0 -5
- package/esm2022/src/lib/services/util.service.mjs +0 -75
- package/esm2022/src/lib/services/verben-workflow-ui-src-lib-services.mjs +0 -5
- package/esm2022/src/lib/shared/base-table-style.mjs +0 -55
- package/esm2022/src/lib/shared/components/base-data-view.component.mjs +0 -154
- package/esm2022/src/lib/shared/components/base-model-field.mjs +0 -21
- package/esm2022/src/lib/shared/index.mjs +0 -7
- package/esm2022/src/lib/shared/models/DataViewConfig.mjs +0 -2
- package/esm2022/src/lib/shared/public-api.mjs +0 -13
- package/esm2022/src/lib/shared/shared.module.mjs +0 -103
- package/esm2022/src/lib/shared/verben-workflow-ui-src-lib-shared.mjs +0 -5
- package/esm2022/verben-workflow-ui.mjs +0 -5
- package/fesm2022/verben-workflow-ui-src-lib-base.mjs +0 -1055
- package/fesm2022/verben-workflow-ui-src-lib-base.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-actors.mjs +0 -484
- package/fesm2022/verben-workflow-ui-src-lib-components-actors.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-designer.mjs +0 -3891
- package/fesm2022/verben-workflow-ui-src-lib-components-designer.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-expiration.mjs +0 -72
- package/fesm2022/verben-workflow-ui-src-lib-components-expiration.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-file-render.mjs +0 -83
- package/fesm2022/verben-workflow-ui-src-lib-components-file-render.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-file-upload.mjs +0 -159
- package/fesm2022/verben-workflow-ui-src-lib-components-file-upload.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-flowable-status.mjs +0 -430
- package/fesm2022/verben-workflow-ui-src-lib-components-flowable-status.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-form-control.mjs +0 -257
- package/fesm2022/verben-workflow-ui-src-lib-components-form-control.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-form-group.mjs +0 -1967
- package/fesm2022/verben-workflow-ui-src-lib-components-form-group.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-form-response.mjs +0 -769
- package/fesm2022/verben-workflow-ui-src-lib-components-form-response.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-form-timer.mjs +0 -78
- package/fesm2022/verben-workflow-ui-src-lib-components-form-timer.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-form-viewer.mjs +0 -118
- package/fesm2022/verben-workflow-ui-src-lib-components-form-viewer.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-forms.mjs +0 -812
- package/fesm2022/verben-workflow-ui-src-lib-components-forms.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-journal.mjs +0 -33
- package/fesm2022/verben-workflow-ui-src-lib-components-journal.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-my-queue.mjs +0 -1338
- package/fesm2022/verben-workflow-ui-src-lib-components-my-queue.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-operation-popup.mjs +0 -845
- package/fesm2022/verben-workflow-ui-src-lib-components-operation-popup.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-stage-details.mjs +0 -72
- package/fesm2022/verben-workflow-ui-src-lib-components-stage-details.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-task-form.mjs +0 -94
- package/fesm2022/verben-workflow-ui-src-lib-components-task-form.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-task-history.mjs +0 -302
- package/fesm2022/verben-workflow-ui-src-lib-components-task-history.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-task-notification.mjs +0 -995
- package/fesm2022/verben-workflow-ui-src-lib-components-task-notification.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-tasks.mjs +0 -1049
- package/fesm2022/verben-workflow-ui-src-lib-components-tasks.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-wf.mjs +0 -203
- package/fesm2022/verben-workflow-ui-src-lib-components-wf.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-designer.mjs +0 -5389
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-designer.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-stage.mjs +0 -415
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-stage.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow.mjs +0 -365
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-components-workflows.mjs +0 -666
- package/fesm2022/verben-workflow-ui-src-lib-components-workflows.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-models.mjs +0 -256
- package/fesm2022/verben-workflow-ui-src-lib-models.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-pipes.mjs +0 -32
- package/fesm2022/verben-workflow-ui-src-lib-pipes.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-services.mjs +0 -322
- package/fesm2022/verben-workflow-ui-src-lib-services.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui-src-lib-shared.mjs +0 -336
- package/fesm2022/verben-workflow-ui-src-lib-shared.mjs.map +0 -1
- package/fesm2022/verben-workflow-ui.mjs +0 -34
- package/fesm2022/verben-workflow-ui.mjs.map +0 -1
- package/index.d.ts +0 -5
- package/public-api.d.ts +0 -22
- package/src/lib/base/core/base-data-page.facade.d.ts +0 -138
- package/src/lib/base/core/base-data-page.service.d.ts +0 -61
- package/src/lib/base/core/base-data-page.state.d.ts +0 -73
- package/src/lib/base/handlers/filter-handler.service.d.ts +0 -34
- package/src/lib/base/handlers/search-handler.service.d.ts +0 -20
- package/src/lib/base/handlers/sort-handler.service.d.ts +0 -30
- package/src/lib/base/models/api-payload.d.ts +0 -2
- package/src/lib/base/models/page-config.interface.d.ts +0 -24
- package/src/lib/base/models/page-filter-tab-option.interface.d.ts +0 -19
- package/src/lib/base/public-api.d.ts +0 -9
- package/src/lib/base/utils/column-helpers.d.ts +0 -24
- package/src/lib/components/actors/actors.columns.d.ts +0 -3
- package/src/lib/components/actors/actors.component.d.ts +0 -79
- package/src/lib/components/actors/actors.config.d.ts +0 -10
- package/src/lib/components/actors/actors.facade.d.ts +0 -29
- package/src/lib/components/actors/actors.form.component.d.ts +0 -23
- package/src/lib/components/actors/actors.module.d.ts +0 -11
- package/src/lib/components/actors/actors.service.d.ts +0 -33
- package/src/lib/components/actors/actors.state.d.ts +0 -19
- package/src/lib/components/designer/components/label-editor.component.d.ts +0 -22
- package/src/lib/components/designer/components/node-selector.component.d.ts +0 -23
- package/src/lib/components/designer/components/swimlane-label.component.d.ts +0 -12
- package/src/lib/components/designer/components/swimlane-popup.component.d.ts +0 -18
- package/src/lib/components/designer/components/wf-canvas.component.d.ts +0 -37
- package/src/lib/components/designer/components/wf-designer.component.d.ts +0 -22
- package/src/lib/components/designer/components/wf-toolbar.component.d.ts +0 -17
- package/src/lib/components/designer/models/types.d.ts +0 -104
- package/src/lib/components/designer/services/canvas-state.service.d.ts +0 -24
- package/src/lib/components/designer/services/connection-segment-interaction.service.d.ts +0 -36
- package/src/lib/components/designer/services/connection.service.d.ts +0 -47
- package/src/lib/components/designer/services/keyboard-handler.service.d.ts +0 -9
- package/src/lib/components/designer/services/label-management.service.d.ts +0 -14
- package/src/lib/components/designer/services/node-finder.service.d.ts +0 -10
- package/src/lib/components/designer/services/node-interaction.service.d.ts +0 -19
- package/src/lib/components/designer/services/node-precondition.service.d.ts +0 -37
- package/src/lib/components/designer/services/node-selection.service.d.ts +0 -19
- package/src/lib/components/designer/services/orthogonal-router.service.d.ts +0 -36
- package/src/lib/components/designer/services/position-update.service.d.ts +0 -10
- package/src/lib/components/designer/services/rendering.service.d.ts +0 -67
- package/src/lib/components/designer/services/swimlane-management.service.d.ts +0 -19
- package/src/lib/components/designer/services/swimlane-stats.service.d.ts +0 -19
- package/src/lib/components/designer/services/viewport.service.d.ts +0 -10
- package/src/lib/components/designer/services/wf-facade.service.d.ts +0 -67
- package/src/lib/components/designer/services/wf-mapper.service.d.ts +0 -26
- package/src/lib/components/designer/services/wf-persistence.service.d.ts +0 -21
- package/src/lib/components/designer/services/wf-state.service.d.ts +0 -30
- package/src/lib/components/expiration/expiration.component.d.ts +0 -20
- package/src/lib/components/expiration/expiration.module.d.ts +0 -9
- package/src/lib/components/file-render/file-render.component.d.ts +0 -17
- package/src/lib/components/file-render/file-render.module.d.ts +0 -10
- package/src/lib/components/file-upload/file-upload.component.d.ts +0 -22
- package/src/lib/components/file-upload/file-upload.module.d.ts +0 -11
- package/src/lib/components/flowable-status/flowable-status.columns.d.ts +0 -3
- package/src/lib/components/flowable-status/flowable-status.component.d.ts +0 -80
- package/src/lib/components/flowable-status/flowable-status.config.d.ts +0 -11
- package/src/lib/components/flowable-status/flowable-status.facade.d.ts +0 -26
- package/src/lib/components/flowable-status/flowable-status.form.component.d.ts +0 -18
- package/src/lib/components/flowable-status/flowable-status.module.d.ts +0 -11
- package/src/lib/components/flowable-status/flowable-status.service.d.ts +0 -23
- package/src/lib/components/flowable-status/flowable-status.state.d.ts +0 -11
- package/src/lib/components/flowable-status/public-api.d.ts +0 -2
- package/src/lib/components/form-control/form-control.component.d.ts +0 -39
- package/src/lib/components/form-control/form-control.module.d.ts +0 -11
- package/src/lib/components/form-group/base-table-style.d.ts +0 -1
- package/src/lib/components/form-group/form-fields/form-fields.component.d.ts +0 -136
- package/src/lib/components/form-group/form-fields/form-fields.module.d.ts +0 -11
- package/src/lib/components/form-group/form-fields/form-fields.service.d.ts +0 -9
- package/src/lib/components/form-group/form-group.component.d.ts +0 -108
- package/src/lib/components/form-group/form-group.module.d.ts +0 -15
- package/src/lib/components/form-group/form-group.service.d.ts +0 -9
- package/src/lib/components/form-response/form-response.component.d.ts +0 -108
- package/src/lib/components/form-response/form-response.module.d.ts +0 -12
- package/src/lib/components/form-response/form-response.service.d.ts +0 -9
- package/src/lib/components/form-timer/form-timer.component.d.ts +0 -13
- package/src/lib/components/form-timer/form-timer.module.d.ts +0 -9
- package/src/lib/components/form-viewer/form-viewer.component.d.ts +0 -17
- package/src/lib/components/form-viewer/form-viewer.module.d.ts +0 -11
- package/src/lib/components/forms/base-table-style.d.ts +0 -1
- package/src/lib/components/forms/forms.component.d.ts +0 -88
- package/src/lib/components/forms/forms.module.d.ts +0 -8
- package/src/lib/components/forms/forms.service.d.ts +0 -9
- package/src/lib/components/journal/journal.component.d.ts +0 -5
- package/src/lib/components/journal/journal.module.d.ts +0 -8
- package/src/lib/components/my-queue/my-queue.columns.d.ts +0 -3
- package/src/lib/components/my-queue/my-queue.component.d.ts +0 -58
- package/src/lib/components/my-queue/my-queue.facade.d.ts +0 -47
- package/src/lib/components/my-queue/my-queue.module.d.ts +0 -15
- package/src/lib/components/my-queue/my-queue.service.d.ts +0 -65
- package/src/lib/components/my-queue/my-queue.state.d.ts +0 -39
- package/src/lib/components/my-queue/tasks.form.component.d.ts +0 -48
- package/src/lib/components/operation-popup/operation-popup.component.d.ts +0 -62
- package/src/lib/components/operation-popup/operation-popup.facade.d.ts +0 -32
- package/src/lib/components/operation-popup/operation-popup.service.d.ts +0 -23
- package/src/lib/components/operation-popup/operation-popup.state.d.ts +0 -20
- package/src/lib/components/stage-details/stage-details.component.d.ts +0 -24
- package/src/lib/components/stage-details/stage-details.module.d.ts +0 -9
- package/src/lib/components/task-form/task-form.component.d.ts +0 -10
- package/src/lib/components/task-form/task-form.module.d.ts +0 -10
- package/src/lib/components/task-history/task-history.component.d.ts +0 -41
- package/src/lib/components/task-history/task-history.module.d.ts +0 -11
- package/src/lib/components/task-history/task-history.service.d.ts +0 -13
- package/src/lib/components/task-notification/base-table-style.d.ts +0 -1
- package/src/lib/components/task-notification/task-notification.component.d.ts +0 -89
- package/src/lib/components/task-notification/task-notification.module.d.ts +0 -8
- package/src/lib/components/task-notification/task-notification.service.d.ts +0 -32
- package/src/lib/components/tasks/tasks.columns.d.ts +0 -11
- package/src/lib/components/tasks/tasks.component.d.ts +0 -40
- package/src/lib/components/tasks/tasks.facade.d.ts +0 -44
- package/src/lib/components/tasks/tasks.form.component.d.ts +0 -40
- package/src/lib/components/tasks/tasks.models.d.ts +0 -4
- package/src/lib/components/tasks/tasks.module.d.ts +0 -17
- package/src/lib/components/tasks/tasks.service.d.ts +0 -58
- package/src/lib/components/tasks/tasks.state.d.ts +0 -46
- package/src/lib/components/wf/wf.columns.d.ts +0 -3
- package/src/lib/components/wf/wf.component.d.ts +0 -16
- package/src/lib/components/wf/wf.module.d.ts +0 -10
- package/src/lib/components/wf/wf.service.d.ts +0 -51
- package/src/lib/components/workflow/column.d.ts +0 -3
- package/src/lib/components/workflow/helper.d.ts +0 -2
- package/src/lib/components/workflow/table-style.d.ts +0 -1
- package/src/lib/components/workflow/workflow.component.d.ts +0 -57
- package/src/lib/components/workflow/workflow.module.d.ts +0 -9
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.d.ts +0 -34
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.d.ts +0 -25
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.d.ts +0 -38
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.d.ts +0 -29
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.d.ts +0 -292
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.d.ts +0 -39
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.types.d.ts +0 -5
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.d.ts +0 -47
- package/src/lib/components/workflow-designer/services/connection.service.d.ts +0 -101
- package/src/lib/components/workflow-designer/services/node-management.service.d.ts +0 -73
- package/src/lib/components/workflow-designer/services/popup.service.d.ts +0 -147
- package/src/lib/components/workflow-designer/services/swimlane.service.d.ts +0 -66
- package/src/lib/components/workflow-designer/services/transformer.service.d.ts +0 -51
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.d.ts +0 -43
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.d.ts +0 -58
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.d.ts +0 -49
- package/src/lib/components/workflow-designer/workflow-data.service.d.ts +0 -59
- package/src/lib/components/workflow-designer/workflow-designer.component.d.ts +0 -121
- package/src/lib/components/workflow-designer/workflow-designer.module.d.ts +0 -41
- package/src/lib/components/workflow-designer/workflow-designer.state.d.ts +0 -278
- package/src/lib/components/workflow-designer/workflow-designer.types.d.ts +0 -130
- package/src/lib/components/workflow-stage/workflow-stage.component.d.ts +0 -78
- package/src/lib/components/workflow-stage/workflow-stage.module.d.ts +0 -12
- package/src/lib/components/workflows/public-api.d.ts +0 -4
- package/src/lib/components/workflows/workflow-form/workflow-form.component.d.ts +0 -28
- package/src/lib/components/workflows/workflows.api.d.ts +0 -38
- package/src/lib/components/workflows/workflows.columns.d.ts +0 -3
- package/src/lib/components/workflows/workflows.component.d.ts +0 -98
- package/src/lib/components/workflows/workflows.config.d.ts +0 -10
- package/src/lib/components/workflows/workflows.facade.d.ts +0 -41
- package/src/lib/components/workflows/workflows.module.d.ts +0 -11
- package/src/lib/components/workflows/workflows.service.d.ts +0 -32
- package/src/lib/components/workflows/workflows.state.d.ts +0 -15
- package/src/lib/models/ActionHistory.d.ts +0 -16
- package/src/lib/models/ActionType.d.ts +0 -9
- package/src/lib/models/Actor.d.ts +0 -11
- package/src/lib/models/ActorTag.d.ts +0 -6
- package/src/lib/models/Coord.d.ts +0 -4
- package/src/lib/models/DataType.d.ts +0 -25
- package/src/lib/models/EAVEntity.d.ts +0 -4
- package/src/lib/models/ErrorResponse.d.ts +0 -6
- package/src/lib/models/Escalation.d.ts +0 -14
- package/src/lib/models/EscalationCycle.d.ts +0 -12
- package/src/lib/models/EscalationStage.d.ts +0 -10
- package/src/lib/models/EscalationType.d.ts +0 -5
- package/src/lib/models/File.d.ts +0 -7
- package/src/lib/models/FilterTypes.d.ts +0 -6
- package/src/lib/models/FlowableStatus.d.ts +0 -5
- package/src/lib/models/Form.d.ts +0 -13
- package/src/lib/models/FormEntity.d.ts +0 -13
- package/src/lib/models/FormFill.d.ts +0 -15
- package/src/lib/models/FormProperty.d.ts +0 -15
- package/src/lib/models/FormValues.d.ts +0 -14
- package/src/lib/models/MailConfig.d.ts +0 -12
- package/src/lib/models/MessageConfig.d.ts +0 -3
- package/src/lib/models/MessageMedium.d.ts +0 -4
- package/src/lib/models/OperationAction.d.ts +0 -14
- package/src/lib/models/PagedResult.d.ts +0 -5
- package/src/lib/models/PeriodMode.d.ts +0 -10
- package/src/lib/models/PermissionConfig.d.ts +0 -7
- package/src/lib/models/ReportSchedule.d.ts +0 -22
- package/src/lib/models/ReportType.d.ts +0 -5
- package/src/lib/models/Resource.d.ts +0 -20
- package/src/lib/models/ResponseKeyValue.d.ts +0 -5
- package/src/lib/models/SMSConfig.d.ts +0 -10
- package/src/lib/models/SearchDynamicWrapper.d.ts +0 -5
- package/src/lib/models/SearchOperator.d.ts +0 -4
- package/src/lib/models/SearchPropertySign.d.ts +0 -9
- package/src/lib/models/SearchPropertyValue.d.ts +0 -12
- package/src/lib/models/SearchPropertyValueType.d.ts +0 -9
- package/src/lib/models/Size.d.ts +0 -4
- package/src/lib/models/SortDirection.d.ts +0 -5
- package/src/lib/models/StageActorRule.d.ts +0 -6
- package/src/lib/models/SwimLane.d.ts +0 -13
- package/src/lib/models/Tag.d.ts +0 -6
- package/src/lib/models/Task.d.ts +0 -32
- package/src/lib/models/TaskAssignmentType.d.ts +0 -4
- package/src/lib/models/TaskNotification.d.ts +0 -14
- package/src/lib/models/TaskNotificationMessageType.d.ts +0 -4
- package/src/lib/models/TaskNotificationType.d.ts +0 -7
- package/src/lib/models/TaskStatus.d.ts +0 -7
- package/src/lib/models/Workflow.d.ts +0 -21
- package/src/lib/models/WorkflowAction.d.ts +0 -14
- package/src/lib/models/WorkflowOperation.d.ts +0 -6
- package/src/lib/models/WorkflowStage.d.ts +0 -26
- package/src/lib/models/actors.d.ts +0 -8
- package/src/lib/models/auth-mechanism.d.ts +0 -13
- package/src/lib/models/base.d.ts +0 -13
- package/src/lib/models/object-state.d.ts +0 -6
- package/src/lib/models/operation-type.d.ts +0 -5
- package/src/lib/models/paged.d.ts +0 -9
- package/src/lib/models/public-api.d.ts +0 -63
- package/src/lib/models/query-params.d.ts +0 -8
- package/src/lib/models/status.d.ts +0 -4
- package/src/lib/models/task-history.d.ts +0 -17
- package/src/lib/models/user-access-request-status.d.ts +0 -5
- package/src/lib/models/user.d.ts +0 -24
- package/src/lib/pipes/async-label.pipe.d.ts +0 -11
- package/src/lib/services/environment.service.d.ts +0 -23
- package/src/lib/services/http-web-request.service.d.ts +0 -23
- package/src/lib/services/label.service.d.ts +0 -15
- package/src/lib/services/public-api.d.ts +0 -4
- package/src/lib/services/util.service.d.ts +0 -20
- package/src/lib/shared/base-table-style.d.ts +0 -2
- package/src/lib/shared/components/base-data-view.component.d.ts +0 -41
- package/src/lib/shared/components/base-model-field.d.ts +0 -26
- package/src/lib/shared/models/DataViewConfig.d.ts +0 -11
- package/src/lib/shared/public-api.d.ts +0 -5
- package/src/lib/shared/shared.module.d.ts +0 -11
- /package/src/lib/base/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/actors/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/actors/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/designer/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/designer/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/expiration/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/expiration/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/file-render/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/file-render/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/file-upload/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/file-upload/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/flowable-status/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/form-control/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/form-control/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/form-group/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/form-group/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/form-response/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/form-response/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/form-timer/{index.d.ts → index.ts} +0 -0
- /package/src/lib/components/form-timer/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{form-viewer/index.d.ts → form-values/index.ts} +0 -0
- /package/src/lib/components/{forms/index.d.ts → form-viewer/index.ts} +0 -0
- /package/src/lib/components/form-viewer/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{journal/index.d.ts → forms/index.ts} +0 -0
- /package/src/lib/components/forms/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{my-queue/index.d.ts → journal/index.ts} +0 -0
- /package/src/lib/components/journal/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{operation-popup/index.d.ts → my-queue/index.ts} +0 -0
- /package/src/lib/components/my-queue/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{stage-details/index.d.ts → operation-popup/index.ts} +0 -0
- /package/src/lib/components/operation-popup/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{task-form/index.d.ts → stage-details/index.ts} +0 -0
- /package/src/lib/components/stage-details/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{task-history/index.d.ts → task-form/index.ts} +0 -0
- /package/src/lib/components/task-form/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{task-notification/index.d.ts → task-history/index.ts} +0 -0
- /package/src/lib/components/task-history/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{tasks/index.d.ts → task-notification/index.ts} +0 -0
- /package/src/lib/components/task-notification/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{wf/index.d.ts → tasks/index.ts} +0 -0
- /package/src/lib/components/tasks/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{workflow-designer/index.d.ts → wf/index.ts} +0 -0
- /package/src/lib/components/wf/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{workflows/index.d.ts → workflow/index.ts} +0 -0
- /package/src/lib/components/workflow/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{workflow-stage/index.d.ts → workflow-designer/index.ts} +0 -0
- /package/src/lib/components/workflow-designer/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/components/{workflow/index.d.ts → workflow-stage/index.ts} +0 -0
- /package/src/lib/components/workflow-stage/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/{models/index.d.ts → components/workflows/index.ts} +0 -0
- /package/src/lib/{pipes/index.d.ts → models/index.ts} +0 -0
- /package/src/lib/{services/index.d.ts → pipes/index.ts} +0 -0
- /package/src/lib/pipes/{public-api.d.ts → public-api.ts} +0 -0
- /package/src/lib/shared/{index.d.ts → index.ts} +0 -0
- /package/{styles → src/styles}/styles.css +0 -0
|
@@ -0,0 +1,1123 @@
|
|
|
1
|
+
import { Injectable } from '@angular/core';
|
|
2
|
+
import {
|
|
3
|
+
ObjectState,
|
|
4
|
+
StageActorRule,
|
|
5
|
+
Status,
|
|
6
|
+
SwimLane,
|
|
7
|
+
Tag,
|
|
8
|
+
TaskAssignmentType,
|
|
9
|
+
Workflow,
|
|
10
|
+
WorkflowAction,
|
|
11
|
+
WorkflowStage,
|
|
12
|
+
} from 'verben-workflow-ui/src/lib/models';
|
|
13
|
+
import {
|
|
14
|
+
Connection,
|
|
15
|
+
ConnectionPoint,
|
|
16
|
+
Node,
|
|
17
|
+
SwimlaneItem,
|
|
18
|
+
ToolType,
|
|
19
|
+
} from './workflow-designer.types';
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* The designer's single source of truth — and, in practice, its domain-logic
|
|
23
|
+
* god object. Holds the entire editing model plus most of the behaviour that
|
|
24
|
+
* operates on it: node placement, connection creation and routing, connection
|
|
25
|
+
* rules, swimlane management, and the whole save-time transform.
|
|
26
|
+
*
|
|
27
|
+
* ## How mutation works here
|
|
28
|
+
*
|
|
29
|
+
* This is a `providedIn: 'root'` singleton injected **by reference** into every
|
|
30
|
+
* component that touches the model. Components mutate its arrays directly
|
|
31
|
+
* (`state.connections.push(...)`) — there is no store, reducer, or action
|
|
32
|
+
* indirection. Change detection works because templates iterate
|
|
33
|
+
* `state.swimlanes` / `state.connections` with `@for`.
|
|
34
|
+
*
|
|
35
|
+
* The one deliberate exception is {@link moveNodeToSwimlane}, which reassigns
|
|
36
|
+
* arrays immutably so `@for` re-renders **both** the source and target lanes.
|
|
37
|
+
* In-place mutation is fine everywhere else, but not across two lanes at once.
|
|
38
|
+
*
|
|
39
|
+
* ## Before you change this class
|
|
40
|
+
*
|
|
41
|
+
* A parallel implementation exists under `services/` (`NodeManagementService`,
|
|
42
|
+
* `ConnectionService`, `TransformerService`, ...) that duplicates much of this
|
|
43
|
+
* logic. It is only partially wired in, and the copies have **drifted** — the
|
|
44
|
+
* two disagree on node placement offsets, connection endpoint offsets, and
|
|
45
|
+
* which node types may connect. This class is the live path; the services are
|
|
46
|
+
* mostly not. Change this one.
|
|
47
|
+
*
|
|
48
|
+
* @see ./docs/01-architecture.md — the split-brain problem in full
|
|
49
|
+
* @see ./docs/02-coordinate-system.md — read before touching any coordinate math
|
|
50
|
+
* @see ./docs/06-known-issues.md — the catalogued divergences
|
|
51
|
+
*/
|
|
52
|
+
@Injectable({
|
|
53
|
+
providedIn: 'root',
|
|
54
|
+
})
|
|
55
|
+
export class WorkflowDesignerState {
|
|
56
|
+
/** Ordered lanes. Each owns its own nodes; there is no flat node list. */
|
|
57
|
+
swimlanes: SwimlaneItem[] = [];
|
|
58
|
+
/** Id of the workflow's entry-point node. */
|
|
59
|
+
startNodeId: string | null = null;
|
|
60
|
+
/** All edges, flat across lanes. */
|
|
61
|
+
connections: Connection[] = [];
|
|
62
|
+
draggingConnectionData: {
|
|
63
|
+
sourcePoint?: ConnectionPoint;
|
|
64
|
+
sourceSwimlaneIndex?: number;
|
|
65
|
+
startX?: number;
|
|
66
|
+
startY?: number;
|
|
67
|
+
currentX?: number;
|
|
68
|
+
currentY?: number;
|
|
69
|
+
} = {};
|
|
70
|
+
workflowFormId: string | null = null;
|
|
71
|
+
workflowFormName: string | null = null;
|
|
72
|
+
workflowId: string | null = null;
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* The workflow exactly as loaded from the API.
|
|
76
|
+
*
|
|
77
|
+
* This and the three `*Record` maps below are kept so that save can tell new
|
|
78
|
+
* objects from changed ones and emit the correct `ObjectState`. Losing them
|
|
79
|
+
* makes every entity look new on the next save.
|
|
80
|
+
*/
|
|
81
|
+
workflow: Workflow | null = null;
|
|
82
|
+
/** Originally-loaded lanes, keyed by id. */
|
|
83
|
+
swimlaneRecord: Record<string, SwimLane> = {};
|
|
84
|
+
/** Originally-loaded stages, keyed by id. */
|
|
85
|
+
stageRecord: Record<string, WorkflowStage> = {};
|
|
86
|
+
/** Originally-loaded actions, keyed by id. */
|
|
87
|
+
actionRecord: Record<string, WorkflowAction> = {};
|
|
88
|
+
|
|
89
|
+
setWorkflowId(id: string): void {
|
|
90
|
+
this.workflowId = id;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
public laneIdToIndexMap: Map<string, number> = new Map();
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Which node types each source type may connect to. Consulted by
|
|
97
|
+
* {@link canConnect} and {@link getAllowedTargetNodeTypes}.
|
|
98
|
+
*
|
|
99
|
+
* Forms are terminal sinks — they accept incoming edges but have no outgoing
|
|
100
|
+
* ones, which is why `form` maps to an empty list.
|
|
101
|
+
*
|
|
102
|
+
* ⚠️ `ConnectionService` holds a **different** copy of this table that also
|
|
103
|
+
* allows `stage → form`. The two have drifted; this one is the live path.
|
|
104
|
+
* See `./docs/06-known-issues.md` section A.
|
|
105
|
+
*/
|
|
106
|
+
private readonly connectionRules: Record<string, string[]> = {
|
|
107
|
+
stage: ['stage', 'decision', 'subflow'],
|
|
108
|
+
decision: ['stage'], // Decisions can only connect to Stages
|
|
109
|
+
// 'action': ['stage', 'form', 'decision'],
|
|
110
|
+
form: [],
|
|
111
|
+
subflow: ['stage', 'decision'],
|
|
112
|
+
};
|
|
113
|
+
|
|
114
|
+
setWorkflowForm(formId: string | null, formName: string | null): void {
|
|
115
|
+
this.workflowFormId = formId;
|
|
116
|
+
this.workflowFormName = formName;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
addSwimlane(name: string, tags: Tag[]) {
|
|
120
|
+
// Generate a unique key for this swimlane
|
|
121
|
+
const swimlaneKey = `lane-${Date.now()}-${Math.floor(
|
|
122
|
+
Math.random() * 1000,
|
|
123
|
+
)}`;
|
|
124
|
+
|
|
125
|
+
this.swimlanes = this.swimlanes.concat([
|
|
126
|
+
{
|
|
127
|
+
order: this.swimlanes.length,
|
|
128
|
+
label: name,
|
|
129
|
+
tags,
|
|
130
|
+
nodes: [],
|
|
131
|
+
id: swimlaneKey, // Store the generated key as id for frontend reference
|
|
132
|
+
},
|
|
133
|
+
]);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
registerLaneMapping(laneId: string, swimlaneIndex: number): void {
|
|
137
|
+
this.laneIdToIndexMap.set(laneId, swimlaneIndex);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* Builds the attachment points for a node, laid out to match its rendered
|
|
142
|
+
* shape. Returned coordinates are **relative to the node's own origin**.
|
|
143
|
+
*
|
|
144
|
+
* Layout per type:
|
|
145
|
+
* - **stage** — points every 50px along all four edges.
|
|
146
|
+
* - **decision** — one point at each of the diamond's four edge midpoints.
|
|
147
|
+
* - **form** — `left` (input) points only; forms are terminal sinks.
|
|
148
|
+
* - **subflow** — top, bottom, and two points on each of left and right.
|
|
149
|
+
*
|
|
150
|
+
* Regenerate these whenever a node's size or type changes, or connections
|
|
151
|
+
* will reference point ids that no longer exist.
|
|
152
|
+
*/
|
|
153
|
+
generateConnectionPoints(node: Node): ConnectionPoint[] {
|
|
154
|
+
const points: ConnectionPoint[] = [];
|
|
155
|
+
const spacing = 50; // Space between connection points
|
|
156
|
+
|
|
157
|
+
if (node.type === 'stage') {
|
|
158
|
+
// Rectangular shapes - add points around the rectangle
|
|
159
|
+
|
|
160
|
+
// Top edge points
|
|
161
|
+
for (let x = spacing; x < node.width; x += spacing) {
|
|
162
|
+
points.push({
|
|
163
|
+
id: `${node.id}-top-${x}`,
|
|
164
|
+
nodeId: node.id,
|
|
165
|
+
x: x,
|
|
166
|
+
y: 0,
|
|
167
|
+
type: 'top',
|
|
168
|
+
});
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
// Right edge points
|
|
172
|
+
for (let y = spacing; y < node.height; y += spacing) {
|
|
173
|
+
points.push({
|
|
174
|
+
id: `${node.id}-right-${y}`,
|
|
175
|
+
nodeId: node.id,
|
|
176
|
+
x: node.width,
|
|
177
|
+
y: y,
|
|
178
|
+
type: 'right',
|
|
179
|
+
});
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
// Bottom edge points
|
|
183
|
+
for (let x = spacing; x < node.width; x += spacing) {
|
|
184
|
+
points.push({
|
|
185
|
+
id: `${node.id}-bottom-${x}`,
|
|
186
|
+
nodeId: node.id,
|
|
187
|
+
x: x,
|
|
188
|
+
y: node.height,
|
|
189
|
+
type: 'bottom',
|
|
190
|
+
});
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
// Left edge points
|
|
194
|
+
for (let y = spacing; y < node.height; y += spacing) {
|
|
195
|
+
points.push({
|
|
196
|
+
id: `${node.id}-left-${y}`,
|
|
197
|
+
nodeId: node.id,
|
|
198
|
+
x: 0,
|
|
199
|
+
y: y,
|
|
200
|
+
type: 'left',
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
} else if (node.type === 'decision') {
|
|
204
|
+
// Diamond shape - add points at the four corners
|
|
205
|
+
points.push({
|
|
206
|
+
id: `${node.id}-top-0`,
|
|
207
|
+
nodeId: node.id,
|
|
208
|
+
x: node.width / 2,
|
|
209
|
+
y: 0,
|
|
210
|
+
type: 'top',
|
|
211
|
+
});
|
|
212
|
+
|
|
213
|
+
points.push({
|
|
214
|
+
id: `${node.id}-right-0`,
|
|
215
|
+
nodeId: node.id,
|
|
216
|
+
x: node.width,
|
|
217
|
+
y: node.height / 2,
|
|
218
|
+
type: 'right',
|
|
219
|
+
});
|
|
220
|
+
|
|
221
|
+
points.push({
|
|
222
|
+
id: `${node.id}-bottom-0`,
|
|
223
|
+
nodeId: node.id,
|
|
224
|
+
x: node.width / 2,
|
|
225
|
+
y: node.height,
|
|
226
|
+
type: 'bottom',
|
|
227
|
+
});
|
|
228
|
+
|
|
229
|
+
points.push({
|
|
230
|
+
id: `${node.id}-left-0`,
|
|
231
|
+
nodeId: node.id,
|
|
232
|
+
x: 0,
|
|
233
|
+
y: node.height / 2,
|
|
234
|
+
type: 'left',
|
|
235
|
+
});
|
|
236
|
+
} else if (node.type === 'form') {
|
|
237
|
+
// Form only has input connection points, no output points
|
|
238
|
+
|
|
239
|
+
// Left edge points (for input connections)
|
|
240
|
+
for (let y = spacing; y < node.height; y += spacing) {
|
|
241
|
+
points.push({
|
|
242
|
+
id: `${node.id}-left-${y}`,
|
|
243
|
+
nodeId: node.id,
|
|
244
|
+
x: 0,
|
|
245
|
+
y: y,
|
|
246
|
+
type: 'left',
|
|
247
|
+
});
|
|
248
|
+
}
|
|
249
|
+
} else if (node.type === 'subflow') {
|
|
250
|
+
// Hexagon shape - add points at the six corners
|
|
251
|
+
points.push({
|
|
252
|
+
id: `${node.id}-top-0`,
|
|
253
|
+
nodeId: node.id,
|
|
254
|
+
x: node.width / 2,
|
|
255
|
+
y: 0,
|
|
256
|
+
type: 'top',
|
|
257
|
+
});
|
|
258
|
+
|
|
259
|
+
points.push({
|
|
260
|
+
id: `${node.id}-right-top`,
|
|
261
|
+
nodeId: node.id,
|
|
262
|
+
x: node.width,
|
|
263
|
+
y: node.height / 4,
|
|
264
|
+
type: 'right',
|
|
265
|
+
});
|
|
266
|
+
|
|
267
|
+
points.push({
|
|
268
|
+
id: `${node.id}-right-bottom`,
|
|
269
|
+
nodeId: node.id,
|
|
270
|
+
x: node.width,
|
|
271
|
+
y: (node.height * 3) / 4,
|
|
272
|
+
type: 'right',
|
|
273
|
+
});
|
|
274
|
+
|
|
275
|
+
points.push({
|
|
276
|
+
id: `${node.id}-bottom-0`,
|
|
277
|
+
nodeId: node.id,
|
|
278
|
+
x: node.width / 2,
|
|
279
|
+
y: node.height,
|
|
280
|
+
type: 'bottom',
|
|
281
|
+
});
|
|
282
|
+
|
|
283
|
+
points.push({
|
|
284
|
+
id: `${node.id}-left-bottom`,
|
|
285
|
+
nodeId: node.id,
|
|
286
|
+
x: 0,
|
|
287
|
+
y: (node.height * 3) / 4,
|
|
288
|
+
type: 'left',
|
|
289
|
+
});
|
|
290
|
+
|
|
291
|
+
points.push({
|
|
292
|
+
id: `${node.id}-left-top`,
|
|
293
|
+
nodeId: node.id,
|
|
294
|
+
x: 0,
|
|
295
|
+
y: node.height / 4,
|
|
296
|
+
type: 'left',
|
|
297
|
+
});
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
return points;
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
/**
|
|
304
|
+
* Creates a node in a swimlane and returns it (or `null` if the lane or type
|
|
305
|
+
* is invalid).
|
|
306
|
+
*
|
|
307
|
+
* ## Coordinate contract — callers must obey both halves
|
|
308
|
+
*
|
|
309
|
+
* 1. `y` must be an **absolute canvas Y**, not lane-relative. This method
|
|
310
|
+
* converts it internally (`y - swimlaneIndex * 263`).
|
|
311
|
+
* 2. `swimlaneIndex` must be the **drop-target** lane — the lane the node is
|
|
312
|
+
* landing in — not the lane a drag started from.
|
|
313
|
+
*
|
|
314
|
+
* Violating either half double-subtracts the lane offset and the node renders
|
|
315
|
+
* roughly one lane too high, attached to the wrong swimlane. That was the
|
|
316
|
+
* connection-drop bug; `designer-canvas.connection-drop.spec.ts` pins it.
|
|
317
|
+
*
|
|
318
|
+
* The canonical correct caller is toolbar placement in
|
|
319
|
+
* `workflow-designer.component.ts`:
|
|
320
|
+
*
|
|
321
|
+
* ```ts
|
|
322
|
+
* const swimlaneIndex = Math.floor(event.y / 263); // target lane from drop Y
|
|
323
|
+
* this.state.addNode(swimlaneIndex, 'stage', event.x, event.y /* absolute *\/);
|
|
324
|
+
* ```
|
|
325
|
+
*
|
|
326
|
+
* The first node created in an empty workflow is automatically marked as the
|
|
327
|
+
* start node.
|
|
328
|
+
*
|
|
329
|
+
* ⚠️ `NodeManagementService.addNode` applies an extra `- 40` that this method
|
|
330
|
+
* and the render template do not. See `./docs/06-known-issues.md` section A.
|
|
331
|
+
*
|
|
332
|
+
* @param swimlaneIndex Target lane index (the lane the node lands in).
|
|
333
|
+
* @param type Node type; `'swimlane'` and `'action'` are rejected.
|
|
334
|
+
* @param x Canvas X.
|
|
335
|
+
* @param y **Absolute** canvas Y.
|
|
336
|
+
* @param useExistingId Reuse `stageData.Code` as the node id instead of
|
|
337
|
+
* generating one — used when rebuilding nodes from a loaded workflow so
|
|
338
|
+
* they keep their backend identity.
|
|
339
|
+
*/
|
|
340
|
+
addNode(
|
|
341
|
+
swimlaneIndex: number,
|
|
342
|
+
type: ToolType,
|
|
343
|
+
x: number,
|
|
344
|
+
y: number,
|
|
345
|
+
stageData?: Partial<WorkflowStage>,
|
|
346
|
+
workflowData?: { id: string; name: string },
|
|
347
|
+
useExistingId: boolean = false,
|
|
348
|
+
) {
|
|
349
|
+
if (
|
|
350
|
+
!this.swimlanes[swimlaneIndex] ||
|
|
351
|
+
!type ||
|
|
352
|
+
(type !== 'stage' &&
|
|
353
|
+
type !== 'decision' &&
|
|
354
|
+
type !== 'form' &&
|
|
355
|
+
type !== 'subflow')
|
|
356
|
+
) {
|
|
357
|
+
return null;
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
// Adjust position relative to swimlane
|
|
361
|
+
const adjustedY = y - swimlaneIndex * 263; // Subtracting header height
|
|
362
|
+
|
|
363
|
+
// Generate a unique ID or use existing
|
|
364
|
+
const id =
|
|
365
|
+
useExistingId && stageData?.Code
|
|
366
|
+
? stageData.Code
|
|
367
|
+
: `${type}-${Date.now()}-${Math.floor(Math.random() * 1000)}`;
|
|
368
|
+
|
|
369
|
+
// Create node with dimensions based on type
|
|
370
|
+
const node: Node = {
|
|
371
|
+
id,
|
|
372
|
+
type,
|
|
373
|
+
x,
|
|
374
|
+
y: adjustedY,
|
|
375
|
+
width: type === 'subflow' ? 150 : 169, // Width from SVG
|
|
376
|
+
height: 100, // Height from SVG
|
|
377
|
+
isStartNode: false, // Default to false
|
|
378
|
+
stageData: stageData || {}, // Store stage data
|
|
379
|
+
workflowData: workflowData || null,
|
|
380
|
+
};
|
|
381
|
+
|
|
382
|
+
// If this is the first node in the entire workflow, mark it as the start node
|
|
383
|
+
if (this.getNodeCount() === 0) {
|
|
384
|
+
node.isStartNode = true;
|
|
385
|
+
this.startNodeId = id;
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
// Generate connection points for the node
|
|
389
|
+
node.connectionPoints = this.generateConnectionPoints(node);
|
|
390
|
+
|
|
391
|
+
// Add node to the swimlane
|
|
392
|
+
if (!this.swimlanes[swimlaneIndex].nodes) {
|
|
393
|
+
this.swimlanes[swimlaneIndex].nodes = [];
|
|
394
|
+
}
|
|
395
|
+
this.swimlanes[swimlaneIndex].nodes.push(node);
|
|
396
|
+
|
|
397
|
+
return node;
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
// Helper to get total node count across all swimlanes
|
|
401
|
+
getNodeCount(): number {
|
|
402
|
+
return this.swimlanes.reduce(
|
|
403
|
+
(count, swimlane) => count + (swimlane.nodes?.length || 0),
|
|
404
|
+
0,
|
|
405
|
+
);
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
// Find a node by ID (useful for later operations)
|
|
409
|
+
findNodeById(id: string): { node: Node; swimlaneIndex: number } | null {
|
|
410
|
+
for (let i = 0; i < this.swimlanes.length; i++) {
|
|
411
|
+
const swimlane = this.swimlanes[i];
|
|
412
|
+
const node = swimlane.nodes?.find((n) => n.id === id);
|
|
413
|
+
if (node) {
|
|
414
|
+
return { node, swimlaneIndex: i };
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
return null;
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
// Find a node by ID (useful for later operations)
|
|
421
|
+
findActionById(connectionId: string): Connection | null {
|
|
422
|
+
return this.connections.find(({ id }) => id === connectionId) ?? null;
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
startConnectionDrag(
|
|
426
|
+
point: ConnectionPoint,
|
|
427
|
+
swimlaneIndex: number,
|
|
428
|
+
globalX: number,
|
|
429
|
+
globalY: number,
|
|
430
|
+
) {
|
|
431
|
+
this.draggingConnectionData = {
|
|
432
|
+
sourcePoint: point,
|
|
433
|
+
sourceSwimlaneIndex: swimlaneIndex,
|
|
434
|
+
startX: globalX,
|
|
435
|
+
startY: globalY,
|
|
436
|
+
currentX: globalX,
|
|
437
|
+
currentY: globalY,
|
|
438
|
+
};
|
|
439
|
+
}
|
|
440
|
+
|
|
441
|
+
updateConnectionDrag(currentX: number, currentY: number) {
|
|
442
|
+
if (this.draggingConnectionData.sourcePoint) {
|
|
443
|
+
this.draggingConnectionData.currentX = currentX;
|
|
444
|
+
this.draggingConnectionData.currentY = currentY;
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
|
|
448
|
+
endConnectionDrag() {
|
|
449
|
+
// Clear dragging data
|
|
450
|
+
this.draggingConnectionData = {};
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
isConnectionDragging(): boolean {
|
|
454
|
+
return !!this.draggingConnectionData.sourcePoint;
|
|
455
|
+
}
|
|
456
|
+
|
|
457
|
+
/**
|
|
458
|
+
* Endpoints for the **in-progress** connection preview line: from the source
|
|
459
|
+
* point (resolved to absolute canvas space) to the current cursor position.
|
|
460
|
+
*
|
|
461
|
+
* Returns `null` when no drag is active. For a *saved* connection's
|
|
462
|
+
* endpoints, use {@link getConnectionData} instead.
|
|
463
|
+
*/
|
|
464
|
+
getConnectionPathData(): {
|
|
465
|
+
startX: number;
|
|
466
|
+
startY: number;
|
|
467
|
+
endX: number;
|
|
468
|
+
endY: number;
|
|
469
|
+
sourceSwimlaneIndex: number;
|
|
470
|
+
} | null {
|
|
471
|
+
if (!this.draggingConnectionData.sourcePoint) return null;
|
|
472
|
+
|
|
473
|
+
const { sourcePoint, sourceSwimlaneIndex, currentX, currentY } =
|
|
474
|
+
this.draggingConnectionData;
|
|
475
|
+
const node = this.findNodeById(sourcePoint.nodeId)?.node;
|
|
476
|
+
|
|
477
|
+
if (!node || sourceSwimlaneIndex === undefined) return null;
|
|
478
|
+
|
|
479
|
+
// Calculate start point in global coordinates
|
|
480
|
+
const startX = node.x + sourcePoint.x;
|
|
481
|
+
const startY = node.y + sourcePoint.y + sourceSwimlaneIndex * 263; // Add swimlane offset
|
|
482
|
+
|
|
483
|
+
return {
|
|
484
|
+
startX,
|
|
485
|
+
startY,
|
|
486
|
+
endX: currentX ?? startX,
|
|
487
|
+
endY: currentY ?? startY,
|
|
488
|
+
sourceSwimlaneIndex,
|
|
489
|
+
};
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
/**
|
|
493
|
+
* Completes the in-progress drag by pushing a `Connection` from the recorded
|
|
494
|
+
* source point to the given target, and returns it.
|
|
495
|
+
*
|
|
496
|
+
* Reads the source from {@link draggingConnectionData}, so it is only valid
|
|
497
|
+
* during a drag — returns `null` if no source was recorded.
|
|
498
|
+
*
|
|
499
|
+
* Note this does **not** check {@link canConnect}; callers are expected to
|
|
500
|
+
* have validated the pairing before calling. The new connection has an empty
|
|
501
|
+
* label and no action — those are filled in afterwards via the action dialog.
|
|
502
|
+
*/
|
|
503
|
+
createConnection(
|
|
504
|
+
targetNodeId: string,
|
|
505
|
+
targetPointId: string,
|
|
506
|
+
targetSwimlaneIndex: number,
|
|
507
|
+
): Connection | null {
|
|
508
|
+
const { sourcePoint, sourceSwimlaneIndex } = this.draggingConnectionData;
|
|
509
|
+
|
|
510
|
+
if (!sourcePoint || sourceSwimlaneIndex === undefined) {
|
|
511
|
+
return null;
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
const connection: Connection = {
|
|
515
|
+
id: `conn-${Date.now()}-${Math.floor(Math.random() * 1000)}`,
|
|
516
|
+
sourceNodeId: sourcePoint.nodeId,
|
|
517
|
+
targetNodeId: targetNodeId,
|
|
518
|
+
sourcePointId: sourcePoint.id,
|
|
519
|
+
targetPointId: targetPointId,
|
|
520
|
+
sourceSwimlaneIndex: sourceSwimlaneIndex,
|
|
521
|
+
targetSwimlaneIndex: targetSwimlaneIndex,
|
|
522
|
+
label: '',
|
|
523
|
+
action: null,
|
|
524
|
+
position: 1,
|
|
525
|
+
};
|
|
526
|
+
|
|
527
|
+
this.connections.push(connection);
|
|
528
|
+
return connection;
|
|
529
|
+
}
|
|
530
|
+
|
|
531
|
+
/**
|
|
532
|
+
* Resolves a saved connection's endpoints into **absolute canvas
|
|
533
|
+
* coordinates** for rendering:
|
|
534
|
+
*
|
|
535
|
+
* ```
|
|
536
|
+
* startY = sourceNode.y + sourcePoint.y + connection.sourceSwimlaneIndex * 263
|
|
537
|
+
* endY = targetNode.y + targetPoint.y + connection.targetSwimlaneIndex * 263
|
|
538
|
+
* ```
|
|
539
|
+
*
|
|
540
|
+
* Both offsets are needed because `node.y` is lane-relative and `point.y` is
|
|
541
|
+
* node-relative.
|
|
542
|
+
*
|
|
543
|
+
* Returns `null` if either endpoint's node no longer exists — callers should
|
|
544
|
+
* treat that as "skip rendering this edge", not as an error.
|
|
545
|
+
*
|
|
546
|
+
* ⚠️ Relies on the connection's denormalised lane indices being current. A
|
|
547
|
+
* node moved between lanes without its connections updated renders detached.
|
|
548
|
+
*
|
|
549
|
+
* ⚠️ `ConnectionService.getConnectionData` adds a further `+ 40` here. The two
|
|
550
|
+
* disagree; this is the live path. See `./docs/06-known-issues.md` section A.
|
|
551
|
+
*/
|
|
552
|
+
getConnectionData(connection: Connection): {
|
|
553
|
+
startX: number;
|
|
554
|
+
startY: number;
|
|
555
|
+
endX: number;
|
|
556
|
+
endY: number;
|
|
557
|
+
sourceSwimlaneIndex: number;
|
|
558
|
+
targetSwimlaneIndex: number;
|
|
559
|
+
} | null {
|
|
560
|
+
const sourceNodeInfo = this.findNodeById(connection.sourceNodeId);
|
|
561
|
+
const targetNodeInfo = this.findNodeById(connection.targetNodeId);
|
|
562
|
+
|
|
563
|
+
if (!sourceNodeInfo || !targetNodeInfo) {
|
|
564
|
+
return null;
|
|
565
|
+
}
|
|
566
|
+
|
|
567
|
+
const sourceNode = sourceNodeInfo.node;
|
|
568
|
+
const targetNode = targetNodeInfo.node;
|
|
569
|
+
|
|
570
|
+
// Find connection points
|
|
571
|
+
const sourcePoint = sourceNode.connectionPoints?.find(
|
|
572
|
+
(p) => p.id === connection.sourcePointId,
|
|
573
|
+
);
|
|
574
|
+
const targetPoint = targetNode.connectionPoints?.find(
|
|
575
|
+
(p) => p.id === connection.targetPointId,
|
|
576
|
+
);
|
|
577
|
+
|
|
578
|
+
if (!sourcePoint || !targetPoint) {
|
|
579
|
+
return null;
|
|
580
|
+
}
|
|
581
|
+
|
|
582
|
+
// Calculate global coordinates
|
|
583
|
+
const startX = sourceNode.x + sourcePoint.x;
|
|
584
|
+
const startY =
|
|
585
|
+
sourceNode.y + sourcePoint.y + connection.sourceSwimlaneIndex * 263;
|
|
586
|
+
|
|
587
|
+
const endX = targetNode.x + targetPoint.x;
|
|
588
|
+
const endY =
|
|
589
|
+
targetNode.y + targetPoint.y + connection.targetSwimlaneIndex * 263;
|
|
590
|
+
|
|
591
|
+
return {
|
|
592
|
+
startX,
|
|
593
|
+
startY,
|
|
594
|
+
endX,
|
|
595
|
+
endY,
|
|
596
|
+
sourceSwimlaneIndex: connection.sourceSwimlaneIndex,
|
|
597
|
+
targetSwimlaneIndex: connection.targetSwimlaneIndex,
|
|
598
|
+
};
|
|
599
|
+
}
|
|
600
|
+
|
|
601
|
+
/**
|
|
602
|
+
* Whether an edge from `sourceNodeType` to `targetNodeType` is permitted by
|
|
603
|
+
* {@link connectionRules}. Unknown types return `false`.
|
|
604
|
+
*/
|
|
605
|
+
canConnect(sourceNodeType: string, targetNodeType: string): boolean {
|
|
606
|
+
return (
|
|
607
|
+
this.connectionRules[sourceNodeType]?.includes(targetNodeType) || false
|
|
608
|
+
);
|
|
609
|
+
}
|
|
610
|
+
|
|
611
|
+
/**
|
|
612
|
+
* Node types the in-progress drag is allowed to land on. Drives the choices
|
|
613
|
+
* offered in the node-type popup when a connection is dropped on empty
|
|
614
|
+
* canvas. Empty when no drag is active.
|
|
615
|
+
*/
|
|
616
|
+
getAllowedTargetNodeTypes(): string[] {
|
|
617
|
+
if (!this.draggingConnectionData.sourcePoint) {
|
|
618
|
+
return [];
|
|
619
|
+
}
|
|
620
|
+
|
|
621
|
+
const sourceNodeInfo = this.findNodeById(
|
|
622
|
+
this.draggingConnectionData.sourcePoint.nodeId,
|
|
623
|
+
);
|
|
624
|
+
if (!sourceNodeInfo) {
|
|
625
|
+
return [];
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
const sourceNodeType = sourceNodeInfo.node.type;
|
|
629
|
+
|
|
630
|
+
return this.connectionRules[sourceNodeType] || [];
|
|
631
|
+
}
|
|
632
|
+
|
|
633
|
+
/**
|
|
634
|
+
* Deletes a swimlane. Only succeeds when the lane has no nodes — stages must
|
|
635
|
+
* be moved to another lane first. Returns false when the lane still has nodes
|
|
636
|
+
* or the index is out of range.
|
|
637
|
+
*
|
|
638
|
+
* Keeps everything aligned after removal:
|
|
639
|
+
* - Re-sequences `order` on the remaining lanes (immutable reassignment so
|
|
640
|
+
* Angular's @for blocks re-render).
|
|
641
|
+
* - Decrements the swimlane indices stored on connections whose endpoints
|
|
642
|
+
* live below the removed lane, since those lanes shift up by one.
|
|
643
|
+
*
|
|
644
|
+
* The lane's original record is left in `swimlaneRecord`, so a previously
|
|
645
|
+
* loaded lane is emitted with `ObjectState.Removed` by
|
|
646
|
+
* `transformToWorkflowModel`; a never-saved lane simply disappears.
|
|
647
|
+
*/
|
|
648
|
+
deleteSwimlane(index: number): boolean {
|
|
649
|
+
if (index < 0 || index >= this.swimlanes.length) {
|
|
650
|
+
return false;
|
|
651
|
+
}
|
|
652
|
+
|
|
653
|
+
if (this.swimlanes[index].nodes?.length) {
|
|
654
|
+
return false;
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
this.swimlanes = this.swimlanes
|
|
658
|
+
.filter((_, i) => i !== index)
|
|
659
|
+
.map((lane, i) => ({ ...lane, order: i }));
|
|
660
|
+
|
|
661
|
+
this.connections = this.connections.map((conn) => ({
|
|
662
|
+
...conn,
|
|
663
|
+
sourceSwimlaneIndex:
|
|
664
|
+
conn.sourceSwimlaneIndex > index
|
|
665
|
+
? conn.sourceSwimlaneIndex - 1
|
|
666
|
+
: conn.sourceSwimlaneIndex,
|
|
667
|
+
targetSwimlaneIndex:
|
|
668
|
+
conn.targetSwimlaneIndex > index
|
|
669
|
+
? conn.targetSwimlaneIndex - 1
|
|
670
|
+
: conn.targetSwimlaneIndex,
|
|
671
|
+
}));
|
|
672
|
+
|
|
673
|
+
return true;
|
|
674
|
+
}
|
|
675
|
+
|
|
676
|
+
updateSwimlane(index: number, name: string, tags: Tag[]) {
|
|
677
|
+
if (index >= 0 && index < this.swimlanes.length) {
|
|
678
|
+
this.swimlanes[index] = {
|
|
679
|
+
...this.swimlanes[index],
|
|
680
|
+
label: name,
|
|
681
|
+
tags: tags,
|
|
682
|
+
};
|
|
683
|
+
}
|
|
684
|
+
}
|
|
685
|
+
|
|
686
|
+
/**
|
|
687
|
+
* Rebuilds the full `Workflow` API model from the current editing state —
|
|
688
|
+
* the save-side counterpart to `parseWorkflowData` in
|
|
689
|
+
* `workflow-designer.component.ts`.
|
|
690
|
+
*
|
|
691
|
+
* Mapping:
|
|
692
|
+
* - swimlanes → `Lanes`
|
|
693
|
+
* - stage **and subflow** nodes → `Stages` (subflows carry `IsSubProcess: true`)
|
|
694
|
+
* - connections → `Actions`
|
|
695
|
+
*
|
|
696
|
+
* Each entity's `DataState` is derived by looking it up in `swimlaneRecord` /
|
|
697
|
+
* `stageRecord` / `actionRecord`: found means `Changed`, absent means `New`.
|
|
698
|
+
* Clearing those maps therefore makes everything save as new.
|
|
699
|
+
*
|
|
700
|
+
* ⚠️ Decision and form nodes are **not** emitted as stages — only `stage` and
|
|
701
|
+
* `subflow` are. Decision semantics survive through the conditions on their
|
|
702
|
+
* connections.
|
|
703
|
+
*
|
|
704
|
+
* ⚠️ When no workflow was loaded, the header is hard-coded (`Name: 'New
|
|
705
|
+
* Workflow'`, empty description, default assignment and status) because the
|
|
706
|
+
* designer has no UI for editing it. See `./docs/06-known-issues.md` section G.
|
|
707
|
+
*
|
|
708
|
+
* This only builds the payload; `WorkflowDataService.saveWorkflows` sends it.
|
|
709
|
+
* Deletions are not part of this — they are issued eagerly at the point of
|
|
710
|
+
* user action. See `./docs/08-api-reference.md` section 3.
|
|
711
|
+
*/
|
|
712
|
+
transformToWorkflowModel(): Workflow {
|
|
713
|
+
// Use stored workflow if available, otherwise create a new one
|
|
714
|
+
const workflow: Workflow = this.workflow
|
|
715
|
+
? { ...this.workflow, DataState: ObjectState.Changed }
|
|
716
|
+
: {
|
|
717
|
+
// BaseModel properties
|
|
718
|
+
Id: '',
|
|
719
|
+
Code: '',
|
|
720
|
+
TenantId: '',
|
|
721
|
+
id: '',
|
|
722
|
+
ServiceName: '',
|
|
723
|
+
CreatedAt: new Date(),
|
|
724
|
+
UpdatedAt: new Date(),
|
|
725
|
+
DataState: this.wasLoadedFromApi(this.workflowId || '')
|
|
726
|
+
? ObjectState.Changed
|
|
727
|
+
: ObjectState.New,
|
|
728
|
+
|
|
729
|
+
// Workflow specific properties
|
|
730
|
+
Name: 'New Workflow',
|
|
731
|
+
Description: '',
|
|
732
|
+
StageEntryRule: '',
|
|
733
|
+
Form: this.workflowFormId || undefined,
|
|
734
|
+
AssignmentType: TaskAssignmentType.AutoRoute,
|
|
735
|
+
Operation: '',
|
|
736
|
+
Status: Status.Active,
|
|
737
|
+
Actions: [],
|
|
738
|
+
Lanes: [],
|
|
739
|
+
Stages: [],
|
|
740
|
+
};
|
|
741
|
+
|
|
742
|
+
// Update workflow form if changed
|
|
743
|
+
if (this.workflowFormId !== this.workflow?.Form) {
|
|
744
|
+
workflow.Form = this.workflowFormId || workflow.Form;
|
|
745
|
+
}
|
|
746
|
+
|
|
747
|
+
// Transform swimlanes to SwimLane[]
|
|
748
|
+
workflow.Lanes = this.swimlanes.map((swimlane) => {
|
|
749
|
+
// Check if this is an existing swimlane
|
|
750
|
+
if (swimlane.id && this.swimlaneRecord[swimlane.id]) {
|
|
751
|
+
// Update existing lane with changed values
|
|
752
|
+
const existingLane = this.swimlaneRecord[swimlane.id];
|
|
753
|
+
return {
|
|
754
|
+
...existingLane,
|
|
755
|
+
Name: swimlane.label,
|
|
756
|
+
Tags: swimlane.tags,
|
|
757
|
+
Position: swimlane.order,
|
|
758
|
+
Coordinates: { X: 0, Y: swimlane.order * 263 },
|
|
759
|
+
DataState: ObjectState.Changed,
|
|
760
|
+
UpdatedAt: new Date(),
|
|
761
|
+
};
|
|
762
|
+
} else {
|
|
763
|
+
// Generate a new ID for new swimlanes if not already set
|
|
764
|
+
const laneId =
|
|
765
|
+
swimlane.id ||
|
|
766
|
+
`lane-${Date.now()}-${Math.floor(Math.random() * 1000)}`;
|
|
767
|
+
|
|
768
|
+
// Create new lane
|
|
769
|
+
return {
|
|
770
|
+
Code: '',
|
|
771
|
+
Id: '',
|
|
772
|
+
TenantId: '',
|
|
773
|
+
// id: laneId,
|
|
774
|
+
id: '',
|
|
775
|
+
ServiceName: '',
|
|
776
|
+
CreatedAt: new Date(),
|
|
777
|
+
UpdatedAt: new Date(),
|
|
778
|
+
DataState: ObjectState.New,
|
|
779
|
+
Workflow: workflow.Code,
|
|
780
|
+
Name: swimlane.label,
|
|
781
|
+
Tags: swimlane.tags || [],
|
|
782
|
+
Position: swimlane.order,
|
|
783
|
+
Coordinates: { X: 0, Y: swimlane.order * 263 },
|
|
784
|
+
Size: { Width: 3000, Height: 263 },
|
|
785
|
+
Key: swimlane.id,
|
|
786
|
+
};
|
|
787
|
+
}
|
|
788
|
+
});
|
|
789
|
+
|
|
790
|
+
// Transform nodes to WorkflowStage[]
|
|
791
|
+
const stages: WorkflowStage[] = [];
|
|
792
|
+
|
|
793
|
+
this.swimlanes.forEach((swimlane, swimlaneIndex) => {
|
|
794
|
+
swimlane.nodes?.forEach((node) => {
|
|
795
|
+
if (node.type === 'stage' || node.type === 'subflow') {
|
|
796
|
+
// Check if this is an existing stage
|
|
797
|
+
if (this.stageRecord[node.id]) {
|
|
798
|
+
// Update existing stage with changed values
|
|
799
|
+
const existingStage = this.stageRecord[node.id];
|
|
800
|
+
|
|
801
|
+
// Create a new object with updated properties
|
|
802
|
+
const updatedStage: WorkflowStage = {
|
|
803
|
+
...existingStage,
|
|
804
|
+
DataState: ObjectState.Changed,
|
|
805
|
+
UpdatedAt: new Date(),
|
|
806
|
+
};
|
|
807
|
+
|
|
808
|
+
// Update properties that may have changed
|
|
809
|
+
if (node.stageData?.Name !== undefined)
|
|
810
|
+
updatedStage.Name =
|
|
811
|
+
node.workflowData?.name ?? node.stageData.Name;
|
|
812
|
+
if (node.stageData?.Description !== undefined)
|
|
813
|
+
updatedStage.Description = node.stageData.Description;
|
|
814
|
+
if (node.stageData?.Duration !== undefined)
|
|
815
|
+
updatedStage.Duration = node.stageData.Duration;
|
|
816
|
+
if (node.stageData?.PassOnRule !== undefined)
|
|
817
|
+
updatedStage.PassOnRule = node.stageData.PassOnRule;
|
|
818
|
+
if (node.stageData?.ActorRule !== undefined)
|
|
819
|
+
updatedStage.ActorRule = node.stageData.ActorRule;
|
|
820
|
+
if (node.stageData?.AssignmentType !== undefined)
|
|
821
|
+
updatedStage.AssignmentType = node.stageData.AssignmentType;
|
|
822
|
+
if (node.stageData?.MinNoOfActor !== undefined)
|
|
823
|
+
updatedStage.MinNoOfActor = node.stageData.MinNoOfActor;
|
|
824
|
+
if (node.stageData?.IsParallel !== undefined)
|
|
825
|
+
updatedStage.IsParallel = node.stageData.IsParallel;
|
|
826
|
+
if (node.stageData?.Tags) updatedStage.Tags = node.stageData.Tags;
|
|
827
|
+
|
|
828
|
+
// Always update these properties
|
|
829
|
+
updatedStage.IsEntryPoint = node.isStartNode;
|
|
830
|
+
updatedStage.IsExitPoint = node.stageData?.IsExitPoint || false;
|
|
831
|
+
updatedStage.Form = node.stageData?.formId || '';
|
|
832
|
+
updatedStage.Coordinates = { X: node.x, Y: node.y };
|
|
833
|
+
updatedStage.SwimLane = this.swimlanes[swimlaneIndex].id || '';
|
|
834
|
+
|
|
835
|
+
// console.log("NODE_TYPE", node.type);
|
|
836
|
+
|
|
837
|
+
// Handle subflow stage
|
|
838
|
+
if (node.type === 'subflow') {
|
|
839
|
+
updatedStage.IsSubProcess = true;
|
|
840
|
+
updatedStage.SubWorkFlow = node.workflowData?.id || '';
|
|
841
|
+
updatedStage.Name = node.workflowData?.name || '';
|
|
842
|
+
}
|
|
843
|
+
|
|
844
|
+
// Add to stages
|
|
845
|
+
stages.push(updatedStage);
|
|
846
|
+
} else {
|
|
847
|
+
// Create a new stage
|
|
848
|
+
stages.push({
|
|
849
|
+
Id: '',
|
|
850
|
+
Code: '',
|
|
851
|
+
TenantId: '',
|
|
852
|
+
// id: node.id,
|
|
853
|
+
id: '',
|
|
854
|
+
ServiceName: '',
|
|
855
|
+
CreatedAt: new Date(),
|
|
856
|
+
UpdatedAt: new Date(),
|
|
857
|
+
DataState: ObjectState.New,
|
|
858
|
+
Workflow: workflow.Code,
|
|
859
|
+
Name:
|
|
860
|
+
(node.type === 'subflow'
|
|
861
|
+
? node.workflowData?.name
|
|
862
|
+
: node.stageData?.Name) ?? '',
|
|
863
|
+
Description: node.stageData?.Description || '',
|
|
864
|
+
Duration: node.stageData?.Duration || 0,
|
|
865
|
+
PassOnRule: node.stageData?.PassOnRule || '',
|
|
866
|
+
ActorRule: node.stageData?.ActorRule || StageActorRule.None,
|
|
867
|
+
MinNoOfActor: node.stageData?.MinNoOfActor || 0,
|
|
868
|
+
IsParallel: node.stageData?.IsParallel || false,
|
|
869
|
+
IsEntryPoint: node.isStartNode,
|
|
870
|
+
IsExitPoint: node.stageData?.IsExitPoint || false, // Will be updated below
|
|
871
|
+
Tags: node.stageData?.Tags || [],
|
|
872
|
+
Form: node.stageData?.formId ?? '',
|
|
873
|
+
AllowMultiSubProcess: false,
|
|
874
|
+
AssignmentType:
|
|
875
|
+
node.stageData?.AssignmentType ||
|
|
876
|
+
this.workflow?.AssignmentType ||
|
|
877
|
+
TaskAssignmentType.AutoRoute,
|
|
878
|
+
SubWorkFlow: node.workflowData?.id || '',
|
|
879
|
+
SwimLane: this.swimlanes[swimlaneIndex].id || '',
|
|
880
|
+
Coordinates: { X: node.x, Y: node.y },
|
|
881
|
+
IsSubProcess: node.type === 'subflow',
|
|
882
|
+
Key: node.stageData?.Key || node.id,
|
|
883
|
+
});
|
|
884
|
+
}
|
|
885
|
+
}
|
|
886
|
+
});
|
|
887
|
+
});
|
|
888
|
+
|
|
889
|
+
// // Determine which stages are exit points (no outgoing connections)
|
|
890
|
+
// stages.forEach((stage) => {
|
|
891
|
+
// const hasOutgoingConnections = this.connections.some(
|
|
892
|
+
// (conn) =>
|
|
893
|
+
// conn.sourceNodeId === stage.Code || conn.sourceNodeId === stage.id
|
|
894
|
+
// );
|
|
895
|
+
// if (!hasOutgoingConnections) {
|
|
896
|
+
// stage.IsExitPoint = true;
|
|
897
|
+
// }
|
|
898
|
+
// });
|
|
899
|
+
|
|
900
|
+
// Transform connections to WorkflowAction[]
|
|
901
|
+
const actions: WorkflowAction[] = [];
|
|
902
|
+
|
|
903
|
+
this.connections.forEach((conn) => {
|
|
904
|
+
const sourceNode = this.findNodeById(conn.sourceNodeId)?.node;
|
|
905
|
+
const targetNode = this.findNodeById(conn.targetNodeId)?.node;
|
|
906
|
+
|
|
907
|
+
// Check if this is an existing action
|
|
908
|
+
if (this.actionRecord[conn.id]) {
|
|
909
|
+
// Update existing action with changed values
|
|
910
|
+
const existingAction = this.actionRecord[conn.id];
|
|
911
|
+
|
|
912
|
+
// Create updated action with changed properties
|
|
913
|
+
const updatedAction: WorkflowAction = {
|
|
914
|
+
...existingAction,
|
|
915
|
+
DataState: ObjectState.Changed,
|
|
916
|
+
UpdatedAt: new Date(),
|
|
917
|
+
};
|
|
918
|
+
|
|
919
|
+
// Update properties that may have changed
|
|
920
|
+
updatedAction.Name =
|
|
921
|
+
conn.label ??
|
|
922
|
+
`Action from ${sourceNode?.stageData?.Name || 'Unknown'} to ${
|
|
923
|
+
targetNode?.stageData?.Name || 'Unknown'
|
|
924
|
+
}`;
|
|
925
|
+
updatedAction.OperationAction = conn.action;
|
|
926
|
+
updatedAction.Position = conn.position;
|
|
927
|
+
updatedAction.IsParallel = targetNode?.stageData?.IsParallel || false;
|
|
928
|
+
updatedAction.PassOnRule = conn.condition || '';
|
|
929
|
+
updatedAction.TargetStatus = conn.targetStatus || undefined;
|
|
930
|
+
// updatedAction.SourcePointType = this.getConnectionPointType(conn.sourcePointId);
|
|
931
|
+
// updatedAction.TargetPointType = this.getConnectionPointType(conn.targetPointId);
|
|
932
|
+
|
|
933
|
+
actions.push(updatedAction);
|
|
934
|
+
} else {
|
|
935
|
+
// Create a new action
|
|
936
|
+
actions.push({
|
|
937
|
+
Id: '',
|
|
938
|
+
Code: '',
|
|
939
|
+
TenantId: '',
|
|
940
|
+
// id: conn.id,
|
|
941
|
+
id: '',
|
|
942
|
+
ServiceName: '',
|
|
943
|
+
CreatedAt: new Date(),
|
|
944
|
+
UpdatedAt: new Date(),
|
|
945
|
+
DataState: ObjectState.New,
|
|
946
|
+
Workflow: workflow.Code,
|
|
947
|
+
Name:
|
|
948
|
+
conn.label ??
|
|
949
|
+
`Action from ${sourceNode?.stageData?.Name || 'Unknown'} to ${
|
|
950
|
+
targetNode?.stageData?.Name || 'Unknown'
|
|
951
|
+
}`,
|
|
952
|
+
OperationAction: conn.action,
|
|
953
|
+
Position: conn.position,
|
|
954
|
+
TargetStatus: conn.targetStatus,
|
|
955
|
+
FromStage: conn.sourceNodeId,
|
|
956
|
+
ToStage: conn.targetNodeId,
|
|
957
|
+
IsParallel: sourceNode?.stageData?.IsParallel || false,
|
|
958
|
+
PassOnRule: conn.condition || '',
|
|
959
|
+
SourcePointType: this.getConnectionPointType(conn.sourcePointId),
|
|
960
|
+
TargetPointType: this.getConnectionPointType(conn.targetPointId),
|
|
961
|
+
});
|
|
962
|
+
}
|
|
963
|
+
});
|
|
964
|
+
|
|
965
|
+
// Add deleted objects with Removed state
|
|
966
|
+
Object.keys(this.stageRecord).forEach((stageId) => {
|
|
967
|
+
const exists = stages.some(
|
|
968
|
+
(stage) => stage.Code === stageId || stage.id === stageId,
|
|
969
|
+
);
|
|
970
|
+
|
|
971
|
+
if (!exists) {
|
|
972
|
+
const stage = this.stageRecord[stageId];
|
|
973
|
+
stages.push({
|
|
974
|
+
...stage,
|
|
975
|
+
DataState: ObjectState.Removed,
|
|
976
|
+
UpdatedAt: new Date(),
|
|
977
|
+
});
|
|
978
|
+
}
|
|
979
|
+
});
|
|
980
|
+
|
|
981
|
+
Object.keys(this.actionRecord).forEach((actionId) => {
|
|
982
|
+
const exists = actions.some(
|
|
983
|
+
(action) => action.Code === actionId || action.id === actionId,
|
|
984
|
+
);
|
|
985
|
+
|
|
986
|
+
if (!exists) {
|
|
987
|
+
const action = this.actionRecord[actionId];
|
|
988
|
+
actions.push({
|
|
989
|
+
...action,
|
|
990
|
+
DataState: ObjectState.Removed,
|
|
991
|
+
UpdatedAt: new Date(),
|
|
992
|
+
});
|
|
993
|
+
}
|
|
994
|
+
});
|
|
995
|
+
|
|
996
|
+
// Handle deleted swimlanes
|
|
997
|
+
Object.keys(this.swimlaneRecord).forEach((laneId) => {
|
|
998
|
+
const exists = workflow.Lanes.some(
|
|
999
|
+
(lane) => lane.Code === laneId || lane.id === laneId,
|
|
1000
|
+
);
|
|
1001
|
+
|
|
1002
|
+
if (!exists) {
|
|
1003
|
+
const lane = this.swimlaneRecord[laneId];
|
|
1004
|
+
workflow.Lanes.push({
|
|
1005
|
+
...lane,
|
|
1006
|
+
DataState: ObjectState.Removed,
|
|
1007
|
+
UpdatedAt: new Date(),
|
|
1008
|
+
});
|
|
1009
|
+
}
|
|
1010
|
+
});
|
|
1011
|
+
|
|
1012
|
+
workflow.Stages = stages;
|
|
1013
|
+
workflow.Actions = actions;
|
|
1014
|
+
|
|
1015
|
+
return workflow;
|
|
1016
|
+
}
|
|
1017
|
+
|
|
1018
|
+
getConnectionPointType(
|
|
1019
|
+
pointId: string,
|
|
1020
|
+
): 'top' | 'right' | 'bottom' | 'left' | undefined {
|
|
1021
|
+
// Extract the type from the connection point ID format
|
|
1022
|
+
// which is usually something like "node-id-top-50"
|
|
1023
|
+
const parts = pointId.split('-');
|
|
1024
|
+
const typeIndex = parts.findIndex(
|
|
1025
|
+
(part) =>
|
|
1026
|
+
part === 'top' ||
|
|
1027
|
+
part === 'right' ||
|
|
1028
|
+
part === 'bottom' ||
|
|
1029
|
+
part === 'left',
|
|
1030
|
+
);
|
|
1031
|
+
|
|
1032
|
+
if (typeIndex >= 0) {
|
|
1033
|
+
return parts[typeIndex] as 'top' | 'right' | 'bottom' | 'left';
|
|
1034
|
+
}
|
|
1035
|
+
|
|
1036
|
+
return undefined;
|
|
1037
|
+
}
|
|
1038
|
+
|
|
1039
|
+
// Add a new property to track loaded objects
|
|
1040
|
+
loadedObjectIds: { [key: string]: string } = {}; // Format: { id: code }
|
|
1041
|
+
|
|
1042
|
+
// Add a method to register loaded objects
|
|
1043
|
+
registerLoadedObject(id: string, code: string): void {
|
|
1044
|
+
this.loadedObjectIds[id] = code;
|
|
1045
|
+
}
|
|
1046
|
+
|
|
1047
|
+
// Method to check if an object was loaded from API
|
|
1048
|
+
wasLoadedFromApi(id: string): boolean {
|
|
1049
|
+
return id in this.loadedObjectIds;
|
|
1050
|
+
}
|
|
1051
|
+
|
|
1052
|
+
// Method to get the code for a loaded object
|
|
1053
|
+
getCodeForObject(id: string): string {
|
|
1054
|
+
return this.loadedObjectIds[id] || '';
|
|
1055
|
+
}
|
|
1056
|
+
|
|
1057
|
+
/**
|
|
1058
|
+
* Moves a node from one swimlane to another and updates all related state:
|
|
1059
|
+
* - Node position (swimlane-relative x/y)
|
|
1060
|
+
* - Swimlane arrays (removes from old, adds to new)
|
|
1061
|
+
* - Connection swimlane indices for this node
|
|
1062
|
+
* - Node's stageData.Tags and SwimLane to match the destination swimlane
|
|
1063
|
+
*/
|
|
1064
|
+
moveNodeToSwimlane(
|
|
1065
|
+
nodeId: string,
|
|
1066
|
+
fromSwimlaneIndex: number,
|
|
1067
|
+
toSwimlaneIndex: number,
|
|
1068
|
+
newX: number,
|
|
1069
|
+
absoluteY: number, // absolute SVG Y of the node at drop time
|
|
1070
|
+
): Node | null {
|
|
1071
|
+
const fromSwimlane = this.swimlanes[fromSwimlaneIndex];
|
|
1072
|
+
if (!fromSwimlane?.nodes) return null;
|
|
1073
|
+
|
|
1074
|
+
const nodeIndex = fromSwimlane.nodes.findIndex((n) => n.id === nodeId);
|
|
1075
|
+
if (nodeIndex === -1) return null;
|
|
1076
|
+
|
|
1077
|
+
// Pull the node out – keep a local reference
|
|
1078
|
+
const node = fromSwimlane.nodes[nodeIndex];
|
|
1079
|
+
|
|
1080
|
+
// ── Fix the Y coordinate ──────────────────────────────────────────────
|
|
1081
|
+
// Template formula: absoluteSVGY = node.y + swimlane.order * 263
|
|
1082
|
+
// Connection formula: absoluteY = node.y + swimlaneIndex * 263 + point.y
|
|
1083
|
+
// Both expect node.y to be swimlane-relative:
|
|
1084
|
+
// node.y = absoluteSVGY - swimlane.order * 263
|
|
1085
|
+
node.x = newX;
|
|
1086
|
+
node.y = absoluteY - toSwimlaneIndex * this.swimlaneHeight;
|
|
1087
|
+
|
|
1088
|
+
// ── Move between swimlane arrays (immutable reassignment) ─────────────
|
|
1089
|
+
// Using filter+spread instead of splice/push so Angular's @for block
|
|
1090
|
+
// detects the array change on both old and new swimlane.
|
|
1091
|
+
fromSwimlane.nodes = fromSwimlane.nodes.filter((n) => n.id !== nodeId);
|
|
1092
|
+
|
|
1093
|
+
const toSwimlane = this.swimlanes[toSwimlaneIndex];
|
|
1094
|
+
toSwimlane.nodes = [...(toSwimlane.nodes || []), node];
|
|
1095
|
+
|
|
1096
|
+
// ── Update connection swimlane indices ────────────────────────────────
|
|
1097
|
+
this.connections = this.connections.map((conn) => {
|
|
1098
|
+
if (conn.sourceNodeId !== nodeId && conn.targetNodeId !== nodeId)
|
|
1099
|
+
return conn;
|
|
1100
|
+
return {
|
|
1101
|
+
...conn,
|
|
1102
|
+
...(conn.sourceNodeId === nodeId
|
|
1103
|
+
? { sourceSwimlaneIndex: toSwimlaneIndex }
|
|
1104
|
+
: {}),
|
|
1105
|
+
...(conn.targetNodeId === nodeId
|
|
1106
|
+
? { targetSwimlaneIndex: toSwimlaneIndex }
|
|
1107
|
+
: {}),
|
|
1108
|
+
};
|
|
1109
|
+
});
|
|
1110
|
+
|
|
1111
|
+
// ── Sync node metadata to the destination swimlane ────────────────────
|
|
1112
|
+
node.stageData = {
|
|
1113
|
+
...node.stageData,
|
|
1114
|
+
Tags: [...(toSwimlane.tags || [])],
|
|
1115
|
+
SwimLane: toSwimlane.id || '',
|
|
1116
|
+
};
|
|
1117
|
+
|
|
1118
|
+
return node;
|
|
1119
|
+
}
|
|
1120
|
+
|
|
1121
|
+
/** Swimlane height constant used for coordinate conversions. */
|
|
1122
|
+
readonly swimlaneHeight = 263;
|
|
1123
|
+
}
|