verben-workflow-ui 0.6.4 → 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 +9 -194
- 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,1437 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ChangeDetectorRef,
|
|
3
|
+
Component,
|
|
4
|
+
Input,
|
|
5
|
+
OnInit,
|
|
6
|
+
ViewChild,
|
|
7
|
+
} from '@angular/core';
|
|
8
|
+
import { ActivatedRoute, ParamMap } from '@angular/router';
|
|
9
|
+
import { debounceTime, Subject } from 'rxjs';
|
|
10
|
+
import {
|
|
11
|
+
CardData,
|
|
12
|
+
CardDataViewComponent,
|
|
13
|
+
ColumnDefinition,
|
|
14
|
+
DataFilterType,
|
|
15
|
+
DataViewComponent,
|
|
16
|
+
IDataFilter,
|
|
17
|
+
} from 'verben-ng-ui';
|
|
18
|
+
import { workflowBaseStyle as baseStyle } from 'verben-workflow-ui/src/lib/components/workflow';
|
|
19
|
+
import {
|
|
20
|
+
DataType,
|
|
21
|
+
ErrorResponse,
|
|
22
|
+
FormValue,
|
|
23
|
+
ObjectState,
|
|
24
|
+
PagedResult,
|
|
25
|
+
PermissionConfig,
|
|
26
|
+
SearchOperator,
|
|
27
|
+
SearchPropertySign,
|
|
28
|
+
SearchPropertyValue,
|
|
29
|
+
SearchPropertyValueType,
|
|
30
|
+
SortDirection,
|
|
31
|
+
} from 'verben-workflow-ui/src/lib/models';
|
|
32
|
+
import {
|
|
33
|
+
EnvironmentService,
|
|
34
|
+
HttpWebRequestService,
|
|
35
|
+
UtilService,
|
|
36
|
+
} from 'verben-workflow-ui/src/lib/services';
|
|
37
|
+
import { FormValuesService } from './form-values.service';
|
|
38
|
+
|
|
39
|
+
export enum FormValuePropertyName {
|
|
40
|
+
Code = 'Code',
|
|
41
|
+
CreatedBy = 'Created By',
|
|
42
|
+
CreatedAt = 'Created At',
|
|
43
|
+
IsValid = 'Is Valid',
|
|
44
|
+
AllowAnonymous = 'Anonymous',
|
|
45
|
+
ExpiryDate = 'Expiry Date',
|
|
46
|
+
Duration = 'Duration',
|
|
47
|
+
TaskCode = 'Task Code',
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export enum FormValuePropertyMap {
|
|
51
|
+
Code = 'Code',
|
|
52
|
+
CreatedBy = 'CreatedBy',
|
|
53
|
+
CreatedAt = 'CreatedAt',
|
|
54
|
+
IsValid = 'IsValid',
|
|
55
|
+
AllowAnonymous = 'AllowAnonymous',
|
|
56
|
+
ExpiryDate = 'ExpiryDate',
|
|
57
|
+
Duration = 'Duration',
|
|
58
|
+
TaskCode = 'TaskCode',
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export enum FormValueSearchProperty {
|
|
62
|
+
Code = 'Code',
|
|
63
|
+
CreatedBy = 'CreatedBy',
|
|
64
|
+
TaskCode = 'TaskCode',
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
enum FilterTypes {
|
|
68
|
+
Before = SearchPropertySign.LT,
|
|
69
|
+
On = SearchPropertySign.EQ,
|
|
70
|
+
After = SearchPropertySign.GT,
|
|
71
|
+
NEQ = SearchPropertySign.NEQ,
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export interface EntityTableExport {
|
|
75
|
+
entityName: string;
|
|
76
|
+
columns: string[];
|
|
77
|
+
rows: Record<string, any>[];
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
@Component({
|
|
81
|
+
selector: 'lib-form-values',
|
|
82
|
+
templateUrl: './form-values.component.html',
|
|
83
|
+
styleUrl: './form-values.component.css',
|
|
84
|
+
})
|
|
85
|
+
export class FormValuesComponent implements OnInit {
|
|
86
|
+
visibleColumnDef: ColumnDefinition<FormValue>[] = [];
|
|
87
|
+
styles = baseStyle;
|
|
88
|
+
data: FormValue[] = [];
|
|
89
|
+
cardData: CardData[] = [];
|
|
90
|
+
currentData: CardData | null = null;
|
|
91
|
+
active: number = 0;
|
|
92
|
+
dataType: DataType = DataType.Text;
|
|
93
|
+
exportColumns: ColumnDefinition<any>[] = [];
|
|
94
|
+
exportData: any[] = [];
|
|
95
|
+
showExport: boolean = false;
|
|
96
|
+
|
|
97
|
+
@ViewChild('vdcv') cardDataView!: CardDataViewComponent;
|
|
98
|
+
@ViewChild('vdv') dataView!: DataViewComponent;
|
|
99
|
+
@ViewChild('dataXport') dataXport!: any;
|
|
100
|
+
|
|
101
|
+
@Input() formCodeKey: string = 'formCode';
|
|
102
|
+
@Input() pageSize: number = 50;
|
|
103
|
+
@Input() searchDebounceTime: number = 500;
|
|
104
|
+
@Input() permissionConfig: PermissionConfig | null = null;
|
|
105
|
+
|
|
106
|
+
formCode: string = '';
|
|
107
|
+
pageState: PagedResult<FormValue> | null = null;
|
|
108
|
+
currentFilters: IDataFilter[] = [];
|
|
109
|
+
currentSorts: IDataFilter[] = [];
|
|
110
|
+
searchTerm$ = new Subject<string>();
|
|
111
|
+
private currentSearchTerm: string = '';
|
|
112
|
+
hasMore: boolean = true;
|
|
113
|
+
|
|
114
|
+
visibleColumns: IDataFilter[] = [];
|
|
115
|
+
|
|
116
|
+
filterArray: IDataFilter[] = [
|
|
117
|
+
{
|
|
118
|
+
name: FormValuePropertyName.Code,
|
|
119
|
+
type: DataFilterType.String,
|
|
120
|
+
checked: false,
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
name: FormValuePropertyName.CreatedBy,
|
|
124
|
+
type: DataFilterType.String,
|
|
125
|
+
checked: false,
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
name: FormValuePropertyName.CreatedAt,
|
|
129
|
+
type: DataFilterType.Date,
|
|
130
|
+
checked: false,
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
name: FormValuePropertyName.IsValid,
|
|
134
|
+
type: DataFilterType.Bool,
|
|
135
|
+
checked: false,
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
name: FormValuePropertyName.AllowAnonymous,
|
|
139
|
+
type: DataFilterType.Bool,
|
|
140
|
+
checked: false,
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
name: FormValuePropertyName.ExpiryDate,
|
|
144
|
+
type: DataFilterType.Date,
|
|
145
|
+
checked: false,
|
|
146
|
+
},
|
|
147
|
+
];
|
|
148
|
+
|
|
149
|
+
sortOptions: IDataFilter[] = [
|
|
150
|
+
{
|
|
151
|
+
name: FormValuePropertyName.CreatedAt,
|
|
152
|
+
type: DataFilterType.Date,
|
|
153
|
+
checked: false,
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
name: FormValuePropertyName.CreatedBy,
|
|
157
|
+
type: DataFilterType.String,
|
|
158
|
+
checked: false,
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
name: FormValuePropertyName.Code,
|
|
162
|
+
type: DataFilterType.String,
|
|
163
|
+
checked: false,
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
name: FormValuePropertyName.ExpiryDate,
|
|
167
|
+
type: DataFilterType.Date,
|
|
168
|
+
checked: false,
|
|
169
|
+
},
|
|
170
|
+
];
|
|
171
|
+
|
|
172
|
+
constructor(
|
|
173
|
+
private utilService: UtilService,
|
|
174
|
+
private server: HttpWebRequestService,
|
|
175
|
+
private cdr: ChangeDetectorRef,
|
|
176
|
+
private envSvc: EnvironmentService,
|
|
177
|
+
private route: ActivatedRoute,
|
|
178
|
+
private formValuesSvc: FormValuesService,
|
|
179
|
+
) {
|
|
180
|
+
this.visibleColumnDef = formValuesSvc.formValueColumns;
|
|
181
|
+
this.visibleColumns = formValuesSvc.formValueColumns.map((col) => ({
|
|
182
|
+
checked: true,
|
|
183
|
+
name: typeof col.header === 'string' ? col.header : col.id,
|
|
184
|
+
type: DataFilterType.Bool,
|
|
185
|
+
}));
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
get allowFormResponseEdit(): boolean {
|
|
189
|
+
return !!this.permissionConfig?.Actions?.['AllowFormResponseEdit'];
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
async ngOnInit(): Promise<void> {
|
|
193
|
+
this.active = 0;
|
|
194
|
+
|
|
195
|
+
this.route.paramMap.subscribe(async (params: ParamMap) => {
|
|
196
|
+
const code = params.get(this.formCodeKey);
|
|
197
|
+
this.formCode = code ? code.trim() : '';
|
|
198
|
+
await this.initData();
|
|
199
|
+
});
|
|
200
|
+
|
|
201
|
+
this.searchTerm$
|
|
202
|
+
.pipe(debounceTime(this.searchDebounceTime))
|
|
203
|
+
.subscribe(async (searchTerm) => {
|
|
204
|
+
this.currentSearchTerm = searchTerm;
|
|
205
|
+
this.updateFiltersAndSorts(true);
|
|
206
|
+
});
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
async initData(): Promise<void> {
|
|
210
|
+
this.data = [];
|
|
211
|
+
this.currentData = null;
|
|
212
|
+
this.pageState = null;
|
|
213
|
+
this.hasMore = true;
|
|
214
|
+
this.active = 0;
|
|
215
|
+
|
|
216
|
+
const values = await this.getFormValues();
|
|
217
|
+
if (values) {
|
|
218
|
+
this.data = values.map((x) => ({
|
|
219
|
+
...x,
|
|
220
|
+
Id: x.Code || x.Id,
|
|
221
|
+
id: x.Code || x.id,
|
|
222
|
+
CreatedAt: x.CreatedAt ? new Date(x.CreatedAt.toString()) : new Date(),
|
|
223
|
+
ExpiryDate: x.ExpiryDate
|
|
224
|
+
? new Date(x.ExpiryDate.toString())
|
|
225
|
+
: new Date(),
|
|
226
|
+
}));
|
|
227
|
+
this.setUpCardData();
|
|
228
|
+
if (this.cardData.length === 1) {
|
|
229
|
+
this.cardClicked(this.cardData[0]);
|
|
230
|
+
}
|
|
231
|
+
} else {
|
|
232
|
+
this.setUpCardData();
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
async getFormValues(): Promise<FormValue[] | undefined> {
|
|
237
|
+
const payload: SearchPropertyValue[] = [];
|
|
238
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
239
|
+
payload.push({
|
|
240
|
+
PropertyName: 'Form',
|
|
241
|
+
EntityValue: this.formCode,
|
|
242
|
+
Operator: SearchOperator.And,
|
|
243
|
+
Sign: SearchPropertySign.EQ,
|
|
244
|
+
});
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
this.utilService.sendBI(true);
|
|
248
|
+
const res =
|
|
249
|
+
payload.length === 0
|
|
250
|
+
? await this.server.get(
|
|
251
|
+
`GetFormValues/0/${this.pageSize}/CreatedAt/${SortDirection.Desc}`,
|
|
252
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
253
|
+
)
|
|
254
|
+
: await this.server.post(
|
|
255
|
+
`SearchFormValues/0/${this.pageSize}`,
|
|
256
|
+
payload,
|
|
257
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
258
|
+
);
|
|
259
|
+
this.utilService.sendBI(false);
|
|
260
|
+
|
|
261
|
+
if (res instanceof ErrorResponse) {
|
|
262
|
+
return undefined;
|
|
263
|
+
} else {
|
|
264
|
+
this.pageState = res as PagedResult<FormValue>;
|
|
265
|
+
const result = (res as PagedResult<FormValue>).Result || [];
|
|
266
|
+
this.hasMore =
|
|
267
|
+
(res as PagedResult<FormValue>).Total !== undefined
|
|
268
|
+
? this.data.length + result.length <
|
|
269
|
+
(res as PagedResult<FormValue>).Total
|
|
270
|
+
: result.length === this.pageSize;
|
|
271
|
+
return result;
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
async loadMore(): Promise<void> {
|
|
276
|
+
if (!this.pageState) {
|
|
277
|
+
return;
|
|
278
|
+
}
|
|
279
|
+
this.utilService.sendBI(true);
|
|
280
|
+
const res =
|
|
281
|
+
this.currentFilters.length > 0 ||
|
|
282
|
+
this.currentSorts.length > 0 ||
|
|
283
|
+
this.currentSearchTerm.trim().length > 0
|
|
284
|
+
? await this.loadMoreFiltersAndSorts()
|
|
285
|
+
: this.formCode && this.formCode.length > 0
|
|
286
|
+
? await this.server.post(
|
|
287
|
+
`SearchFormValues/${this.pageState.Skip}/${this.pageSize}`,
|
|
288
|
+
[
|
|
289
|
+
{
|
|
290
|
+
PropertyName: 'Form',
|
|
291
|
+
EntityValue: this.formCode,
|
|
292
|
+
Operator: SearchOperator.And,
|
|
293
|
+
Sign: SearchPropertySign.EQ,
|
|
294
|
+
},
|
|
295
|
+
],
|
|
296
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
297
|
+
)
|
|
298
|
+
: await this.server.get(
|
|
299
|
+
`GetFormValues/${this.pageState.Skip}/${this.pageSize}/CreatedAt/${SortDirection.Desc}`,
|
|
300
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
301
|
+
);
|
|
302
|
+
this.utilService.sendBI(false);
|
|
303
|
+
|
|
304
|
+
if (res instanceof ErrorResponse) {
|
|
305
|
+
return;
|
|
306
|
+
} else {
|
|
307
|
+
this.pageState = res as PagedResult<FormValue>;
|
|
308
|
+
const result = (res as PagedResult<FormValue>).Result || [];
|
|
309
|
+
const mapped = result.map((x) => ({
|
|
310
|
+
...x,
|
|
311
|
+
Id: x.Code || x.Id,
|
|
312
|
+
id: x.Code || x.id,
|
|
313
|
+
CreatedAt: x.CreatedAt ? new Date(x.CreatedAt.toString()) : new Date(),
|
|
314
|
+
ExpiryDate: x.ExpiryDate
|
|
315
|
+
? new Date(x.ExpiryDate.toString())
|
|
316
|
+
: new Date(),
|
|
317
|
+
}));
|
|
318
|
+
this.data = this.data.concat(mapped);
|
|
319
|
+
this.setUpCardDataExtra(mapped);
|
|
320
|
+
this.hasMore =
|
|
321
|
+
(res as PagedResult<FormValue>).Total !== undefined
|
|
322
|
+
? this.data.length < (res as PagedResult<FormValue>).Total
|
|
323
|
+
: result.length === this.pageSize;
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
setUpCardData(): void {
|
|
328
|
+
const cardData: CardData[] = this.data.map((x) => ({
|
|
329
|
+
selected: false,
|
|
330
|
+
title: x.CreatedBy || x.Code || 'Response',
|
|
331
|
+
data: x,
|
|
332
|
+
body: [],
|
|
333
|
+
children: [],
|
|
334
|
+
}));
|
|
335
|
+
this.cardData = cardData;
|
|
336
|
+
this.updateExportColumnsAndData();
|
|
337
|
+
this.cdr.detectChanges();
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
setUpCardDataExtra(baseData: FormValue[]): void {
|
|
341
|
+
const cardData: CardData[] = baseData.map((x) => ({
|
|
342
|
+
selected: false,
|
|
343
|
+
title: x.CreatedBy || x.Code || 'Response',
|
|
344
|
+
data: x,
|
|
345
|
+
body: [],
|
|
346
|
+
children: [],
|
|
347
|
+
}));
|
|
348
|
+
this.cardData = this.cardData.concat(cardData);
|
|
349
|
+
this.updateExportColumnsAndData();
|
|
350
|
+
this.cdr.detectChanges();
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
cardClicked(item: CardData): void {
|
|
354
|
+
this.cardData.forEach((card) => (card.selected = false));
|
|
355
|
+
item.selected = true;
|
|
356
|
+
this.setActive(0);
|
|
357
|
+
this.currentData = this.cardDataView
|
|
358
|
+
? this.cardDataView.onItemClick(item)
|
|
359
|
+
: item;
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
setActive(i: number = 0): void {
|
|
363
|
+
this.active = i;
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
async saveFormValue(): Promise<void> {
|
|
367
|
+
if (!this.allowFormResponseEdit) {
|
|
368
|
+
return;
|
|
369
|
+
}
|
|
370
|
+
if (this.currentData && this.currentData.data) {
|
|
371
|
+
const formValue: FormValue = this.currentData.data as FormValue;
|
|
372
|
+
formValue.DataState =
|
|
373
|
+
formValue.DataState === ObjectState.New
|
|
374
|
+
? ObjectState.New
|
|
375
|
+
: ObjectState.Changed;
|
|
376
|
+
|
|
377
|
+
this.utilService.sendBI(true);
|
|
378
|
+
const res = await this.server.post(
|
|
379
|
+
`SaveFormValues`,
|
|
380
|
+
[formValue],
|
|
381
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
382
|
+
);
|
|
383
|
+
this.utilService.sendBI(false);
|
|
384
|
+
|
|
385
|
+
if (res instanceof ErrorResponse) {
|
|
386
|
+
} else {
|
|
387
|
+
this.utilService.showSuccess('Form response saved successfully');
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
async updateFiltersAndSorts(isSearch: boolean = false): Promise<void> {
|
|
393
|
+
if (!isSearch) {
|
|
394
|
+
if (this.dataView) {
|
|
395
|
+
this.dataView.onClearSearch();
|
|
396
|
+
}
|
|
397
|
+
this.currentSearchTerm = '';
|
|
398
|
+
this.cdr.detectChanges();
|
|
399
|
+
const clickEvent = new MouseEvent('click', {
|
|
400
|
+
bubbles: true,
|
|
401
|
+
cancelable: true,
|
|
402
|
+
view: window,
|
|
403
|
+
});
|
|
404
|
+
document.dispatchEvent(clickEvent);
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
const payload: SearchPropertyValue[] = this.currentFilters.map((x) => ({
|
|
408
|
+
PropertyName:
|
|
409
|
+
FormValuePropertyMap[
|
|
410
|
+
x.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
411
|
+
],
|
|
412
|
+
EntityValue: x.value,
|
|
413
|
+
Operator: SearchOperator.And,
|
|
414
|
+
Sign:
|
|
415
|
+
x.condition && Object.keys(FilterTypes).includes(x.condition)
|
|
416
|
+
? (FilterTypes[
|
|
417
|
+
x.condition as keyof typeof FilterTypes
|
|
418
|
+
] as unknown as SearchPropertySign)
|
|
419
|
+
: SearchPropertySign.EQ,
|
|
420
|
+
Type:
|
|
421
|
+
x.name === FormValuePropertyName.CreatedAt ||
|
|
422
|
+
x.name === FormValuePropertyName.ExpiryDate
|
|
423
|
+
? SearchPropertyValueType.Date
|
|
424
|
+
: x.name === FormValuePropertyName.AllowAnonymous ||
|
|
425
|
+
x.name === FormValuePropertyName.IsValid
|
|
426
|
+
? SearchPropertyValueType.Bool
|
|
427
|
+
: SearchPropertyValueType.String,
|
|
428
|
+
}));
|
|
429
|
+
|
|
430
|
+
for (const sort of this.currentSorts) {
|
|
431
|
+
payload.push({
|
|
432
|
+
PropertyName:
|
|
433
|
+
FormValuePropertyMap[
|
|
434
|
+
sort.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
435
|
+
],
|
|
436
|
+
EntityValue: '',
|
|
437
|
+
Operator: SearchOperator.And,
|
|
438
|
+
Sign: SearchPropertySign.EQ,
|
|
439
|
+
Sort:
|
|
440
|
+
sort.value.toLowerCase() === SortDirection.Asc.toLowerCase()
|
|
441
|
+
? SortDirection.Asc
|
|
442
|
+
: sort.value.toLowerCase() === SortDirection.Desc.toLowerCase()
|
|
443
|
+
? SortDirection.Desc
|
|
444
|
+
: SortDirection.None,
|
|
445
|
+
});
|
|
446
|
+
}
|
|
447
|
+
|
|
448
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
449
|
+
payload.push({
|
|
450
|
+
PropertyName: 'Form',
|
|
451
|
+
EntityValue: this.formCode,
|
|
452
|
+
Operator: SearchOperator.And,
|
|
453
|
+
Sign: SearchPropertySign.EQ,
|
|
454
|
+
});
|
|
455
|
+
}
|
|
456
|
+
|
|
457
|
+
const searchPayload: SearchPropertyValue[] = [];
|
|
458
|
+
const searchTermExists = this.currentSearchTerm.trim().length > 0;
|
|
459
|
+
|
|
460
|
+
if (searchTermExists) {
|
|
461
|
+
Object.keys(FormValueSearchProperty).forEach((key) => {
|
|
462
|
+
searchPayload.push({
|
|
463
|
+
PropertyName: key,
|
|
464
|
+
EntityValue: this.currentSearchTerm.trim(),
|
|
465
|
+
Operator: SearchOperator.Or,
|
|
466
|
+
Sign: SearchPropertySign.LIKE,
|
|
467
|
+
});
|
|
468
|
+
});
|
|
469
|
+
|
|
470
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
471
|
+
searchPayload.push({
|
|
472
|
+
PropertyName: 'Form',
|
|
473
|
+
EntityValue: this.formCode,
|
|
474
|
+
Operator: SearchOperator.And,
|
|
475
|
+
Sign: SearchPropertySign.EQ,
|
|
476
|
+
});
|
|
477
|
+
}
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
this.utilService.sendBI(true);
|
|
481
|
+
let res: any;
|
|
482
|
+
|
|
483
|
+
if (searchTermExists) {
|
|
484
|
+
res =
|
|
485
|
+
this.formCode && this.formCode.length > 0
|
|
486
|
+
? await this.server.post(
|
|
487
|
+
`SearchFormValues/0/${this.pageSize}`,
|
|
488
|
+
searchPayload,
|
|
489
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
490
|
+
)
|
|
491
|
+
: await this.server.get(
|
|
492
|
+
`GetFormValuesWithParam/${this.currentSearchTerm.trim()}/0/${
|
|
493
|
+
this.pageSize
|
|
494
|
+
}`,
|
|
495
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
496
|
+
);
|
|
497
|
+
} else {
|
|
498
|
+
res =
|
|
499
|
+
payload.length === 0
|
|
500
|
+
? await this.server.get(
|
|
501
|
+
`GetFormValues/0/${this.pageSize}`,
|
|
502
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
503
|
+
)
|
|
504
|
+
: await this.server.post(
|
|
505
|
+
`SearchFormValues/0/${this.pageSize}`,
|
|
506
|
+
payload,
|
|
507
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
508
|
+
);
|
|
509
|
+
}
|
|
510
|
+
this.utilService.sendBI(false);
|
|
511
|
+
|
|
512
|
+
if (res instanceof ErrorResponse) {
|
|
513
|
+
this.currentFilters = [];
|
|
514
|
+
this.currentSorts = [];
|
|
515
|
+
return;
|
|
516
|
+
} else {
|
|
517
|
+
if (this.cardDataView) {
|
|
518
|
+
this.cardDataView.clearData();
|
|
519
|
+
}
|
|
520
|
+
this.currentData = null;
|
|
521
|
+
this.pageState = res as PagedResult<FormValue>;
|
|
522
|
+
const result = (res as PagedResult<FormValue>).Result || [];
|
|
523
|
+
this.data = result.map((x) => ({
|
|
524
|
+
...x,
|
|
525
|
+
Id: x.Code || x.Id,
|
|
526
|
+
id: x.Code || x.id,
|
|
527
|
+
CreatedAt: x.CreatedAt ? new Date(x.CreatedAt.toString()) : new Date(),
|
|
528
|
+
ExpiryDate: x.ExpiryDate
|
|
529
|
+
? new Date(x.ExpiryDate.toString())
|
|
530
|
+
: new Date(),
|
|
531
|
+
}));
|
|
532
|
+
this.setUpCardData();
|
|
533
|
+
if (this.cardData.length > 0) {
|
|
534
|
+
this.cardClicked(this.cardData[0]);
|
|
535
|
+
}
|
|
536
|
+
this.hasMore =
|
|
537
|
+
(res as PagedResult<FormValue>).Total !== undefined
|
|
538
|
+
? this.data.length < (res as PagedResult<FormValue>).Total
|
|
539
|
+
: result.length === this.pageSize;
|
|
540
|
+
}
|
|
541
|
+
}
|
|
542
|
+
|
|
543
|
+
async loadMoreFiltersAndSorts(): Promise<PagedResult<FormValue> | undefined> {
|
|
544
|
+
if (!this.pageState) {
|
|
545
|
+
return;
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
const payload: SearchPropertyValue[] = this.currentFilters.map((x) => ({
|
|
549
|
+
PropertyName:
|
|
550
|
+
FormValuePropertyMap[
|
|
551
|
+
x.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
552
|
+
],
|
|
553
|
+
EntityValue: x.value,
|
|
554
|
+
Operator: SearchOperator.And,
|
|
555
|
+
Sign:
|
|
556
|
+
x.condition && Object.keys(FilterTypes).includes(x.condition)
|
|
557
|
+
? (FilterTypes[
|
|
558
|
+
x.condition as keyof typeof FilterTypes
|
|
559
|
+
] as unknown as SearchPropertySign)
|
|
560
|
+
: SearchPropertySign.EQ,
|
|
561
|
+
Type:
|
|
562
|
+
x.name === FormValuePropertyName.CreatedAt ||
|
|
563
|
+
x.name === FormValuePropertyName.ExpiryDate
|
|
564
|
+
? SearchPropertyValueType.Date
|
|
565
|
+
: x.name === FormValuePropertyName.AllowAnonymous ||
|
|
566
|
+
x.name === FormValuePropertyName.IsValid
|
|
567
|
+
? SearchPropertyValueType.Bool
|
|
568
|
+
: SearchPropertyValueType.String,
|
|
569
|
+
}));
|
|
570
|
+
|
|
571
|
+
for (const sort of this.currentSorts) {
|
|
572
|
+
payload.push({
|
|
573
|
+
PropertyName:
|
|
574
|
+
FormValuePropertyMap[
|
|
575
|
+
sort.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
576
|
+
],
|
|
577
|
+
EntityValue: '',
|
|
578
|
+
Operator: SearchOperator.And,
|
|
579
|
+
Sign: SearchPropertySign.EQ,
|
|
580
|
+
Sort:
|
|
581
|
+
sort.value.toLowerCase() === SortDirection.Asc.toLowerCase()
|
|
582
|
+
? SortDirection.Asc
|
|
583
|
+
: sort.value.toLowerCase() === SortDirection.Desc.toLowerCase()
|
|
584
|
+
? SortDirection.Desc
|
|
585
|
+
: SortDirection.None,
|
|
586
|
+
});
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
590
|
+
payload.push({
|
|
591
|
+
PropertyName: 'Form',
|
|
592
|
+
EntityValue: this.formCode,
|
|
593
|
+
Operator: SearchOperator.And,
|
|
594
|
+
Sign: SearchPropertySign.EQ,
|
|
595
|
+
});
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
const searchPayload: SearchPropertyValue[] = [];
|
|
599
|
+
const searchTermExists = this.currentSearchTerm.trim().length > 0;
|
|
600
|
+
|
|
601
|
+
if (searchTermExists) {
|
|
602
|
+
Object.keys(FormValueSearchProperty).forEach((key) => {
|
|
603
|
+
searchPayload.push({
|
|
604
|
+
PropertyName: key,
|
|
605
|
+
EntityValue: this.currentSearchTerm.trim(),
|
|
606
|
+
Operator: SearchOperator.Or,
|
|
607
|
+
Sign: SearchPropertySign.LIKE,
|
|
608
|
+
});
|
|
609
|
+
});
|
|
610
|
+
|
|
611
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
612
|
+
searchPayload.push({
|
|
613
|
+
PropertyName: 'Form',
|
|
614
|
+
EntityValue: this.formCode,
|
|
615
|
+
Operator: SearchOperator.And,
|
|
616
|
+
Sign: SearchPropertySign.EQ,
|
|
617
|
+
});
|
|
618
|
+
}
|
|
619
|
+
}
|
|
620
|
+
|
|
621
|
+
this.utilService.sendBI(true);
|
|
622
|
+
let res: any;
|
|
623
|
+
|
|
624
|
+
if (searchTermExists) {
|
|
625
|
+
res =
|
|
626
|
+
this.formCode && this.formCode.length > 0
|
|
627
|
+
? await this.server.post(
|
|
628
|
+
`SearchFormValues/${this.pageState.Skip}/${this.pageSize}`,
|
|
629
|
+
searchPayload,
|
|
630
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
631
|
+
)
|
|
632
|
+
: await this.server.get(
|
|
633
|
+
`GetFormValuesWithParam/${this.currentSearchTerm.trim()}/${
|
|
634
|
+
this.pageState.Skip
|
|
635
|
+
}/${this.pageSize}`,
|
|
636
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
637
|
+
);
|
|
638
|
+
} else {
|
|
639
|
+
res =
|
|
640
|
+
payload.length === 0
|
|
641
|
+
? await this.server.get(
|
|
642
|
+
`GetFormValues/${this.pageState.Skip}/${this.pageSize}`,
|
|
643
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
644
|
+
)
|
|
645
|
+
: await this.server.post(
|
|
646
|
+
`SearchFormValues/${this.pageState.Skip}/${this.pageSize}`,
|
|
647
|
+
payload,
|
|
648
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
649
|
+
);
|
|
650
|
+
}
|
|
651
|
+
this.utilService.sendBI(false);
|
|
652
|
+
|
|
653
|
+
if (res instanceof ErrorResponse) {
|
|
654
|
+
return undefined;
|
|
655
|
+
} else {
|
|
656
|
+
return res as PagedResult<FormValue>;
|
|
657
|
+
}
|
|
658
|
+
}
|
|
659
|
+
|
|
660
|
+
onFilterUpdated(updatedFilters: IDataFilter[] | string): void {
|
|
661
|
+
if (Array.isArray(updatedFilters)) {
|
|
662
|
+
this.currentFilters = updatedFilters;
|
|
663
|
+
this.updateFiltersAndSorts();
|
|
664
|
+
}
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
onSortUpdated(updatedSorts: IDataFilter[]): void {
|
|
668
|
+
this.currentSorts = updatedSorts;
|
|
669
|
+
this.updateFiltersAndSorts();
|
|
670
|
+
}
|
|
671
|
+
|
|
672
|
+
handleSearch(event: { key: string; value: string }): void {
|
|
673
|
+
this.searchTerm$.next(event.value);
|
|
674
|
+
}
|
|
675
|
+
|
|
676
|
+
onStateChange(event: { key: string; value: boolean }): void {}
|
|
677
|
+
|
|
678
|
+
onViewChange(isGridView: boolean): void {}
|
|
679
|
+
|
|
680
|
+
// ---------------- Export Logic ----------------
|
|
681
|
+
|
|
682
|
+
isFileInput(dataType: any): boolean {
|
|
683
|
+
if (!dataType) return false;
|
|
684
|
+
const str = String(dataType).toLowerCase();
|
|
685
|
+
return (
|
|
686
|
+
str.includes('file') ||
|
|
687
|
+
str === 'image' ||
|
|
688
|
+
str === 'video' ||
|
|
689
|
+
str === 'audio' ||
|
|
690
|
+
dataType === DataType.Image ||
|
|
691
|
+
dataType === DataType.Video ||
|
|
692
|
+
dataType === DataType.Audio ||
|
|
693
|
+
dataType === DataType.SingleFileSelection ||
|
|
694
|
+
dataType === DataType.MultiFileSelection
|
|
695
|
+
);
|
|
696
|
+
}
|
|
697
|
+
|
|
698
|
+
getEntitiesFromRecord(record: any): any[] {
|
|
699
|
+
if (!record) return [];
|
|
700
|
+
let entities =
|
|
701
|
+
record.EntityValues ??
|
|
702
|
+
record.Entities ??
|
|
703
|
+
record.entityValues ??
|
|
704
|
+
record.entities ??
|
|
705
|
+
record.Groups ??
|
|
706
|
+
record.groups;
|
|
707
|
+
if (typeof entities === 'string') {
|
|
708
|
+
try {
|
|
709
|
+
entities = JSON.parse(entities);
|
|
710
|
+
} catch {
|
|
711
|
+
entities = [];
|
|
712
|
+
}
|
|
713
|
+
}
|
|
714
|
+
if (Array.isArray(entities)) {
|
|
715
|
+
return entities;
|
|
716
|
+
}
|
|
717
|
+
if (entities && typeof entities === 'object') {
|
|
718
|
+
return [entities];
|
|
719
|
+
}
|
|
720
|
+
return [];
|
|
721
|
+
}
|
|
722
|
+
|
|
723
|
+
getEntityProperties(entityVal: any): any[] {
|
|
724
|
+
if (!entityVal) return [];
|
|
725
|
+
let props =
|
|
726
|
+
entityVal.Values ??
|
|
727
|
+
entityVal.Properties ??
|
|
728
|
+
entityVal.values ??
|
|
729
|
+
entityVal.properties;
|
|
730
|
+
if (typeof props === 'string') {
|
|
731
|
+
try {
|
|
732
|
+
props = JSON.parse(props);
|
|
733
|
+
} catch {
|
|
734
|
+
props = [];
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
if (Array.isArray(props)) {
|
|
738
|
+
return props;
|
|
739
|
+
}
|
|
740
|
+
return [];
|
|
741
|
+
}
|
|
742
|
+
|
|
743
|
+
groupFormValuesByEntity(rawList: FormValue[]): EntityTableExport[] {
|
|
744
|
+
if (!rawList || rawList.length === 0) {
|
|
745
|
+
return [];
|
|
746
|
+
}
|
|
747
|
+
|
|
748
|
+
const entityMap = new Map<
|
|
749
|
+
string,
|
|
750
|
+
{ propertyNames: Set<string>; rows: Record<string, any>[] }
|
|
751
|
+
>();
|
|
752
|
+
|
|
753
|
+
for (const record of rawList) {
|
|
754
|
+
const entities = this.getEntitiesFromRecord(record);
|
|
755
|
+
|
|
756
|
+
const baseRow: Record<string, any> = {
|
|
757
|
+
SubmissionCode: record.Code || record.Id || (record as any).id || '',
|
|
758
|
+
'Submission Code': record.Code || record.Id || (record as any).id || '',
|
|
759
|
+
CreatedBy: record.CreatedBy || (record as any).createdBy || '',
|
|
760
|
+
'Created By': record.CreatedBy || (record as any).createdBy || '',
|
|
761
|
+
SubmissionDate: record.CreatedAt
|
|
762
|
+
? new Date(record.CreatedAt).toLocaleString()
|
|
763
|
+
: '',
|
|
764
|
+
'Submission Date': record.CreatedAt
|
|
765
|
+
? new Date(record.CreatedAt).toLocaleString()
|
|
766
|
+
: '',
|
|
767
|
+
};
|
|
768
|
+
|
|
769
|
+
if (entities.length === 0) {
|
|
770
|
+
const entityName = record.Form ? String(record.Form).trim() : 'General';
|
|
771
|
+
if (!entityMap.has(entityName)) {
|
|
772
|
+
entityMap.set(entityName, {
|
|
773
|
+
propertyNames: new Set<string>(),
|
|
774
|
+
rows: [],
|
|
775
|
+
});
|
|
776
|
+
}
|
|
777
|
+
const group = entityMap.get(entityName)!;
|
|
778
|
+
group.rows.push({
|
|
779
|
+
FormEntity: entityName,
|
|
780
|
+
'Form Entity': entityName,
|
|
781
|
+
...baseRow,
|
|
782
|
+
});
|
|
783
|
+
continue;
|
|
784
|
+
}
|
|
785
|
+
|
|
786
|
+
for (const entityVal of entities) {
|
|
787
|
+
const entityName = (
|
|
788
|
+
entityVal.EntityName ||
|
|
789
|
+
entityVal.Name ||
|
|
790
|
+
entityVal.entityName ||
|
|
791
|
+
entityVal.name ||
|
|
792
|
+
record.Form ||
|
|
793
|
+
'General'
|
|
794
|
+
)
|
|
795
|
+
.toString()
|
|
796
|
+
.trim();
|
|
797
|
+
|
|
798
|
+
if (!entityMap.has(entityName)) {
|
|
799
|
+
entityMap.set(entityName, {
|
|
800
|
+
propertyNames: new Set<string>(),
|
|
801
|
+
rows: [],
|
|
802
|
+
});
|
|
803
|
+
}
|
|
804
|
+
|
|
805
|
+
const group = entityMap.get(entityName)!;
|
|
806
|
+
const row: Record<string, any> = {
|
|
807
|
+
FormEntity: entityName,
|
|
808
|
+
'Form Entity': entityName,
|
|
809
|
+
...baseRow,
|
|
810
|
+
};
|
|
811
|
+
|
|
812
|
+
const props = this.getEntityProperties(entityVal);
|
|
813
|
+
for (const prop of props) {
|
|
814
|
+
if (this.isFileInput(prop.DataType || prop.dataType)) {
|
|
815
|
+
continue;
|
|
816
|
+
}
|
|
817
|
+
const propName = (
|
|
818
|
+
prop.Name ||
|
|
819
|
+
prop.PropertyName ||
|
|
820
|
+
prop.name ||
|
|
821
|
+
prop.propertyName ||
|
|
822
|
+
prop.Label ||
|
|
823
|
+
prop.label ||
|
|
824
|
+
'Property'
|
|
825
|
+
)
|
|
826
|
+
.toString()
|
|
827
|
+
.trim();
|
|
828
|
+
|
|
829
|
+
const propValue =
|
|
830
|
+
prop.Value !== undefined && prop.Value !== null
|
|
831
|
+
? prop.Value
|
|
832
|
+
: prop.value !== undefined && prop.value !== null
|
|
833
|
+
? prop.value
|
|
834
|
+
: '';
|
|
835
|
+
|
|
836
|
+
group.propertyNames.add(propName);
|
|
837
|
+
row[propName] = propValue;
|
|
838
|
+
}
|
|
839
|
+
|
|
840
|
+
group.rows.push(row);
|
|
841
|
+
}
|
|
842
|
+
}
|
|
843
|
+
|
|
844
|
+
const tables: EntityTableExport[] = [];
|
|
845
|
+
entityMap.forEach((group, entityName) => {
|
|
846
|
+
const columns = [
|
|
847
|
+
'Form Entity',
|
|
848
|
+
'Submission Code',
|
|
849
|
+
'Created By',
|
|
850
|
+
'Submission Date',
|
|
851
|
+
...Array.from(group.propertyNames),
|
|
852
|
+
];
|
|
853
|
+
|
|
854
|
+
tables.push({
|
|
855
|
+
entityName,
|
|
856
|
+
columns,
|
|
857
|
+
rows: group.rows,
|
|
858
|
+
});
|
|
859
|
+
});
|
|
860
|
+
|
|
861
|
+
return tables;
|
|
862
|
+
}
|
|
863
|
+
|
|
864
|
+
exportFiltersAndSorts = async (pageState: {
|
|
865
|
+
skip: number;
|
|
866
|
+
limit: number;
|
|
867
|
+
}): Promise<any> => {
|
|
868
|
+
const payload: SearchPropertyValue[] = this.currentFilters.map((x) => ({
|
|
869
|
+
PropertyName:
|
|
870
|
+
FormValuePropertyMap[
|
|
871
|
+
x.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
872
|
+
],
|
|
873
|
+
EntityValue: x.value,
|
|
874
|
+
Operator: SearchOperator.And,
|
|
875
|
+
Sign:
|
|
876
|
+
x.condition && Object.keys(FilterTypes).includes(x.condition)
|
|
877
|
+
? (FilterTypes[
|
|
878
|
+
x.condition as keyof typeof FilterTypes
|
|
879
|
+
] as unknown as SearchPropertySign)
|
|
880
|
+
: SearchPropertySign.EQ,
|
|
881
|
+
Type:
|
|
882
|
+
x.name === FormValuePropertyName.CreatedAt ||
|
|
883
|
+
x.name === FormValuePropertyName.ExpiryDate
|
|
884
|
+
? SearchPropertyValueType.Date
|
|
885
|
+
: x.name === FormValuePropertyName.AllowAnonymous ||
|
|
886
|
+
x.name === FormValuePropertyName.IsValid
|
|
887
|
+
? SearchPropertyValueType.Bool
|
|
888
|
+
: SearchPropertyValueType.String,
|
|
889
|
+
}));
|
|
890
|
+
|
|
891
|
+
for (const sort of this.currentSorts) {
|
|
892
|
+
payload.push({
|
|
893
|
+
PropertyName:
|
|
894
|
+
FormValuePropertyMap[
|
|
895
|
+
sort.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
896
|
+
],
|
|
897
|
+
EntityValue: '',
|
|
898
|
+
Operator: SearchOperator.And,
|
|
899
|
+
Sign: SearchPropertySign.EQ,
|
|
900
|
+
Sort:
|
|
901
|
+
sort.value.toLowerCase() === SortDirection.Asc.toLowerCase()
|
|
902
|
+
? SortDirection.Asc
|
|
903
|
+
: sort.value.toLowerCase() === SortDirection.Desc.toLowerCase()
|
|
904
|
+
? SortDirection.Desc
|
|
905
|
+
: SortDirection.None,
|
|
906
|
+
});
|
|
907
|
+
}
|
|
908
|
+
|
|
909
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
910
|
+
payload.push({
|
|
911
|
+
PropertyName: 'Form',
|
|
912
|
+
EntityValue: this.formCode,
|
|
913
|
+
Operator: SearchOperator.And,
|
|
914
|
+
Sign: SearchPropertySign.EQ,
|
|
915
|
+
});
|
|
916
|
+
}
|
|
917
|
+
|
|
918
|
+
const searchPayload: SearchPropertyValue[] = [];
|
|
919
|
+
const searchTermExists = this.currentSearchTerm.trim().length > 0;
|
|
920
|
+
|
|
921
|
+
if (searchTermExists) {
|
|
922
|
+
Object.keys(FormValueSearchProperty).forEach((key) => {
|
|
923
|
+
searchPayload.push({
|
|
924
|
+
PropertyName: key,
|
|
925
|
+
EntityValue: this.currentSearchTerm.trim(),
|
|
926
|
+
Operator: SearchOperator.Or,
|
|
927
|
+
Sign: SearchPropertySign.LIKE,
|
|
928
|
+
});
|
|
929
|
+
});
|
|
930
|
+
|
|
931
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
932
|
+
searchPayload.push({
|
|
933
|
+
PropertyName: 'Form',
|
|
934
|
+
EntityValue: this.formCode,
|
|
935
|
+
Operator: SearchOperator.And,
|
|
936
|
+
Sign: SearchPropertySign.EQ,
|
|
937
|
+
});
|
|
938
|
+
}
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
const skip = pageState.skip || 0;
|
|
942
|
+
const limit =
|
|
943
|
+
pageState.limit && pageState.limit > 0
|
|
944
|
+
? pageState.limit
|
|
945
|
+
: this.pageState?.Total && this.pageState.Total > 0
|
|
946
|
+
? this.pageState.Total
|
|
947
|
+
: 10000;
|
|
948
|
+
|
|
949
|
+
this.utilService.sendBI(true);
|
|
950
|
+
let res: any;
|
|
951
|
+
|
|
952
|
+
if (searchTermExists) {
|
|
953
|
+
res =
|
|
954
|
+
this.formCode && this.formCode.length > 0
|
|
955
|
+
? await this.server.post(
|
|
956
|
+
`SearchFormValues/${skip}/${limit}`,
|
|
957
|
+
searchPayload,
|
|
958
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
959
|
+
)
|
|
960
|
+
: await this.server.get(
|
|
961
|
+
`GetFormValuesWithParam/${this.currentSearchTerm.trim()}/${skip}/${limit}`,
|
|
962
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
963
|
+
);
|
|
964
|
+
} else {
|
|
965
|
+
res =
|
|
966
|
+
payload.length === 0
|
|
967
|
+
? await this.server.get(
|
|
968
|
+
`GetFormValues/${skip}/${limit}`,
|
|
969
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
970
|
+
)
|
|
971
|
+
: await this.server.post(
|
|
972
|
+
`SearchFormValues/${skip}/${limit}`,
|
|
973
|
+
payload,
|
|
974
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
975
|
+
);
|
|
976
|
+
}
|
|
977
|
+
this.utilService.sendBI(false);
|
|
978
|
+
|
|
979
|
+
if (res instanceof ErrorResponse) {
|
|
980
|
+
const tables = this.groupFormValuesByEntity(this.data);
|
|
981
|
+
const csv = this.generateMultiTableCSV(tables);
|
|
982
|
+
this.downloadCSVContent(csv, this.getExportFilename());
|
|
983
|
+
return null;
|
|
984
|
+
} else {
|
|
985
|
+
const result = (res as PagedResult<FormValue>).Result || [];
|
|
986
|
+
const dataToGroup = result.length > 0 ? result : this.data;
|
|
987
|
+
const tables = this.groupFormValuesByEntity(dataToGroup);
|
|
988
|
+
const csv = this.generateMultiTableCSV(tables);
|
|
989
|
+
this.downloadCSVContent(csv, this.getExportFilename());
|
|
990
|
+
return null;
|
|
991
|
+
}
|
|
992
|
+
};
|
|
993
|
+
|
|
994
|
+
private getFallbackExportRow(): Record<string, any>[] {
|
|
995
|
+
const fallbackRow: Record<string, any> = {};
|
|
996
|
+
const cols =
|
|
997
|
+
this.exportColumns.length > 0
|
|
998
|
+
? this.exportColumns
|
|
999
|
+
: [
|
|
1000
|
+
{
|
|
1001
|
+
id: 'formEntity',
|
|
1002
|
+
header: 'Form Entity',
|
|
1003
|
+
accessorKey: 'FormEntity',
|
|
1004
|
+
},
|
|
1005
|
+
{
|
|
1006
|
+
id: 'submissionCode',
|
|
1007
|
+
header: 'Submission Code',
|
|
1008
|
+
accessorKey: 'SubmissionCode',
|
|
1009
|
+
},
|
|
1010
|
+
{
|
|
1011
|
+
id: 'createdBy',
|
|
1012
|
+
header: 'Created By',
|
|
1013
|
+
accessorKey: 'CreatedBy',
|
|
1014
|
+
},
|
|
1015
|
+
{
|
|
1016
|
+
id: 'submissionDate',
|
|
1017
|
+
header: 'Submission Date',
|
|
1018
|
+
accessorKey: 'SubmissionDate',
|
|
1019
|
+
},
|
|
1020
|
+
];
|
|
1021
|
+
cols.forEach((c) => {
|
|
1022
|
+
const key = String(
|
|
1023
|
+
c.accessorKey || (typeof c.header === 'string' ? c.header : c.id),
|
|
1024
|
+
);
|
|
1025
|
+
fallbackRow[key] = '';
|
|
1026
|
+
});
|
|
1027
|
+
return [fallbackRow];
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
updateExportColumnsAndData(): void {
|
|
1031
|
+
const propertySet = new Set<string>();
|
|
1032
|
+
|
|
1033
|
+
for (const item of this.data) {
|
|
1034
|
+
const entities = this.getEntitiesFromRecord(item);
|
|
1035
|
+
for (const entityVal of entities) {
|
|
1036
|
+
const props = this.getEntityProperties(entityVal);
|
|
1037
|
+
for (const prop of props) {
|
|
1038
|
+
if (!this.isFileInput(prop.DataType || prop.dataType)) {
|
|
1039
|
+
const propName = (
|
|
1040
|
+
prop.Name ||
|
|
1041
|
+
prop.PropertyName ||
|
|
1042
|
+
prop.name ||
|
|
1043
|
+
prop.propertyName ||
|
|
1044
|
+
prop.Label ||
|
|
1045
|
+
prop.label ||
|
|
1046
|
+
''
|
|
1047
|
+
)
|
|
1048
|
+
.toString()
|
|
1049
|
+
.trim();
|
|
1050
|
+
if (propName) {
|
|
1051
|
+
propertySet.add(propName);
|
|
1052
|
+
}
|
|
1053
|
+
}
|
|
1054
|
+
}
|
|
1055
|
+
}
|
|
1056
|
+
}
|
|
1057
|
+
|
|
1058
|
+
const cols: ColumnDefinition<any>[] = [
|
|
1059
|
+
{
|
|
1060
|
+
id: 'formEntity',
|
|
1061
|
+
header: 'Form Entity',
|
|
1062
|
+
accessorKey: 'FormEntity',
|
|
1063
|
+
},
|
|
1064
|
+
{
|
|
1065
|
+
id: 'submissionCode',
|
|
1066
|
+
header: 'Submission Code',
|
|
1067
|
+
accessorKey: 'SubmissionCode',
|
|
1068
|
+
},
|
|
1069
|
+
{
|
|
1070
|
+
id: 'createdBy',
|
|
1071
|
+
header: 'Created By',
|
|
1072
|
+
accessorKey: 'CreatedBy',
|
|
1073
|
+
},
|
|
1074
|
+
{
|
|
1075
|
+
id: 'submissionDate',
|
|
1076
|
+
header: 'Submission Date',
|
|
1077
|
+
accessorKey: 'SubmissionDate',
|
|
1078
|
+
},
|
|
1079
|
+
];
|
|
1080
|
+
|
|
1081
|
+
propertySet.forEach((propName) => {
|
|
1082
|
+
cols.push({
|
|
1083
|
+
id: propName.toLowerCase().replace(/\s+/g, '_'),
|
|
1084
|
+
header: propName,
|
|
1085
|
+
accessorKey: propName,
|
|
1086
|
+
});
|
|
1087
|
+
});
|
|
1088
|
+
|
|
1089
|
+
this.exportColumns = cols;
|
|
1090
|
+
|
|
1091
|
+
const rows: any[] = [];
|
|
1092
|
+
const tables = this.groupFormValuesByEntity(this.data);
|
|
1093
|
+
for (const table of tables) {
|
|
1094
|
+
for (const row of table.rows) {
|
|
1095
|
+
rows.push(row);
|
|
1096
|
+
}
|
|
1097
|
+
}
|
|
1098
|
+
this.exportData = rows;
|
|
1099
|
+
|
|
1100
|
+
this.showExport = false;
|
|
1101
|
+
this.cdr.detectChanges();
|
|
1102
|
+
this.showExport = true;
|
|
1103
|
+
this.cdr.detectChanges();
|
|
1104
|
+
|
|
1105
|
+
if (this.dataXport?.exportService) {
|
|
1106
|
+
this.dataXport.exportService.downloadCSV = () => {
|
|
1107
|
+
const currentTables = this.groupFormValuesByEntity(this.data);
|
|
1108
|
+
const csv = this.generateMultiTableCSV(currentTables);
|
|
1109
|
+
this.downloadCSVContent(csv, this.getExportFilename());
|
|
1110
|
+
};
|
|
1111
|
+
}
|
|
1112
|
+
}
|
|
1113
|
+
|
|
1114
|
+
getExportFilename(): string {
|
|
1115
|
+
return this.formCode ? `${this.formCode}-values.csv` : 'export.csv';
|
|
1116
|
+
}
|
|
1117
|
+
|
|
1118
|
+
generateMultiTableCSV(tables: EntityTableExport[]): string {
|
|
1119
|
+
if (!tables || tables.length === 0) {
|
|
1120
|
+
const fallbackRow = this.getFallbackExportRow();
|
|
1121
|
+
const headers = Object.keys(fallbackRow[0]);
|
|
1122
|
+
return (
|
|
1123
|
+
headers.map((h) => `"${h.replace(/"/g, '""')}"`).join(',') +
|
|
1124
|
+
'\r\n' +
|
|
1125
|
+
headers.map(() => '""').join(',')
|
|
1126
|
+
);
|
|
1127
|
+
}
|
|
1128
|
+
|
|
1129
|
+
const sections: string[] = [];
|
|
1130
|
+
|
|
1131
|
+
for (const table of tables) {
|
|
1132
|
+
if (!table.rows || table.rows.length === 0) {
|
|
1133
|
+
continue;
|
|
1134
|
+
}
|
|
1135
|
+
|
|
1136
|
+
const headers = table.columns;
|
|
1137
|
+
const csvRows = [
|
|
1138
|
+
headers.map((h) => `"${h.replace(/"/g, '""')}"`).join(','),
|
|
1139
|
+
...table.rows.map((row) =>
|
|
1140
|
+
headers
|
|
1141
|
+
.map((header) => {
|
|
1142
|
+
const val =
|
|
1143
|
+
row[header] !== undefined && row[header] !== null
|
|
1144
|
+
? String(row[header])
|
|
1145
|
+
: '';
|
|
1146
|
+
return `"${val.replace(/"/g, '""')}"`;
|
|
1147
|
+
})
|
|
1148
|
+
.join(','),
|
|
1149
|
+
),
|
|
1150
|
+
];
|
|
1151
|
+
|
|
1152
|
+
sections.push(csvRows.join('\r\n'));
|
|
1153
|
+
}
|
|
1154
|
+
|
|
1155
|
+
return sections.join('\r\n\r\n\r\n');
|
|
1156
|
+
}
|
|
1157
|
+
|
|
1158
|
+
downloadCSVContent(csvContent: string, filename: string): void {
|
|
1159
|
+
const blob = new Blob([csvContent], { type: 'text/csv;charset=utf-8;' });
|
|
1160
|
+
const link = document.createElement('a');
|
|
1161
|
+
if (link.download !== undefined) {
|
|
1162
|
+
const url = URL.createObjectURL(blob);
|
|
1163
|
+
link.setAttribute('href', url);
|
|
1164
|
+
link.setAttribute('download', filename);
|
|
1165
|
+
link.style.visibility = 'hidden';
|
|
1166
|
+
document.body.appendChild(link);
|
|
1167
|
+
link.click();
|
|
1168
|
+
document.body.removeChild(link);
|
|
1169
|
+
}
|
|
1170
|
+
}
|
|
1171
|
+
|
|
1172
|
+
async handleExport(exportedData?: Partial<any>[]): Promise<void> {
|
|
1173
|
+
let rawList: FormValue[] = this.data;
|
|
1174
|
+
|
|
1175
|
+
if (
|
|
1176
|
+
exportedData &&
|
|
1177
|
+
exportedData.length > 0 &&
|
|
1178
|
+
(exportedData[0] as any)?.EntityValues
|
|
1179
|
+
) {
|
|
1180
|
+
rawList = exportedData as FormValue[];
|
|
1181
|
+
} else if (
|
|
1182
|
+
this.pageState &&
|
|
1183
|
+
this.pageState.Total &&
|
|
1184
|
+
this.pageState.Total > this.data.length
|
|
1185
|
+
) {
|
|
1186
|
+
try {
|
|
1187
|
+
const full = await this.fetchAllRecordsForExport(this.pageState.Total);
|
|
1188
|
+
if (full && full.length > 0) {
|
|
1189
|
+
rawList = full;
|
|
1190
|
+
}
|
|
1191
|
+
} catch (e) {
|
|
1192
|
+
rawList = this.data;
|
|
1193
|
+
}
|
|
1194
|
+
}
|
|
1195
|
+
|
|
1196
|
+
const tables = this.groupFormValuesByEntity(rawList);
|
|
1197
|
+
this.downloadCSV(tables);
|
|
1198
|
+
}
|
|
1199
|
+
|
|
1200
|
+
async fetchAllRecordsForExport(total: number): Promise<FormValue[]> {
|
|
1201
|
+
const payload: SearchPropertyValue[] = this.currentFilters.map((x) => ({
|
|
1202
|
+
PropertyName:
|
|
1203
|
+
FormValuePropertyMap[
|
|
1204
|
+
x.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
1205
|
+
],
|
|
1206
|
+
EntityValue: x.value,
|
|
1207
|
+
Operator: SearchOperator.And,
|
|
1208
|
+
Sign:
|
|
1209
|
+
x.condition && Object.keys(FilterTypes).includes(x.condition)
|
|
1210
|
+
? (FilterTypes[
|
|
1211
|
+
x.condition as keyof typeof FilterTypes
|
|
1212
|
+
] as unknown as SearchPropertySign)
|
|
1213
|
+
: SearchPropertySign.EQ,
|
|
1214
|
+
Type:
|
|
1215
|
+
x.name === FormValuePropertyName.CreatedAt ||
|
|
1216
|
+
x.name === FormValuePropertyName.ExpiryDate
|
|
1217
|
+
? SearchPropertyValueType.Date
|
|
1218
|
+
: x.name === FormValuePropertyName.AllowAnonymous ||
|
|
1219
|
+
x.name === FormValuePropertyName.IsValid
|
|
1220
|
+
? SearchPropertyValueType.Bool
|
|
1221
|
+
: SearchPropertyValueType.String,
|
|
1222
|
+
}));
|
|
1223
|
+
|
|
1224
|
+
for (const sort of this.currentSorts) {
|
|
1225
|
+
payload.push({
|
|
1226
|
+
PropertyName:
|
|
1227
|
+
FormValuePropertyMap[
|
|
1228
|
+
sort.name.split(' ').join('') as keyof typeof FormValuePropertyMap
|
|
1229
|
+
],
|
|
1230
|
+
EntityValue: '',
|
|
1231
|
+
Operator: SearchOperator.And,
|
|
1232
|
+
Sign: SearchPropertySign.EQ,
|
|
1233
|
+
Sort:
|
|
1234
|
+
sort.value.toLowerCase() === SortDirection.Asc.toLowerCase()
|
|
1235
|
+
? SortDirection.Asc
|
|
1236
|
+
: sort.value.toLowerCase() === SortDirection.Desc.toLowerCase()
|
|
1237
|
+
? SortDirection.Desc
|
|
1238
|
+
: SortDirection.None,
|
|
1239
|
+
});
|
|
1240
|
+
}
|
|
1241
|
+
|
|
1242
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
1243
|
+
payload.push({
|
|
1244
|
+
PropertyName: 'Form',
|
|
1245
|
+
EntityValue: this.formCode,
|
|
1246
|
+
Operator: SearchOperator.And,
|
|
1247
|
+
Sign: SearchPropertySign.EQ,
|
|
1248
|
+
});
|
|
1249
|
+
}
|
|
1250
|
+
|
|
1251
|
+
const searchTermExists = this.currentSearchTerm.trim().length > 0;
|
|
1252
|
+
this.utilService.sendBI(true);
|
|
1253
|
+
|
|
1254
|
+
let res: any;
|
|
1255
|
+
if (searchTermExists) {
|
|
1256
|
+
const searchPayload: SearchPropertyValue[] = [];
|
|
1257
|
+
Object.keys(FormValueSearchProperty).forEach((key) => {
|
|
1258
|
+
searchPayload.push({
|
|
1259
|
+
PropertyName: key,
|
|
1260
|
+
EntityValue: this.currentSearchTerm.trim(),
|
|
1261
|
+
Operator: SearchOperator.Or,
|
|
1262
|
+
Sign: SearchPropertySign.LIKE,
|
|
1263
|
+
});
|
|
1264
|
+
});
|
|
1265
|
+
if (this.formCode && this.formCode.length > 0) {
|
|
1266
|
+
searchPayload.push({
|
|
1267
|
+
PropertyName: 'Form',
|
|
1268
|
+
EntityValue: this.formCode,
|
|
1269
|
+
Operator: SearchOperator.And,
|
|
1270
|
+
Sign: SearchPropertySign.EQ,
|
|
1271
|
+
});
|
|
1272
|
+
}
|
|
1273
|
+
res = await this.server.post(
|
|
1274
|
+
`SearchFormValues/0/${total}`,
|
|
1275
|
+
searchPayload,
|
|
1276
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
1277
|
+
);
|
|
1278
|
+
} else {
|
|
1279
|
+
res =
|
|
1280
|
+
payload.length === 0
|
|
1281
|
+
? await this.server.get(
|
|
1282
|
+
`GetFormValues/0/${total}`,
|
|
1283
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
1284
|
+
)
|
|
1285
|
+
: await this.server.post(
|
|
1286
|
+
`SearchFormValues/0/${total}`,
|
|
1287
|
+
payload,
|
|
1288
|
+
this.envSvc.environment.WorkFlowAPI,
|
|
1289
|
+
);
|
|
1290
|
+
}
|
|
1291
|
+
this.utilService.sendBI(false);
|
|
1292
|
+
|
|
1293
|
+
if (res instanceof ErrorResponse) {
|
|
1294
|
+
return this.data;
|
|
1295
|
+
}
|
|
1296
|
+
|
|
1297
|
+
return (res as PagedResult<FormValue>).Result || this.data;
|
|
1298
|
+
}
|
|
1299
|
+
|
|
1300
|
+
downloadCSV(tables: EntityTableExport[]): void {
|
|
1301
|
+
if (!tables || tables.length === 0) {
|
|
1302
|
+
this.utilService.showError('No valid form values found to export');
|
|
1303
|
+
return;
|
|
1304
|
+
}
|
|
1305
|
+
|
|
1306
|
+
const sections: string[] = [];
|
|
1307
|
+
|
|
1308
|
+
tables.forEach((table) => {
|
|
1309
|
+
const lines: string[] = [];
|
|
1310
|
+
lines.push(this.escapeCsv(`Table: ${table.entityName}`));
|
|
1311
|
+
lines.push(table.columns.map((h) => this.escapeCsv(h)).join(','));
|
|
1312
|
+
table.rows.forEach((row) => {
|
|
1313
|
+
lines.push(
|
|
1314
|
+
table.columns
|
|
1315
|
+
.map((col) =>
|
|
1316
|
+
this.escapeCsv(
|
|
1317
|
+
row[col] !== undefined && row[col] !== null
|
|
1318
|
+
? String(row[col])
|
|
1319
|
+
: '',
|
|
1320
|
+
),
|
|
1321
|
+
)
|
|
1322
|
+
.join(','),
|
|
1323
|
+
);
|
|
1324
|
+
});
|
|
1325
|
+
sections.push(lines.join('\r\n'));
|
|
1326
|
+
});
|
|
1327
|
+
|
|
1328
|
+
const csvContent = sections.join('\r\n\r\n');
|
|
1329
|
+
const blob = new Blob([csvContent], { type: 'text/csv;charset=utf-8;' });
|
|
1330
|
+
const link = document.createElement('a');
|
|
1331
|
+
if (link.download !== undefined) {
|
|
1332
|
+
const url = URL.createObjectURL(blob);
|
|
1333
|
+
link.setAttribute('href', url);
|
|
1334
|
+
link.setAttribute(
|
|
1335
|
+
'download',
|
|
1336
|
+
`${this.formCode ? this.formCode + '-responses' : 'form-values'}.csv`,
|
|
1337
|
+
);
|
|
1338
|
+
link.style.visibility = 'hidden';
|
|
1339
|
+
document.body.appendChild(link);
|
|
1340
|
+
link.click();
|
|
1341
|
+
document.body.removeChild(link);
|
|
1342
|
+
}
|
|
1343
|
+
}
|
|
1344
|
+
|
|
1345
|
+
downloadExcel(tables: EntityTableExport[]): void {
|
|
1346
|
+
if (!tables || tables.length === 0) {
|
|
1347
|
+
this.utilService.showError('No valid form values found to export');
|
|
1348
|
+
return;
|
|
1349
|
+
}
|
|
1350
|
+
|
|
1351
|
+
let xml =
|
|
1352
|
+
`<?xml version="1.0"?>\n` +
|
|
1353
|
+
`<?mso-application progid="Excel.Sheet"?>\n` +
|
|
1354
|
+
`<Workbook xmlns="urn:schemas-microsoft-com:office:spreadsheet"\n` +
|
|
1355
|
+
` xmlns:o="urn:schemas-microsoft-com:office:office"\n` +
|
|
1356
|
+
` xmlns:x="urn:schemas-microsoft-com:office:excel"\n` +
|
|
1357
|
+
` xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"\n` +
|
|
1358
|
+
` xmlns:html="http://www.w3.org/TR/REC-html40">\n` +
|
|
1359
|
+
` <Styles>\n` +
|
|
1360
|
+
` <Style ss:ID="Header">\n` +
|
|
1361
|
+
` <Font ss:Bold="1"/>\n` +
|
|
1362
|
+
` <Interior ss:Color="#EFEFEF" ss:Pattern="Solid"/>\n` +
|
|
1363
|
+
` </Style>\n` +
|
|
1364
|
+
` </Styles>\n`;
|
|
1365
|
+
|
|
1366
|
+
for (const table of tables) {
|
|
1367
|
+
const safeSheetName = this.escapeXml(
|
|
1368
|
+
table.entityName.replace(/[:\\/?*\[\]]/g, '').substring(0, 31) ||
|
|
1369
|
+
'Sheet',
|
|
1370
|
+
);
|
|
1371
|
+
|
|
1372
|
+
xml += ` <Worksheet ss:Name="${safeSheetName}">\n`;
|
|
1373
|
+
xml += ` <Table>\n`;
|
|
1374
|
+
|
|
1375
|
+
// Header row
|
|
1376
|
+
xml += ` <Row ss:StyleID="Header">\n`;
|
|
1377
|
+
for (const col of table.columns) {
|
|
1378
|
+
xml += ` <Cell><Data ss:Type="String">${this.escapeXml(col)}</Data></Cell>\n`;
|
|
1379
|
+
}
|
|
1380
|
+
xml += ` </Row>\n`;
|
|
1381
|
+
|
|
1382
|
+
// Data rows
|
|
1383
|
+
for (const row of table.rows) {
|
|
1384
|
+
xml += ` <Row>\n`;
|
|
1385
|
+
for (const col of table.columns) {
|
|
1386
|
+
const val =
|
|
1387
|
+
row[col] !== undefined && row[col] !== null ? String(row[col]) : '';
|
|
1388
|
+
xml += ` <Cell><Data ss:Type="String">${this.escapeXml(val)}</Data></Cell>\n`;
|
|
1389
|
+
}
|
|
1390
|
+
xml += ` </Row>\n`;
|
|
1391
|
+
}
|
|
1392
|
+
|
|
1393
|
+
xml += ` </Table>\n`;
|
|
1394
|
+
xml += ` </Worksheet>\n`;
|
|
1395
|
+
}
|
|
1396
|
+
|
|
1397
|
+
xml += `</Workbook>`;
|
|
1398
|
+
|
|
1399
|
+
const blob = new Blob([xml], {
|
|
1400
|
+
type: 'application/vnd.ms-excel;charset=utf-8;',
|
|
1401
|
+
});
|
|
1402
|
+
const link = document.createElement('a');
|
|
1403
|
+
if (link.download !== undefined) {
|
|
1404
|
+
const url = URL.createObjectURL(blob);
|
|
1405
|
+
link.setAttribute('href', url);
|
|
1406
|
+
link.setAttribute(
|
|
1407
|
+
'download',
|
|
1408
|
+
`${this.formCode ? this.formCode + '-responses' : 'form-values'}.xls`,
|
|
1409
|
+
);
|
|
1410
|
+
link.style.visibility = 'hidden';
|
|
1411
|
+
document.body.appendChild(link);
|
|
1412
|
+
link.click();
|
|
1413
|
+
document.body.removeChild(link);
|
|
1414
|
+
}
|
|
1415
|
+
}
|
|
1416
|
+
|
|
1417
|
+
private escapeXml(str: string): string {
|
|
1418
|
+
return str
|
|
1419
|
+
.replace(/&/g, '&')
|
|
1420
|
+
.replace(/</g, '<')
|
|
1421
|
+
.replace(/>/g, '>')
|
|
1422
|
+
.replace(/"/g, '"')
|
|
1423
|
+
.replace(/'/g, ''');
|
|
1424
|
+
}
|
|
1425
|
+
|
|
1426
|
+
private escapeCsv(value: string): string {
|
|
1427
|
+
if (
|
|
1428
|
+
value.includes(',') ||
|
|
1429
|
+
value.includes('"') ||
|
|
1430
|
+
value.includes('\n') ||
|
|
1431
|
+
value.includes('\r')
|
|
1432
|
+
) {
|
|
1433
|
+
return `"${value.replace(/"/g, '""')}"`;
|
|
1434
|
+
}
|
|
1435
|
+
return value;
|
|
1436
|
+
}
|
|
1437
|
+
}
|