@things-factory/worklist 7.0.0-alpha.9 → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-client/activity-summary-generator.js +1 -1
- package/dist-client/activity-summary-generator.js.map +1 -1
- package/dist-client/bootstrap.d.ts +1 -1
- package/dist-client/bootstrap.js +4 -4
- package/dist-client/bootstrap.js.map +1 -1
- package/dist-client/components/activity-/bowner-view.d.ts +1 -1
- package/dist-client/components/activity-/bowner-view.js +3 -3
- package/dist-client/components/activity-/bowner-view.js.map +1 -1
- package/dist-client/components/activity-approval-ribon.d.ts +0 -1
- package/dist-client/components/activity-approval-ribon.js +7 -8
- package/dist-client/components/activity-approval-ribon.js.map +1 -1
- package/dist-client/components/activity-instance-preview.d.ts +1 -1
- package/dist-client/components/activity-instance-preview.js +9 -9
- package/dist-client/components/activity-instance-preview.js.map +1 -1
- package/dist-client/components/activity-instance-ribon.d.ts +1 -1
- package/dist-client/components/activity-instance-ribon.js +8 -8
- package/dist-client/components/activity-instance-ribon.js.map +1 -1
- package/dist-client/components/activity-intro-view.d.ts +1 -1
- package/dist-client/components/activity-intro-view.js +3 -3
- package/dist-client/components/activity-intro-view.js.map +1 -1
- package/dist-client/components/activity-reporter-view.d.ts +1 -1
- package/dist-client/components/activity-reporter-view.js +3 -3
- package/dist-client/components/activity-reporter-view.js.map +1 -1
- package/dist-client/components/activity-starter-form.d.ts +3 -2
- package/dist-client/components/activity-starter-form.js +39 -39
- package/dist-client/components/activity-starter-form.js.map +1 -1
- package/dist-client/components/activity-thread-ribon.d.ts +1 -1
- package/dist-client/components/activity-thread-ribon.js +8 -8
- package/dist-client/components/activity-thread-ribon.js.map +1 -1
- package/dist-client/components/activity-thread-timeline.d.ts +1 -1
- package/dist-client/components/activity-thread-timeline.js +15 -14
- package/dist-client/components/activity-thread-timeline.js.map +1 -1
- package/dist-client/grist-editor/grist-editor-activity-search-key.js +1 -1
- package/dist-client/grist-editor/grist-editor-activity-search-key.js.map +1 -1
- package/dist-client/grist-editor/grist-renderer-activity-search-key.d.ts +1 -1
- package/dist-client/grist-editor/grist-renderer-activity-search-key.js +7 -4
- package/dist-client/grist-editor/grist-renderer-activity-search-key.js.map +1 -1
- package/dist-client/grist-editor/popup-activity-search-keys-input.js +7 -10
- package/dist-client/grist-editor/popup-activity-search-keys-input.js.map +1 -1
- package/dist-client/pages/activity/activity-list-page.js +6 -11
- package/dist-client/pages/activity/activity-list-page.js.map +1 -1
- package/dist-client/pages/activity/activity-model-item-list.js +26 -22
- package/dist-client/pages/activity/activity-model-item-list.js.map +1 -1
- package/dist-client/pages/activity/activity-page.js +1 -1
- package/dist-client/pages/activity/activity-page.js.map +1 -1
- package/dist-client/pages/activity/activity-partial-view.js +1 -1
- package/dist-client/pages/activity/activity-partial-view.js.map +1 -1
- package/dist-client/pages/activity/starter-list-page.d.ts +2 -3
- package/dist-client/pages/activity/starter-list-page.js +28 -45
- package/dist-client/pages/activity/starter-list-page.js.map +1 -1
- package/dist-client/pages/activity-approval/activity-approval-importer.d.ts +1 -0
- package/dist-client/pages/activity-approval/activity-approval-importer.js +5 -12
- package/dist-client/pages/activity-approval/activity-approval-importer.js.map +1 -1
- package/dist-client/pages/activity-approval/activity-approval-list-page.d.ts +0 -1
- package/dist-client/pages/activity-approval/activity-approval-list-page.js +4 -32
- package/dist-client/pages/activity-approval/activity-approval-list-page.js.map +1 -1
- package/dist-client/pages/activity-approval/activity-approval-page.d.ts +6 -4
- package/dist-client/pages/activity-approval/activity-approval-page.js +10 -6
- package/dist-client/pages/activity-approval/activity-approval-page.js.map +1 -1
- package/dist-client/pages/activity-instance/activity-instance-list-page.d.ts +1 -2
- package/dist-client/pages/activity-instance/activity-instance-list-page.js +5 -32
- package/dist-client/pages/activity-instance/activity-instance-list-page.js.map +1 -1
- package/dist-client/pages/activity-instance/activity-instance-search-page.d.ts +0 -1
- package/dist-client/pages/activity-instance/activity-instance-search-page.js +7 -47
- package/dist-client/pages/activity-instance/activity-instance-search-page.js.map +1 -1
- package/dist-client/pages/activity-instance/activity-instance-start-page.d.ts +7 -5
- package/dist-client/pages/activity-instance/activity-instance-start-page.js +1 -1
- package/dist-client/pages/activity-instance/activity-instance-start-page.js.map +1 -1
- package/dist-client/pages/activity-instance/activity-instance-view.js +50 -36
- package/dist-client/pages/activity-instance/activity-instance-view.js.map +1 -1
- package/dist-client/pages/activity-stats/activity-stats-importer.d.ts +1 -0
- package/dist-client/pages/activity-stats/activity-stats-importer.js +5 -12
- package/dist-client/pages/activity-stats/activity-stats-importer.js.map +1 -1
- package/dist-client/pages/activity-stats/activity-stats-list-page.d.ts +0 -1
- package/dist-client/pages/activity-stats/activity-stats-list-page.js +4 -32
- package/dist-client/pages/activity-stats/activity-stats-list-page.js.map +1 -1
- package/dist-client/pages/activity-store/activity-store-page.d.ts +1 -2
- package/dist-client/pages/activity-store/activity-store-page.js +4 -25
- package/dist-client/pages/activity-store/activity-store-page.js.map +1 -1
- package/dist-client/pages/activity-supervisor/reporter-list-page.d.ts +1 -2
- package/dist-client/pages/activity-supervisor/reporter-list-page.js +4 -31
- package/dist-client/pages/activity-supervisor/reporter-list-page.js.map +1 -1
- package/dist-client/pages/activity-template/activity-template-importer.d.ts +1 -0
- package/dist-client/pages/activity-template/activity-template-importer.js +13 -20
- package/dist-client/pages/activity-template/activity-template-importer.js.map +1 -1
- package/dist-client/pages/activity-template/activity-template-list-page.d.ts +1 -2
- package/dist-client/pages/activity-template/activity-template-list-page.js +4 -31
- package/dist-client/pages/activity-template/activity-template-list-page.js.map +1 -1
- package/dist-client/pages/activity-template/activity-template-model-item-list.js.map +1 -1
- package/dist-client/pages/activity-thread/activity-thread-importer.d.ts +1 -0
- package/dist-client/pages/activity-thread/activity-thread-importer.js +15 -24
- package/dist-client/pages/activity-thread/activity-thread-importer.js.map +1 -1
- package/dist-client/pages/activity-thread/activity-thread-list-page.d.ts +1 -2
- package/dist-client/pages/activity-thread/activity-thread-list-page.js +4 -31
- package/dist-client/pages/activity-thread/activity-thread-list-page.js.map +1 -1
- package/dist-client/pages/activity-thread/activity-thread-page.d.ts +4 -3
- package/dist-client/pages/activity-thread/activity-thread-page.js +7 -3
- package/dist-client/pages/activity-thread/activity-thread-page.js.map +1 -1
- package/dist-client/pages/activity-thread/activity-thread-view-page.d.ts +4 -3
- package/dist-client/pages/activity-thread/activity-thread-view-page.js +3 -3
- package/dist-client/pages/activity-thread/activity-thread-view-page.js.map +1 -1
- package/dist-client/pages/activity-thread/activity-thread-view.js +22 -18
- package/dist-client/pages/activity-thread/activity-thread-view.js.map +1 -1
- package/dist-client/pages/installable-activity/installable-activity-list-page.d.ts +5 -0
- package/dist-client/pages/installable-activity/installable-activity-list-page.js +14 -8
- package/dist-client/pages/installable-activity/installable-activity-list-page.js.map +1 -1
- package/dist-client/pages/todo/approval-done-list-page.js +2 -5
- package/dist-client/pages/todo/approval-done-list-page.js.map +1 -1
- package/dist-client/pages/todo/approval-pending-list-page.d.ts +5 -0
- package/dist-client/pages/todo/approval-pending-list-page.js +14 -8
- package/dist-client/pages/todo/approval-pending-list-page.js.map +1 -1
- package/dist-client/pages/todo/done-list-calendar-page.d.ts +2 -2
- package/dist-client/pages/todo/done-list-calendar-page.js +6 -4
- package/dist-client/pages/todo/done-list-calendar-page.js.map +1 -1
- package/dist-client/pages/todo/done-list-page.js +2 -5
- package/dist-client/pages/todo/done-list-page.js.map +1 -1
- package/dist-client/pages/todo/draft-list-page.d.ts +1 -3
- package/dist-client/pages/todo/draft-list-page.js +4 -34
- package/dist-client/pages/todo/draft-list-page.js.map +1 -1
- package/dist-client/pages/todo/pickable-list-page.js +1 -4
- package/dist-client/pages/todo/pickable-list-page.js.map +1 -1
- package/dist-client/pages/todo/todo-list-page.d.ts +6 -1
- package/dist-client/pages/todo/todo-list-page.js +18 -12
- package/dist-client/pages/todo/todo-list-page.js.map +1 -1
- package/dist-client/route.js.map +1 -1
- package/dist-client/templates/activity-approval-context-template.d.ts +1 -1
- package/dist-client/templates/activity-approval-context-template.js +20 -12
- package/dist-client/templates/activity-approval-context-template.js.map +1 -1
- package/dist-client/templates/activity-instance-context-template.d.ts +2 -1
- package/dist-client/templates/activity-instance-context-template.js +30 -19
- package/dist-client/templates/activity-instance-context-template.js.map +1 -1
- package/dist-client/templates/activity-thread-context-template.d.ts +1 -1
- package/dist-client/templates/activity-thread-context-template.js +22 -12
- package/dist-client/templates/activity-thread-context-template.js.map +1 -1
- package/dist-client/tsconfig.tsbuildinfo +1 -1
- package/dist-client/types/activity-instance.js.map +1 -1
- package/dist-client/types/activity.d.ts +1 -1
- package/dist-client/types/activity.js.map +1 -1
- package/dist-server/controllers/activity-approval/_abort.d.ts +5 -0
- package/dist-server/controllers/activity-approval/_abort.js +1 -2
- package/dist-server/controllers/activity-approval/_abort.js.map +1 -1
- package/dist-server/controllers/activity-approval/abort.d.ts +5 -0
- package/dist-server/controllers/activity-approval/abort.js +1 -2
- package/dist-server/controllers/activity-approval/abort.js.map +1 -1
- package/dist-server/controllers/activity-approval/approve.d.ts +5 -0
- package/dist-server/controllers/activity-approval/approve.js +1 -2
- package/dist-server/controllers/activity-approval/approve.js.map +1 -1
- package/dist-server/controllers/activity-approval/delegate.d.ts +7 -0
- package/dist-server/controllers/activity-approval/delegate.js +1 -2
- package/dist-server/controllers/activity-approval/delegate.js.map +1 -1
- package/dist-server/controllers/activity-approval/reject.d.ts +5 -0
- package/dist-server/controllers/activity-approval/reject.js +1 -2
- package/dist-server/controllers/activity-approval/reject.js.map +1 -1
- package/dist-server/controllers/activity-installation/activity-installation-controller.d.ts +18 -0
- package/dist-server/controllers/activity-installation/activity-installation-controller.js.map +1 -1
- package/dist-server/controllers/activity-installation/call-webhook.d.ts +3 -0
- package/dist-server/controllers/activity-installation/call-webhook.js +1 -2
- package/dist-server/controllers/activity-installation/call-webhook.js.map +1 -1
- package/dist-server/controllers/activity-instance/abort.d.ts +5 -0
- package/dist-server/controllers/activity-instance/abort.js +1 -2
- package/dist-server/controllers/activity-instance/abort.js.map +1 -1
- package/dist-server/controllers/activity-instance/assign.d.ts +7 -0
- package/dist-server/controllers/activity-instance/assign.js +1 -2
- package/dist-server/controllers/activity-instance/assign.js.map +1 -1
- package/dist-server/controllers/activity-instance/draft.d.ts +3 -0
- package/dist-server/controllers/activity-instance/draft.js +1 -2
- package/dist-server/controllers/activity-instance/draft.js.map +1 -1
- package/dist-server/controllers/activity-instance/end.d.ts +6 -0
- package/dist-server/controllers/activity-instance/end.js +1 -2
- package/dist-server/controllers/activity-instance/end.js.map +1 -1
- package/dist-server/controllers/activity-instance/index.d.ts +6 -0
- package/dist-server/controllers/activity-instance/issue.d.ts +3 -0
- package/dist-server/controllers/activity-instance/issue.js +3 -3
- package/dist-server/controllers/activity-instance/issue.js.map +1 -1
- package/dist-server/controllers/activity-instance/pick.d.ts +2 -0
- package/dist-server/controllers/activity-instance/pick.js +1 -2
- package/dist-server/controllers/activity-instance/pick.js.map +1 -1
- package/dist-server/controllers/activity-thread/_abort.d.ts +5 -0
- package/dist-server/controllers/activity-thread/_abort.js +1 -2
- package/dist-server/controllers/activity-thread/_abort.js.map +1 -1
- package/dist-server/controllers/activity-thread/abort.d.ts +5 -0
- package/dist-server/controllers/activity-thread/abort.js +1 -2
- package/dist-server/controllers/activity-thread/abort.js.map +1 -1
- package/dist-server/controllers/activity-thread/delegate.d.ts +7 -0
- package/dist-server/controllers/activity-thread/delegate.js +1 -2
- package/dist-server/controllers/activity-thread/delegate.js.map +1 -1
- package/dist-server/controllers/activity-thread/end.d.ts +6 -0
- package/dist-server/controllers/activity-thread/end.js +1 -2
- package/dist-server/controllers/activity-thread/end.js.map +1 -1
- package/dist-server/controllers/activity-thread/index.d.ts +7 -0
- package/dist-server/controllers/activity-thread/restart.d.ts +2 -0
- package/dist-server/controllers/activity-thread/restart.js +1 -2
- package/dist-server/controllers/activity-thread/restart.js.map +1 -1
- package/dist-server/controllers/activity-thread/save.d.ts +3 -0
- package/dist-server/controllers/activity-thread/save.js +1 -2
- package/dist-server/controllers/activity-thread/save.js.map +1 -1
- package/dist-server/controllers/activity-thread/start.d.ts +2 -0
- package/dist-server/controllers/activity-thread/start.js +1 -2
- package/dist-server/controllers/activity-thread/start.js.map +1 -1
- package/dist-server/controllers/activity-thread/submit.d.ts +6 -0
- package/dist-server/controllers/activity-thread/submit.js +1 -2
- package/dist-server/controllers/activity-thread/submit.js.map +1 -1
- package/dist-server/controllers/common.d.ts +20 -0
- package/dist-server/controllers/common.js +9 -10
- package/dist-server/controllers/common.js.map +1 -1
- package/dist-server/controllers/index.d.ts +3 -0
- package/dist-server/controllers/index.js +1 -0
- package/dist-server/controllers/index.js.map +1 -1
- package/dist-server/index.d.ts +3 -0
- package/dist-server/routes.d.ts +1 -0
- package/dist-server/routes.js.map +1 -1
- package/dist-server/service/activity/activity-history.d.ts +45 -0
- package/dist-server/service/activity/activity-history.js +7 -7
- package/dist-server/service/activity/activity-history.js.map +1 -1
- package/dist-server/service/activity/activity-model-type.d.ts +49 -0
- package/dist-server/service/activity/activity-model-type.js +6 -6
- package/dist-server/service/activity/activity-model-type.js.map +1 -1
- package/dist-server/service/activity/activity-mutation.d.ts +12 -0
- package/dist-server/service/activity/activity-mutation.js +2 -2
- package/dist-server/service/activity/activity-mutation.js.map +1 -1
- package/dist-server/service/activity/activity-query.d.ts +21 -0
- package/dist-server/service/activity/activity-query.js +5 -6
- package/dist-server/service/activity/activity-query.js.map +1 -1
- package/dist-server/service/activity/activity-search-key-item-type.d.ts +6 -0
- package/dist-server/service/activity/activity-search-key-item-type.js +2 -2
- package/dist-server/service/activity/activity-search-key-item-type.js.map +1 -1
- package/dist-server/service/activity/activity-type.d.ts +67 -0
- package/dist-server/service/activity/activity-type.js +6 -6
- package/dist-server/service/activity/activity-type.js.map +1 -1
- package/dist-server/service/activity/activity.d.ts +87 -0
- package/dist-server/service/activity/activity.js +11 -12
- package/dist-server/service/activity/activity.js.map +1 -1
- package/dist-server/service/activity/event-subscriber.d.ts +7 -0
- package/dist-server/service/activity/event-subscriber.js +2 -2
- package/dist-server/service/activity/event-subscriber.js.map +1 -1
- package/dist-server/service/activity/index.d.ts +8 -0
- package/dist-server/service/activity-approval/activity-approval-mutation.d.ts +8 -0
- package/dist-server/service/activity-approval/activity-approval-mutation.js +2 -2
- package/dist-server/service/activity-approval/activity-approval-mutation.js.map +1 -1
- package/dist-server/service/activity-approval/activity-approval-query.d.ts +17 -0
- package/dist-server/service/activity-approval/activity-approval-query.js +5 -5
- package/dist-server/service/activity-approval/activity-approval-query.js.map +1 -1
- package/dist-server/service/activity-approval/activity-approval-subscription.d.ts +6 -0
- package/dist-server/service/activity-approval/activity-approval-subscription.js +2 -2
- package/dist-server/service/activity-approval/activity-approval-subscription.js.map +1 -1
- package/dist-server/service/activity-approval/activity-approval-type.d.ts +10 -0
- package/dist-server/service/activity-approval/activity-approval-type.js +4 -4
- package/dist-server/service/activity-approval/activity-approval-type.js.map +1 -1
- package/dist-server/service/activity-approval/activity-approval.d.ts +37 -0
- package/dist-server/service/activity-approval/activity-approval.js +9 -10
- package/dist-server/service/activity-approval/activity-approval.js.map +1 -1
- package/dist-server/service/activity-approval/event-subscriber.d.ts +7 -0
- package/dist-server/service/activity-approval/event-subscriber.js +2 -2
- package/dist-server/service/activity-approval/event-subscriber.js.map +1 -1
- package/dist-server/service/activity-approval/index.d.ts +8 -0
- package/dist-server/service/activity-instance/activity-instance-history-query.d.ts +12 -0
- package/dist-server/service/activity-instance/activity-instance-history-query.js +3 -3
- package/dist-server/service/activity-instance/activity-instance-history-query.js.map +1 -1
- package/dist-server/service/activity-instance/activity-instance-history-type.d.ts +5 -0
- package/dist-server/service/activity-instance/activity-instance-history-type.js +2 -2
- package/dist-server/service/activity-instance/activity-instance-history-type.js.map +1 -1
- package/dist-server/service/activity-instance/activity-instance-history.d.ts +61 -0
- package/dist-server/service/activity-instance/activity-instance-history.js +10 -8
- package/dist-server/service/activity-instance/activity-instance-history.js.map +1 -1
- package/dist-server/service/activity-instance/activity-instance-mutation.d.ts +15 -0
- package/dist-server/service/activity-instance/activity-instance-mutation.js +2 -2
- package/dist-server/service/activity-instance/activity-instance-mutation.js.map +1 -1
- package/dist-server/service/activity-instance/activity-instance-query.d.ts +27 -0
- package/dist-server/service/activity-instance/activity-instance-query.js +6 -7
- package/dist-server/service/activity-instance/activity-instance-query.js.map +1 -1
- package/dist-server/service/activity-instance/activity-instance-subscription.d.ts +6 -0
- package/dist-server/service/activity-instance/activity-instance-subscription.js +2 -2
- package/dist-server/service/activity-instance/activity-instance-subscription.js.map +1 -1
- package/dist-server/service/activity-instance/activity-instance-type.d.ts +87 -0
- package/dist-server/service/activity-instance/activity-instance-type.js +10 -10
- package/dist-server/service/activity-instance/activity-instance-type.js.map +1 -1
- package/dist-server/service/activity-instance/activity-instance.d.ts +75 -0
- package/dist-server/service/activity-instance/activity-instance.js +6 -6
- package/dist-server/service/activity-instance/activity-instance.js.map +1 -1
- package/dist-server/service/activity-instance/event-subscriber.d.ts +13 -0
- package/dist-server/service/activity-instance/event-subscriber.js +4 -4
- package/dist-server/service/activity-instance/event-subscriber.js.map +1 -1
- package/dist-server/service/activity-instance/index.d.ts +10 -0
- package/dist-server/service/activity-stats/activity-stats-query.d.ts +4 -0
- package/dist-server/service/activity-stats/activity-stats-query.js +4 -5
- package/dist-server/service/activity-stats/activity-stats-query.js.map +1 -1
- package/dist-server/service/activity-stats/activity-stats-type.d.ts +14 -0
- package/dist-server/service/activity-stats/activity-stats-type.js +3 -3
- package/dist-server/service/activity-stats/activity-stats-type.js.map +1 -1
- package/dist-server/service/activity-stats/index.d.ts +2 -0
- package/dist-server/service/activity-summary/activity-summary-query.d.ts +8 -0
- package/dist-server/service/activity-summary/activity-summary-query.js +2 -2
- package/dist-server/service/activity-summary/activity-summary-query.js.map +1 -1
- package/dist-server/service/activity-summary/activity-summary.d.ts +6 -0
- package/dist-server/service/activity-summary/activity-summary.js +2 -2
- package/dist-server/service/activity-summary/activity-summary.js.map +1 -1
- package/dist-server/service/activity-summary/index.d.ts +4 -0
- package/dist-server/service/activity-template/activity-template-history.d.ts +32 -0
- package/dist-server/service/activity-template/activity-template-history.js +10 -8
- package/dist-server/service/activity-template/activity-template-history.js.map +1 -1
- package/dist-server/service/activity-template/activity-template-mutation.d.ts +10 -0
- package/dist-server/service/activity-template/activity-template-mutation.js +2 -2
- package/dist-server/service/activity-template/activity-template-mutation.js.map +1 -1
- package/dist-server/service/activity-template/activity-template-query.d.ts +14 -0
- package/dist-server/service/activity-template/activity-template-query.js +3 -3
- package/dist-server/service/activity-template/activity-template-query.js.map +1 -1
- package/dist-server/service/activity-template/activity-template-type.d.ts +44 -0
- package/dist-server/service/activity-template/activity-template-type.js +6 -6
- package/dist-server/service/activity-template/activity-template-type.js.map +1 -1
- package/dist-server/service/activity-template/activity-template.d.ts +36 -0
- package/dist-server/service/activity-template/activity-template.js +6 -6
- package/dist-server/service/activity-template/activity-template.js.map +1 -1
- package/dist-server/service/activity-template/event-subscriber.d.ts +7 -0
- package/dist-server/service/activity-template/event-subscriber.js +2 -2
- package/dist-server/service/activity-template/event-subscriber.js.map +1 -1
- package/dist-server/service/activity-template/index.d.ts +8 -0
- package/dist-server/service/activity-thread/activity-thread-history-query.d.ts +10 -0
- package/dist-server/service/activity-thread/activity-thread-history-query.js +2 -2
- package/dist-server/service/activity-thread/activity-thread-history-query.js.map +1 -1
- package/dist-server/service/activity-thread/activity-thread-history.d.ts +39 -0
- package/dist-server/service/activity-thread/activity-thread-history.js +17 -9
- package/dist-server/service/activity-thread/activity-thread-history.js.map +1 -1
- package/dist-server/service/activity-thread/activity-thread-mutation.d.ts +23 -0
- package/dist-server/service/activity-thread/activity-thread-mutation.js +2 -2
- package/dist-server/service/activity-thread/activity-thread-mutation.js.map +1 -1
- package/dist-server/service/activity-thread/activity-thread-query.d.ts +21 -0
- package/dist-server/service/activity-thread/activity-thread-query.js +8 -6
- package/dist-server/service/activity-thread/activity-thread-query.js.map +1 -1
- package/dist-server/service/activity-thread/activity-thread-subscription.d.ts +6 -0
- package/dist-server/service/activity-thread/activity-thread-subscription.js +2 -2
- package/dist-server/service/activity-thread/activity-thread-subscription.js.map +1 -1
- package/dist-server/service/activity-thread/activity-thread-type.d.ts +15 -0
- package/dist-server/service/activity-thread/activity-thread-type.js +6 -6
- package/dist-server/service/activity-thread/activity-thread-type.js.map +1 -1
- package/dist-server/service/activity-thread/activity-thread.d.ts +46 -0
- package/dist-server/service/activity-thread/activity-thread.js +6 -6
- package/dist-server/service/activity-thread/activity-thread.js.map +1 -1
- package/dist-server/service/activity-thread/event-subscriber.d.ts +13 -0
- package/dist-server/service/activity-thread/event-subscriber.js +4 -4
- package/dist-server/service/activity-thread/event-subscriber.js.map +1 -1
- package/dist-server/service/activity-thread/index.d.ts +10 -0
- package/dist-server/service/index.d.ts +12 -0
- package/dist-server/service/installable-activity/index.d.ts +6 -0
- package/dist-server/service/installable-activity/installable-activity-mutation.d.ts +5 -0
- package/dist-server/service/installable-activity/installable-activity-mutation.js +2 -2
- package/dist-server/service/installable-activity/installable-activity-mutation.js.map +1 -1
- package/dist-server/service/installable-activity/installable-activity-query.d.ts +7 -0
- package/dist-server/service/installable-activity/installable-activity-query.js +3 -3
- package/dist-server/service/installable-activity/installable-activity-query.js.map +1 -1
- package/dist-server/service/installable-activity/installable-activity-type.d.ts +5 -0
- package/dist-server/service/installable-activity/installable-activity-type.js +2 -2
- package/dist-server/service/installable-activity/installable-activity-type.js.map +1 -1
- package/dist-server/service/installable-activity/installable-activity.d.ts +24 -0
- package/dist-server/service/installable-activity/installable-activity.js +2 -2
- package/dist-server/service/installable-activity/installable-activity.js.map +1 -1
- package/dist-server/tsconfig.tsbuildinfo +1 -1
- package/package.json +16 -13
- package/client/activity-summary-generator.ts +0 -132
- package/client/bootstrap.ts +0 -70
- package/client/components/activity-/bowner-view.ts +0 -100
- package/client/components/activity-approval-ribon.ts +0 -164
- package/client/components/activity-instance-preview.ts +0 -197
- package/client/components/activity-instance-ribon.ts +0 -158
- package/client/components/activity-intro-view.ts +0 -95
- package/client/components/activity-reporter-view.ts +0 -95
- package/client/components/activity-starter-form.ts +0 -258
- package/client/components/activity-thread-ribon.ts +0 -148
- package/client/components/activity-thread-timeline.ts +0 -210
- package/client/grist-editor/grist-editor-activity-search-key.ts +0 -80
- package/client/grist-editor/grist-renderer-activity-search-key.ts +0 -25
- package/client/grist-editor/popup-activity-search-keys-input.ts +0 -167
- package/client/index.ts +0 -3
- package/client/pages/activity/activity-list-page.ts +0 -685
- package/client/pages/activity/activity-model-item-list.ts +0 -297
- package/client/pages/activity/activity-page.ts +0 -431
- package/client/pages/activity/activity-partial-view.ts +0 -82
- package/client/pages/activity/starter-list-page.ts +0 -224
- package/client/pages/activity-approval/activity-approval-importer.ts +0 -97
- package/client/pages/activity-approval/activity-approval-list-page.ts +0 -337
- package/client/pages/activity-approval/activity-approval-page.ts +0 -540
- package/client/pages/activity-instance/activity-instance-list-page.ts +0 -228
- package/client/pages/activity-instance/activity-instance-search-page.ts +0 -373
- package/client/pages/activity-instance/activity-instance-start-page.ts +0 -550
- package/client/pages/activity-instance/activity-instance-view.ts +0 -475
- package/client/pages/activity-stats/activity-stats-importer.ts +0 -97
- package/client/pages/activity-stats/activity-stats-list-page.ts +0 -337
- package/client/pages/activity-store/activity-store-page.ts +0 -243
- package/client/pages/activity-supervisor/reporter-list-page.ts +0 -241
- package/client/pages/activity-template/activity-template-importer.ts +0 -101
- package/client/pages/activity-template/activity-template-list-page.ts +0 -480
- package/client/pages/activity-template/activity-template-model-item-list.ts +0 -44
- package/client/pages/activity-thread/activity-thread-importer.ts +0 -102
- package/client/pages/activity-thread/activity-thread-list-page.ts +0 -328
- package/client/pages/activity-thread/activity-thread-page.ts +0 -571
- package/client/pages/activity-thread/activity-thread-view-page.ts +0 -345
- package/client/pages/activity-thread/activity-thread-view.ts +0 -325
- package/client/pages/dashboard/dashboard-home.ts +0 -23
- package/client/pages/installable-activity/installable-activity-list-page.ts +0 -427
- package/client/pages/installable-activity/installable-activity-model-item-list.ts +0 -18
- package/client/pages/todo/approval-done-list-page.ts +0 -345
- package/client/pages/todo/approval-pending-list-page.ts +0 -419
- package/client/pages/todo/done-list-calendar-page.ts +0 -115
- package/client/pages/todo/done-list-page.ts +0 -366
- package/client/pages/todo/draft-list-page.ts +0 -306
- package/client/pages/todo/pickable-list-page.ts +0 -311
- package/client/pages/todo/todo-list-page.ts +0 -394
- package/client/pages/worklist-home.ts +0 -16
- package/client/route.ts +0 -103
- package/client/templates/activity-approval-context-template.ts +0 -170
- package/client/templates/activity-instance-context-template.ts +0 -276
- package/client/templates/activity-thread-context-template.ts +0 -146
- package/client/themes/calendar-theme.css +0 -54
- package/client/tsconfig.json +0 -13
- package/client/types/activity-approval.ts +0 -62
- package/client/types/activity-instance-type.ts +0 -125
- package/client/types/activity-instance.ts +0 -128
- package/client/types/activity-model-type.ts +0 -40
- package/client/types/activity-search-key-item-type.ts +0 -9
- package/client/types/activity-thread-history.ts +0 -47
- package/client/types/activity-thread-type.ts +0 -19
- package/client/types/activity-thread.ts +0 -60
- package/client/types/activity.ts +0 -102
- package/client/types/types.ts +0 -46
- package/dist-client/themes/calendar-theme.css +0 -54
- package/server/controllers/activity-approval/_abort.ts +0 -31
- package/server/controllers/activity-approval/abort.ts +0 -41
- package/server/controllers/activity-approval/approve.ts +0 -96
- package/server/controllers/activity-approval/delegate.ts +0 -62
- package/server/controllers/activity-approval/reject.ts +0 -57
- package/server/controllers/activity-installation/activity-installation-controller.ts +0 -36
- package/server/controllers/activity-installation/call-webhook.ts +0 -40
- package/server/controllers/activity-instance/abort.ts +0 -78
- package/server/controllers/activity-instance/assign.ts +0 -56
- package/server/controllers/activity-instance/draft.ts +0 -91
- package/server/controllers/activity-instance/end.ts +0 -81
- package/server/controllers/activity-instance/index.ts +0 -6
- package/server/controllers/activity-instance/issue.ts +0 -179
- package/server/controllers/activity-instance/pick.ts +0 -45
- package/server/controllers/activity-thread/_abort.ts +0 -40
- package/server/controllers/activity-thread/abort.ts +0 -45
- package/server/controllers/activity-thread/delegate.ts +0 -64
- package/server/controllers/activity-thread/end.ts +0 -51
- package/server/controllers/activity-thread/index.ts +0 -7
- package/server/controllers/activity-thread/restart.ts +0 -51
- package/server/controllers/activity-thread/save.ts +0 -50
- package/server/controllers/activity-thread/start.ts +0 -49
- package/server/controllers/activity-thread/submit.ts +0 -89
- package/server/controllers/common.ts +0 -311
- package/server/controllers/index.ts +0 -2
- package/server/index.ts +0 -4
- package/server/routes.ts +0 -73
- package/server/service/activity/activity-history.ts +0 -187
- package/server/service/activity/activity-model-type.ts +0 -106
- package/server/service/activity/activity-mutation.ts +0 -388
- package/server/service/activity/activity-query.ts +0 -257
- package/server/service/activity/activity-search-key-item-type.ts +0 -16
- package/server/service/activity/activity-type.ts +0 -192
- package/server/service/activity/activity.ts +0 -261
- package/server/service/activity/event-subscriber.ts +0 -17
- package/server/service/activity/index.ts +0 -9
- package/server/service/activity-approval/activity-approval-mutation.ts +0 -75
- package/server/service/activity-approval/activity-approval-query.ts +0 -152
- package/server/service/activity-approval/activity-approval-subscription.ts +0 -45
- package/server/service/activity-approval/activity-approval-type.ts +0 -28
- package/server/service/activity-approval/activity-approval.ts +0 -124
- package/server/service/activity-approval/event-subscriber.ts +0 -45
- package/server/service/activity-approval/index.ts +0 -9
- package/server/service/activity-instance/activity-instance-history-query.ts +0 -48
- package/server/service/activity-instance/activity-instance-history-type.ts +0 -13
- package/server/service/activity-instance/activity-instance-history.ts +0 -244
- package/server/service/activity-instance/activity-instance-mutation.ts +0 -116
- package/server/service/activity-instance/activity-instance-query.ts +0 -330
- package/server/service/activity-instance/activity-instance-subscription.ts +0 -52
- package/server/service/activity-instance/activity-instance-type.ts +0 -205
- package/server/service/activity-instance/activity-instance.ts +0 -262
- package/server/service/activity-instance/event-subscriber.ts +0 -44
- package/server/service/activity-instance/index.ts +0 -11
- package/server/service/activity-stats/activity-stats-query.ts +0 -94
- package/server/service/activity-stats/activity-stats-type.ts +0 -34
- package/server/service/activity-stats/index.ts +0 -3
- package/server/service/activity-summary/activity-summary-query.ts +0 -114
- package/server/service/activity-summary/activity-summary.ts +0 -16
- package/server/service/activity-summary/index.ts +0 -5
- package/server/service/activity-template/activity-template-history.ts +0 -140
- package/server/service/activity-template/activity-template-mutation.ts +0 -203
- package/server/service/activity-template/activity-template-query.ts +0 -75
- package/server/service/activity-template/activity-template-type.ts +0 -120
- package/server/service/activity-template/activity-template.ts +0 -134
- package/server/service/activity-template/event-subscriber.ts +0 -20
- package/server/service/activity-template/index.ts +0 -9
- package/server/service/activity-thread/activity-thread-history-query.ts +0 -34
- package/server/service/activity-thread/activity-thread-history.ts +0 -168
- package/server/service/activity-thread/activity-thread-mutation.ts +0 -97
- package/server/service/activity-thread/activity-thread-query.ts +0 -145
- package/server/service/activity-thread/activity-thread-subscription.ts +0 -41
- package/server/service/activity-thread/activity-thread-type.ts +0 -33
- package/server/service/activity-thread/activity-thread.ts +0 -164
- package/server/service/activity-thread/event-subscriber.ts +0 -47
- package/server/service/activity-thread/index.ts +0 -11
- package/server/service/index.ts +0 -70
- package/server/service/installable-activity/index.ts +0 -7
- package/server/service/installable-activity/installable-activity-mutation.ts +0 -61
- package/server/service/installable-activity/installable-activity-query.ts +0 -36
- package/server/service/installable-activity/installable-activity-type.ts +0 -12
- package/server/service/installable-activity/installable-activity.ts +0 -74
- package/server/tsconfig.json +0 -10
|
@@ -1,297 +0,0 @@
|
|
|
1
|
-
import gql from 'graphql-tag'
|
|
2
|
-
import { css, html, LitElement } from 'lit'
|
|
3
|
-
import { customElement, property, query } from 'lit/decorators.js'
|
|
4
|
-
|
|
5
|
-
import { client } from '@operato/graphql'
|
|
6
|
-
import { i18next, localize } from '@operato/i18n'
|
|
7
|
-
import { OxPropertyEditor } from '@operato/property-editor'
|
|
8
|
-
import { isMobileDevice } from '@operato/utils'
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
@customElement('activity-model-item-list')
|
|
12
|
-
export class ActivityModelItemList extends localize(i18next)(LitElement) {
|
|
13
|
-
static styles = [
|
|
14
|
-
css`
|
|
15
|
-
:host {
|
|
16
|
-
display: flex;
|
|
17
|
-
flex-direction: column;
|
|
18
|
-
|
|
19
|
-
background-color: #fff;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
ox-grist {
|
|
23
|
-
flex: 1;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.button-container {
|
|
27
|
-
display: flex;
|
|
28
|
-
margin-left: auto;
|
|
29
|
-
padding: var(--padding-default);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
[danger] {
|
|
33
|
-
--mdc-theme-primary: var(--mdc-danger-button-primary-color);
|
|
34
|
-
}
|
|
35
|
-
mwc-button {
|
|
36
|
-
margin-left: var(--margin-default);
|
|
37
|
-
}
|
|
38
|
-
`
|
|
39
|
-
]
|
|
40
|
-
|
|
41
|
-
@property({ type: Object }) gristConfig?:any
|
|
42
|
-
@property({ type: Object }) activity: any
|
|
43
|
-
|
|
44
|
-
@query('ox-grist') grist?: HTMLElement & { fetch: any; commit: any; deleteSelectedRecords: any; data: any }
|
|
45
|
-
|
|
46
|
-
render() {
|
|
47
|
-
return html`
|
|
48
|
-
<ox-grist
|
|
49
|
-
.mode=${isMobileDevice() ? 'CARD' : 'GRID'}
|
|
50
|
-
.config=${this.gristConfig}
|
|
51
|
-
.fetchHandler=${this.fetchHandler.bind(this)}
|
|
52
|
-
></ox-grist>
|
|
53
|
-
<div class="button-container">
|
|
54
|
-
<mwc-button raised danger @click=${this._deleteDataItems.bind(this)}>${i18next.t('button.delete')}</mwc-button>
|
|
55
|
-
<mwc-button raised @click=${this._updateDataItems.bind(this)}>${i18next.t('button.save')}</mwc-button>
|
|
56
|
-
</div>
|
|
57
|
-
`
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
async firstUpdated() {
|
|
61
|
-
this.gristConfig = {
|
|
62
|
-
list: {
|
|
63
|
-
fields: ['name', 'description', 'active']
|
|
64
|
-
},
|
|
65
|
-
columns: [
|
|
66
|
-
{ type: 'gutter', gutterName: 'row-selector', multiple: true },
|
|
67
|
-
{
|
|
68
|
-
type: 'gutter',
|
|
69
|
-
gutterName: 'button',
|
|
70
|
-
icon: 'add',
|
|
71
|
-
handlers: {
|
|
72
|
-
click: 'record-copy'
|
|
73
|
-
}
|
|
74
|
-
},
|
|
75
|
-
{ type: 'gutter', gutterName: 'sequence' },
|
|
76
|
-
{
|
|
77
|
-
type: 'gutter',
|
|
78
|
-
gutterName: 'button',
|
|
79
|
-
icon: 'arrow_upward',
|
|
80
|
-
handlers: {
|
|
81
|
-
click: 'move-up'
|
|
82
|
-
}
|
|
83
|
-
},
|
|
84
|
-
{
|
|
85
|
-
type: 'gutter',
|
|
86
|
-
gutterName: 'button',
|
|
87
|
-
icon: 'arrow_downward',
|
|
88
|
-
handlers: {
|
|
89
|
-
click: 'move-down'
|
|
90
|
-
}
|
|
91
|
-
},
|
|
92
|
-
{
|
|
93
|
-
type: 'string',
|
|
94
|
-
name: 'name',
|
|
95
|
-
header: i18next.t('field.name'),
|
|
96
|
-
record: {
|
|
97
|
-
editable: true
|
|
98
|
-
},
|
|
99
|
-
width: 140,
|
|
100
|
-
validation: (after, before, record, column) => {
|
|
101
|
-
return after
|
|
102
|
-
}
|
|
103
|
-
},
|
|
104
|
-
{
|
|
105
|
-
type: 'string',
|
|
106
|
-
name: 'description',
|
|
107
|
-
header: i18next.t('field.description'),
|
|
108
|
-
record: {
|
|
109
|
-
editable: true
|
|
110
|
-
},
|
|
111
|
-
width: 180
|
|
112
|
-
},
|
|
113
|
-
{
|
|
114
|
-
type: 'checkbox',
|
|
115
|
-
name: 'active',
|
|
116
|
-
label: true,
|
|
117
|
-
header: i18next.t('field.active'),
|
|
118
|
-
record: {
|
|
119
|
-
editable: true
|
|
120
|
-
},
|
|
121
|
-
sortable: true,
|
|
122
|
-
width: 60
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
type: 'checkbox',
|
|
126
|
-
name: 'mandatory',
|
|
127
|
-
label: true,
|
|
128
|
-
header: i18next.t('field.mandatory'),
|
|
129
|
-
record: {
|
|
130
|
-
editable: true
|
|
131
|
-
},
|
|
132
|
-
sortable: true,
|
|
133
|
-
width: 60
|
|
134
|
-
},
|
|
135
|
-
{
|
|
136
|
-
type: 'checkbox',
|
|
137
|
-
name: 'hidden',
|
|
138
|
-
label: true,
|
|
139
|
-
header: i18next.t('field.hidden'),
|
|
140
|
-
record: {
|
|
141
|
-
editable: true
|
|
142
|
-
},
|
|
143
|
-
sortable: true,
|
|
144
|
-
width: 60
|
|
145
|
-
},
|
|
146
|
-
{
|
|
147
|
-
type: 'string',
|
|
148
|
-
name: 'tag',
|
|
149
|
-
header: i18next.t('field.tag'),
|
|
150
|
-
record: {
|
|
151
|
-
editable: true
|
|
152
|
-
},
|
|
153
|
-
width: 180
|
|
154
|
-
},
|
|
155
|
-
{
|
|
156
|
-
type: 'select',
|
|
157
|
-
name: 'inout',
|
|
158
|
-
header: i18next.t('field.inout'),
|
|
159
|
-
record: {
|
|
160
|
-
options: ['', 'in', 'out', 'inout'],
|
|
161
|
-
editable: true
|
|
162
|
-
},
|
|
163
|
-
width: 60
|
|
164
|
-
},
|
|
165
|
-
{
|
|
166
|
-
type: 'select',
|
|
167
|
-
name: 'type',
|
|
168
|
-
header: i18next.t('field.type'),
|
|
169
|
-
record: {
|
|
170
|
-
options: ['', ...Object.keys(OxPropertyEditor.registry)],
|
|
171
|
-
editable: true
|
|
172
|
-
},
|
|
173
|
-
width: 120
|
|
174
|
-
},
|
|
175
|
-
{
|
|
176
|
-
type: 'parameters',
|
|
177
|
-
name: 'options',
|
|
178
|
-
header: i18next.t('field.options'),
|
|
179
|
-
record: {
|
|
180
|
-
editable: true,
|
|
181
|
-
renderer: 'json5',
|
|
182
|
-
options: async (value, column, record, row, field) => {
|
|
183
|
-
return {
|
|
184
|
-
name: record.type,
|
|
185
|
-
help: '',
|
|
186
|
-
spec:
|
|
187
|
-
record.type === 'select'
|
|
188
|
-
? [
|
|
189
|
-
{
|
|
190
|
-
type: 'options' /* property-editor type */,
|
|
191
|
-
name: 'options',
|
|
192
|
-
label: 'options'
|
|
193
|
-
}
|
|
194
|
-
]
|
|
195
|
-
: [],
|
|
196
|
-
context: this.grist,
|
|
197
|
-
objectified: true
|
|
198
|
-
}
|
|
199
|
-
}
|
|
200
|
-
},
|
|
201
|
-
width: 120
|
|
202
|
-
},
|
|
203
|
-
{
|
|
204
|
-
type: 'string',
|
|
205
|
-
name: 'unit',
|
|
206
|
-
header: i18next.t('field.unit'),
|
|
207
|
-
record: {
|
|
208
|
-
editable: true
|
|
209
|
-
},
|
|
210
|
-
width: 120
|
|
211
|
-
},
|
|
212
|
-
{
|
|
213
|
-
type: 'quantifier',
|
|
214
|
-
name: 'quantifier',
|
|
215
|
-
header: i18next.t('field.quantifier'),
|
|
216
|
-
record: {
|
|
217
|
-
editable: true
|
|
218
|
-
},
|
|
219
|
-
width: 60
|
|
220
|
-
},
|
|
221
|
-
{
|
|
222
|
-
type: 'data-item-spec',
|
|
223
|
-
name: 'spec',
|
|
224
|
-
header: i18next.t('field.spec'),
|
|
225
|
-
record: {
|
|
226
|
-
editable: true,
|
|
227
|
-
options: {
|
|
228
|
-
name: '',
|
|
229
|
-
help: '',
|
|
230
|
-
objectified: true /* prevent from stringifying */
|
|
231
|
-
}
|
|
232
|
-
},
|
|
233
|
-
width: 200
|
|
234
|
-
}
|
|
235
|
-
],
|
|
236
|
-
rows: {
|
|
237
|
-
selectable: {
|
|
238
|
-
multiple: true
|
|
239
|
-
}
|
|
240
|
-
},
|
|
241
|
-
pagination: {
|
|
242
|
-
infinite: true
|
|
243
|
-
},
|
|
244
|
-
sorters: []
|
|
245
|
-
}
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
async fetchHandler({ filters, page, limit, sortings = [] }) {
|
|
249
|
-
const model = this.activity.model || []
|
|
250
|
-
|
|
251
|
-
return {
|
|
252
|
-
total: model.length,
|
|
253
|
-
records: model
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
async _updateDataItems() {
|
|
258
|
-
this.grist?.commit()
|
|
259
|
-
|
|
260
|
-
const response = await client.mutate({
|
|
261
|
-
mutation: gql`
|
|
262
|
-
mutation ($id: String!, $patch: ActivityPatch!) {
|
|
263
|
-
updateActivity(id: $id, patch: $patch) {
|
|
264
|
-
name
|
|
265
|
-
}
|
|
266
|
-
}
|
|
267
|
-
`,
|
|
268
|
-
variables: {
|
|
269
|
-
id: this.activity.id,
|
|
270
|
-
patch: {
|
|
271
|
-
model: this.grist?.data.records,
|
|
272
|
-
cuFlag: 'M'
|
|
273
|
-
}
|
|
274
|
-
}
|
|
275
|
-
})
|
|
276
|
-
|
|
277
|
-
if (!response.errors) {
|
|
278
|
-
await document.dispatchEvent(
|
|
279
|
-
new CustomEvent('notify', {
|
|
280
|
-
detail: {
|
|
281
|
-
message: i18next.t('text.info_x_successfully', {
|
|
282
|
-
x: i18next.t('button.save')
|
|
283
|
-
})
|
|
284
|
-
}
|
|
285
|
-
})
|
|
286
|
-
)
|
|
287
|
-
}
|
|
288
|
-
}
|
|
289
|
-
|
|
290
|
-
async _deleteDataItems() {
|
|
291
|
-
if (!confirm(i18next.t('text.sure_to_x', { x: i18next.t('text.delete') }))) {
|
|
292
|
-
return
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
this.grist?.deleteSelectedRecords(false)
|
|
296
|
-
}
|
|
297
|
-
}
|
|
@@ -1,431 +0,0 @@
|
|
|
1
|
-
import '@operato/property-editor/ox-properties-dynamic-view.js'
|
|
2
|
-
import '@operato/board/ox-board-viewer.js'
|
|
3
|
-
|
|
4
|
-
import gql from 'graphql-tag'
|
|
5
|
-
import { css, html } from 'lit'
|
|
6
|
-
import { unsafeHTML } from 'lit-html/directives/unsafe-html.js'
|
|
7
|
-
import { customElement, property, query } from 'lit/decorators.js'
|
|
8
|
-
import { connect } from 'pwa-helpers/connect-mixin.js'
|
|
9
|
-
|
|
10
|
-
import { client } from '@operato/graphql'
|
|
11
|
-
import { i18next, localize } from '@operato/i18n'
|
|
12
|
-
import { PageView, store } from '@operato/shell'
|
|
13
|
-
import { CommonButtonStyles, ScrollbarStyles } from '@operato/styles'
|
|
14
|
-
import { provider } from '@things-factory/board-ui'
|
|
15
|
-
|
|
16
|
-
const formatter = new Intl.DateTimeFormat(navigator.language, { dateStyle: 'full', timeStyle: 'short' })
|
|
17
|
-
|
|
18
|
-
export const ActivityInstanceStatus = {
|
|
19
|
-
Draft: 'draft',
|
|
20
|
-
Issued: 'issued',
|
|
21
|
-
PendingAssignment: 'pending-assignment',
|
|
22
|
-
Assigned: 'assigned',
|
|
23
|
-
Started: 'started',
|
|
24
|
-
Pending: 'pending',
|
|
25
|
-
Ended: 'ended',
|
|
26
|
-
Aborted: 'aborted'
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
@customElement('activity-page')
|
|
30
|
-
export class ActivityPage extends connect(store)(localize(i18next)(PageView)) {
|
|
31
|
-
static styles = [
|
|
32
|
-
ScrollbarStyles,
|
|
33
|
-
css`
|
|
34
|
-
:host {
|
|
35
|
-
display: flex;
|
|
36
|
-
flex-direction: column;
|
|
37
|
-
|
|
38
|
-
width: 100%;
|
|
39
|
-
padding: 5px;
|
|
40
|
-
overflow: auto;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
[header] {
|
|
44
|
-
display: block;
|
|
45
|
-
padding: 5px;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
[content] {
|
|
49
|
-
flex: 1;
|
|
50
|
-
display: block;
|
|
51
|
-
padding: 5px;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
ox-board-viewer {
|
|
55
|
-
width: 100%;
|
|
56
|
-
height: 100%;
|
|
57
|
-
}
|
|
58
|
-
`
|
|
59
|
-
]
|
|
60
|
-
|
|
61
|
-
@property({ type: Object }) activityInstance: any
|
|
62
|
-
@property({ type: Object }) board: any
|
|
63
|
-
|
|
64
|
-
get context() {
|
|
65
|
-
const startable = [ActivityInstanceStatus.Assigned, ActivityInstanceStatus.Issued].includes(
|
|
66
|
-
this.activityInstance?.state
|
|
67
|
-
)
|
|
68
|
-
|
|
69
|
-
const finishable = [ActivityInstanceStatus.Started].includes(this.activityInstance?.state)
|
|
70
|
-
const savable = finishable
|
|
71
|
-
|
|
72
|
-
return {
|
|
73
|
-
title: this.lifecycle?.params?.['title'] || i18next.t('title.activity'),
|
|
74
|
-
help: 'worklist/activity',
|
|
75
|
-
actions: [
|
|
76
|
-
startable && {
|
|
77
|
-
title: i18next.t('button.play'),
|
|
78
|
-
action: this._startActivityInstance.bind(this),
|
|
79
|
-
...CommonButtonStyles.play
|
|
80
|
-
},
|
|
81
|
-
|
|
82
|
-
savable && {
|
|
83
|
-
title: i18next.t('button.save'),
|
|
84
|
-
action: this._saveActivityInstance.bind(this),
|
|
85
|
-
...CommonButtonStyles.save
|
|
86
|
-
},
|
|
87
|
-
|
|
88
|
-
finishable && {
|
|
89
|
-
title: i18next.t('button.finish'),
|
|
90
|
-
action: this._endActivityInstance.bind(this),
|
|
91
|
-
...CommonButtonStyles.save
|
|
92
|
-
}
|
|
93
|
-
].filter(Boolean /* truthy only */)
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
render() {
|
|
98
|
-
const { name, description, state, thumbnail, dueAt, createdAt } = this.activityInstance || {}
|
|
99
|
-
return html`
|
|
100
|
-
<div header>
|
|
101
|
-
<div>name: ${name}</div>
|
|
102
|
-
<div>description: ${description}</div>
|
|
103
|
-
<div>state: ${state}</div>
|
|
104
|
-
<div>posted at: ${createdAt && formatter.format(new Date(createdAt))}</div>
|
|
105
|
-
<div>due at: ${dueAt && formatter.format(new Date(dueAt))}</div>
|
|
106
|
-
<img src=${thumbnail} />
|
|
107
|
-
</div>
|
|
108
|
-
|
|
109
|
-
<div content>${this.activityContent()}</div>
|
|
110
|
-
`
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
activityContent() {
|
|
114
|
-
switch (this.activityInstance?.uiType) {
|
|
115
|
-
case 'template':
|
|
116
|
-
return this.templateContent()
|
|
117
|
-
case 'generated':
|
|
118
|
-
return this.generatedContent()
|
|
119
|
-
case 'board':
|
|
120
|
-
return this.boardContent()
|
|
121
|
-
case 'page':
|
|
122
|
-
case 'external':
|
|
123
|
-
default:
|
|
124
|
-
return html``
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
templateContent() {
|
|
129
|
-
const { uiSource: template } = this.activityInstance
|
|
130
|
-
return unsafeHTML(template)
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
getInputSpec() {
|
|
134
|
-
const model = this.activityInstance?.activity?.model
|
|
135
|
-
|
|
136
|
-
return (model || [])
|
|
137
|
-
.filter(item => item.inout === 'in' || item.inout === 'inout')
|
|
138
|
-
.map(item => {
|
|
139
|
-
return {
|
|
140
|
-
...item,
|
|
141
|
-
name: item.tag,
|
|
142
|
-
label: item.tKey || item.name,
|
|
143
|
-
property: item.options
|
|
144
|
-
}
|
|
145
|
-
})
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
getOutputSpec() {
|
|
149
|
-
const model = this.activityInstance?.activity?.model
|
|
150
|
-
|
|
151
|
-
return (model || [])
|
|
152
|
-
.filter(item => item.inout === 'inout' || item.inout === 'out')
|
|
153
|
-
.map(item => {
|
|
154
|
-
return {
|
|
155
|
-
...item,
|
|
156
|
-
name: item.tag,
|
|
157
|
-
label: item.tKey || item.name,
|
|
158
|
-
property: item.options
|
|
159
|
-
}
|
|
160
|
-
})
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
generatedContent() {
|
|
164
|
-
var { input, output } = this.activityInstance || {}
|
|
165
|
-
|
|
166
|
-
const inputSpec = this.getInputSpec()
|
|
167
|
-
const outputSpec = this.getOutputSpec()
|
|
168
|
-
|
|
169
|
-
if (!output) {
|
|
170
|
-
output = inputSpec
|
|
171
|
-
.filter(item => item.inout === 'inout')
|
|
172
|
-
.reduce((inout, item) => {
|
|
173
|
-
inout[item.name] = input[item.name]
|
|
174
|
-
return inout
|
|
175
|
-
}, {})
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
return html`
|
|
179
|
-
<fieldset>
|
|
180
|
-
<legend>Input</legend>
|
|
181
|
-
<ox-properties-dynamic-view data-name="input" .props=${inputSpec} .value=${input}></ox-properties-dynamic-view>
|
|
182
|
-
</fieldset>
|
|
183
|
-
|
|
184
|
-
<fieldset>
|
|
185
|
-
<legend>Output</legend>
|
|
186
|
-
<ox-properties-dynamic-view
|
|
187
|
-
data-name="output"
|
|
188
|
-
.props=${outputSpec}
|
|
189
|
-
.value=${output}
|
|
190
|
-
@property-change=${e => (this.activityInstance.output = e.currentTarget.value)}
|
|
191
|
-
></ox-properties-dynamic-view>
|
|
192
|
-
</fieldset>
|
|
193
|
-
`
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
boardContent() {
|
|
197
|
-
const { uiSource: boardId, input, output } = this.activityInstance
|
|
198
|
-
|
|
199
|
-
if (!this.board || this.board.id !== boardId) {
|
|
200
|
-
this.board = {
|
|
201
|
-
id: boardId
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
return html`
|
|
206
|
-
<ox-board-viewer
|
|
207
|
-
style="background-color: white;"
|
|
208
|
-
.board=${this.board}
|
|
209
|
-
.provider=${provider}
|
|
210
|
-
.values=${{ ...input, ...output }}
|
|
211
|
-
hide-fullscreen
|
|
212
|
-
hide-navigation
|
|
213
|
-
></ox-board-viewer>
|
|
214
|
-
`
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
@query('ox-board-viewer') boardViewer: any
|
|
218
|
-
|
|
219
|
-
getOutputFromBoard() {
|
|
220
|
-
const outputSpec = this.getOutputSpec()
|
|
221
|
-
const data = this.boardViewer.getSceneValues()
|
|
222
|
-
|
|
223
|
-
return outputSpec.reduce((output, spec) => {
|
|
224
|
-
output[spec.name] = data[spec.name]
|
|
225
|
-
return output
|
|
226
|
-
}, {})
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
updated(changes) {
|
|
230
|
-
if (changes.has('activityInstance')) {
|
|
231
|
-
this.updateContext()
|
|
232
|
-
}
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
async pageUpdated(changes, lifecycle, changedBefore) {
|
|
236
|
-
if (this.active) {
|
|
237
|
-
this.fetchActivityInstance(lifecycle.resourceId)
|
|
238
|
-
}
|
|
239
|
-
}
|
|
240
|
-
|
|
241
|
-
async fetchActivityInstance(id) {
|
|
242
|
-
const response = await client.query({
|
|
243
|
-
query: gql`
|
|
244
|
-
query activityInstance($id: String!) {
|
|
245
|
-
activityInstance(id: $id) {
|
|
246
|
-
id
|
|
247
|
-
name
|
|
248
|
-
description
|
|
249
|
-
state
|
|
250
|
-
activity {
|
|
251
|
-
model {
|
|
252
|
-
name
|
|
253
|
-
description
|
|
254
|
-
active
|
|
255
|
-
tag
|
|
256
|
-
inout
|
|
257
|
-
type
|
|
258
|
-
unit
|
|
259
|
-
options
|
|
260
|
-
quantifier
|
|
261
|
-
spec
|
|
262
|
-
}
|
|
263
|
-
}
|
|
264
|
-
thumbnail
|
|
265
|
-
input
|
|
266
|
-
output
|
|
267
|
-
uiType
|
|
268
|
-
uiSource
|
|
269
|
-
dueAt
|
|
270
|
-
createdAt
|
|
271
|
-
}
|
|
272
|
-
}
|
|
273
|
-
`,
|
|
274
|
-
variables: {
|
|
275
|
-
id
|
|
276
|
-
}
|
|
277
|
-
})
|
|
278
|
-
|
|
279
|
-
this.activityInstance = response.data.activityInstance
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
async _startActivityInstance() {
|
|
283
|
-
var { id, output, reason, uiType } = this.activityInstance
|
|
284
|
-
if (uiType === 'board') {
|
|
285
|
-
output = this.getOutputFromBoard()
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
const response = await client.mutate({
|
|
289
|
-
mutation: gql`
|
|
290
|
-
mutation ($id: String!, $output: Object) {
|
|
291
|
-
startActivityInstance(id: $id, output: $output) {
|
|
292
|
-
name
|
|
293
|
-
}
|
|
294
|
-
}
|
|
295
|
-
`,
|
|
296
|
-
variables: {
|
|
297
|
-
id,
|
|
298
|
-
output
|
|
299
|
-
}
|
|
300
|
-
})
|
|
301
|
-
|
|
302
|
-
if (!response.errors) {
|
|
303
|
-
await this.fetchActivityInstance(this.activityInstance.id)
|
|
304
|
-
|
|
305
|
-
document.dispatchEvent(
|
|
306
|
-
new CustomEvent('notify', {
|
|
307
|
-
detail: {
|
|
308
|
-
message: i18next.t('text.task_is_started_successfully')
|
|
309
|
-
}
|
|
310
|
-
})
|
|
311
|
-
)
|
|
312
|
-
}
|
|
313
|
-
}
|
|
314
|
-
|
|
315
|
-
async _saveActivityInstance() {
|
|
316
|
-
var { id, output, reason, uiType } = this.activityInstance
|
|
317
|
-
if (uiType === 'board') {
|
|
318
|
-
output = this.getOutputFromBoard()
|
|
319
|
-
}
|
|
320
|
-
|
|
321
|
-
const response = await client.mutate({
|
|
322
|
-
mutation: gql`
|
|
323
|
-
mutation ($id: String!, $save: ActivityInstanceSave!) {
|
|
324
|
-
draftActivityInstance(id: $id, save: $save) {
|
|
325
|
-
id
|
|
326
|
-
name
|
|
327
|
-
description
|
|
328
|
-
state
|
|
329
|
-
activity {
|
|
330
|
-
model {
|
|
331
|
-
name
|
|
332
|
-
description
|
|
333
|
-
active
|
|
334
|
-
tag
|
|
335
|
-
inout
|
|
336
|
-
type
|
|
337
|
-
unit
|
|
338
|
-
options
|
|
339
|
-
quantifier
|
|
340
|
-
spec
|
|
341
|
-
}
|
|
342
|
-
}
|
|
343
|
-
thumbnail
|
|
344
|
-
input
|
|
345
|
-
output
|
|
346
|
-
uiType
|
|
347
|
-
uiSource
|
|
348
|
-
dueAt
|
|
349
|
-
createdAt
|
|
350
|
-
}
|
|
351
|
-
}
|
|
352
|
-
`,
|
|
353
|
-
variables: {
|
|
354
|
-
id,
|
|
355
|
-
save: {
|
|
356
|
-
output
|
|
357
|
-
}
|
|
358
|
-
}
|
|
359
|
-
})
|
|
360
|
-
|
|
361
|
-
if (!response.errors) {
|
|
362
|
-
this.activityInstance = response.data.saveActivityInstance
|
|
363
|
-
|
|
364
|
-
document.dispatchEvent(
|
|
365
|
-
new CustomEvent('notify', {
|
|
366
|
-
detail: {
|
|
367
|
-
message: i18next.t('text.task_is_saved_successfully')
|
|
368
|
-
}
|
|
369
|
-
})
|
|
370
|
-
)
|
|
371
|
-
}
|
|
372
|
-
}
|
|
373
|
-
|
|
374
|
-
async _endActivityInstance() {
|
|
375
|
-
var { id, output, reason, uiType } = this.activityInstance
|
|
376
|
-
if (uiType === 'board') {
|
|
377
|
-
output = this.getOutputFromBoard()
|
|
378
|
-
}
|
|
379
|
-
|
|
380
|
-
const response = await client.mutate({
|
|
381
|
-
mutation: gql`
|
|
382
|
-
mutation ($id: String!, $output: Object, $reason: String) {
|
|
383
|
-
endActivityInstance(id: $id, output: $output, reason: $reason) {
|
|
384
|
-
id
|
|
385
|
-
name
|
|
386
|
-
description
|
|
387
|
-
state
|
|
388
|
-
activity {
|
|
389
|
-
model {
|
|
390
|
-
name
|
|
391
|
-
description
|
|
392
|
-
active
|
|
393
|
-
tag
|
|
394
|
-
inout
|
|
395
|
-
type
|
|
396
|
-
unit
|
|
397
|
-
options
|
|
398
|
-
quantifier
|
|
399
|
-
spec
|
|
400
|
-
}
|
|
401
|
-
}
|
|
402
|
-
thumbnail
|
|
403
|
-
input
|
|
404
|
-
output
|
|
405
|
-
uiType
|
|
406
|
-
uiSource
|
|
407
|
-
dueAt
|
|
408
|
-
createdAt
|
|
409
|
-
}
|
|
410
|
-
}
|
|
411
|
-
`,
|
|
412
|
-
variables: {
|
|
413
|
-
id,
|
|
414
|
-
output,
|
|
415
|
-
reason
|
|
416
|
-
}
|
|
417
|
-
})
|
|
418
|
-
|
|
419
|
-
if (!response.errors) {
|
|
420
|
-
this.activityInstance = response.data.endActivityInstance
|
|
421
|
-
|
|
422
|
-
document.dispatchEvent(
|
|
423
|
-
new CustomEvent('notify', {
|
|
424
|
-
detail: {
|
|
425
|
-
message: i18next.t('text.task_is_finished_successfully')
|
|
426
|
-
}
|
|
427
|
-
})
|
|
428
|
-
)
|
|
429
|
-
}
|
|
430
|
-
}
|
|
431
|
-
}
|