From 4d7b1eff0b476562fce9e8b557319e2aac080c01 Mon Sep 17 00:00:00 2001 From: Feynman Date: Thu, 30 Nov 2023 15:11:42 +0800 Subject: [PATCH] feat(dfs): extend task tour information --- apps/dfs/src/components/guide/Deploy.vue | 8 +------- apps/dfs/src/store/index.js | 7 ++++++- .../src/components/create-connection/SceneDialog.vue | 6 ++++-- .../src/components/create-connection/SceneForm.vue | 1 + packages/ldp/src/ReplicationBoard.vue | 11 +++++++++-- packages/ldp/src/TargetPanel.vue | 9 +++++++-- 6 files changed, 28 insertions(+), 14 deletions(-) diff --git a/apps/dfs/src/components/guide/Deploy.vue b/apps/dfs/src/components/guide/Deploy.vue index 0ef24948b2..8fb31c225c 100644 --- a/apps/dfs/src/components/guide/Deploy.vue +++ b/apps/dfs/src/components/guide/Deploy.vue @@ -182,13 +182,7 @@ export default {
{{ $t('dfs_guide_index_waiting_for_deployment_tip') }}
- {{ $t('dfs_guide_index_development_complete') }} diff --git a/apps/dfs/src/store/index.js b/apps/dfs/src/store/index.js index 6b03b308f1..51b5a60b0e 100644 --- a/apps/dfs/src/store/index.js +++ b/apps/dfs/src/store/index.js @@ -37,7 +37,12 @@ const store = new Vuex.Store({ activeIndex: null, behavior: '', // add-source, add-target, add-task status: '', // starting, completed, paused - view: 'list' // board, list + view: 'list', // board, list + sourceConnectionId: '', + targetConnectionId: '', + isDemoSource: null, + isDemoTarget: null, + taskId: '' }, // 新人引导 guide: { diff --git a/packages/business/src/components/create-connection/SceneDialog.vue b/packages/business/src/components/create-connection/SceneDialog.vue index f6b3db3a79..5c7d04db31 100644 --- a/packages/business/src/components/create-connection/SceneDialog.vue +++ b/packages/business/src/components/create-connection/SceneDialog.vue @@ -201,7 +201,8 @@ export default { name: '', pdkHash: null, pdkId: null, - md: null + md: null, + isDemo: false }, selected: {}, showForm: false, @@ -457,7 +458,8 @@ export default { icon: null, pdkHash: item.pdkHash, pdkId: item.pdkId, - pdkOptions: item + pdkOptions: item, + isDemo }) this.selected = item this.showForm = true diff --git a/packages/business/src/components/create-connection/SceneForm.vue b/packages/business/src/components/create-connection/SceneForm.vue index 41200a342e..77d542e292 100644 --- a/packages/business/src/components/create-connection/SceneForm.vue +++ b/packages/business/src/components/create-connection/SceneForm.vue @@ -294,6 +294,7 @@ export default { } promise .then(data => { + data.isDemo = this.params.isDemo // 标记是否是demo数据源 this.buried('connectionSubmit', '', { result: true }) diff --git a/packages/ldp/src/ReplicationBoard.vue b/packages/ldp/src/ReplicationBoard.vue index bacf472f40..8e594ab345 100644 --- a/packages/ldp/src/ReplicationBoard.vue +++ b/packages/ldp/src/ReplicationBoard.vue @@ -208,10 +208,17 @@ export default { if (this.startingTour) { let type = this.selectorType type = type.charAt(0).toUpperCase() + type.slice(1) - this.$store.commit('setTourBehavior', 'add-' + this.selectorType) + + this.$store.commit('setReplicationTour', { + behavior: 'add-' + this.selectorType, + [`${this.selectorType}ConnectionId`]: connection.id, + [`isDemo${type}`]: connection.isDemo + }) + // 上报引导创建源/目标连接 this.buried(`guideCreate${type}Connection`, '', { - result: true + result: true, + connectionId: connection.id }) } diff --git a/packages/ldp/src/TargetPanel.vue b/packages/ldp/src/TargetPanel.vue index 54043fbac1..92d834c396 100644 --- a/packages/ldp/src/TargetPanel.vue +++ b/packages/ldp/src/TargetPanel.vue @@ -999,9 +999,14 @@ export default { }) if (this.startingTour) { - this.$store.commit('setTourBehavior', 'add-task') + this.$store.commit('setReplicationTour', { + behavior: 'add-task', + taskId: taskInfo.id + }) // 上报引导创任务 - this.buried(`guideCreateTask`, '') + this.buried(`guideCreateTask`, { + taskId: taskInfo.id + }) } } })