Skip to content

Commit

Permalink
feat(dfs): extend task tour information
Browse files Browse the repository at this point in the history
  • Loading branch information
cn-xufei committed Dec 20, 2023
1 parent 50270ae commit 41cef46
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 14 deletions.
8 changes: 1 addition & 7 deletions apps/dfs/src/components/guide/Deploy.vue
Original file line number Diff line number Diff line change
Expand Up @@ -181,13 +181,7 @@ export default {
<!--等待提示-->
<div class="font-color-light">{{ $t('dfs_guide_index_waiting_for_deployment_tip') }}</div>

<ElButton
class="mt-4"
plain
size="default"
type="primary"
:disabled="activeKey === 'Scenes' && !scenes.length"
@click="handleComplete"
<ElButton class="mt-4" plain size="default" type="primary" @click="handleComplete"
>{{ $t('dfs_guide_index_development_complete') }}
</ElButton>
</template>
Expand Down
7 changes: 6 additions & 1 deletion apps/dfs/src/store/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -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: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,8 @@ export default {
name: '',
pdkHash: null,
pdkId: null,
md: null
md: null,
isDemo: false
},
selected: {},
showForm: false,
Expand Down Expand Up @@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,7 @@ export default {
}
promise
.then(data => {
data.isDemo = this.params.isDemo // 标记是否是demo数据源
this.buried('connectionSubmit', '', {
result: true
})
Expand Down
11 changes: 9 additions & 2 deletions packages/ldp/src/ReplicationBoard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -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
})
}
Expand Down
9 changes: 7 additions & 2 deletions packages/ldp/src/TargetPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -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
})
}
}
})
Expand Down

0 comments on commit 41cef46

Please sign in to comment.