fix:修复 chart 操作按钮点击不收回的问题

This commit is contained in:
zhangyu
2022-04-15 17:57:55 +08:00
parent 90a0750acd
commit 4a658570b9
2 changed files with 8 additions and 1 deletions

View File

@@ -73,7 +73,7 @@
<i class="el-icon-copy-document" style="font-size: 16px;"></i>
<span>{{$t('dashboard.duplicate')}}</span>
</li>
<li v-if="from !== this.$CONSTANTS.fromRoute.chartTemp && chartInfo.pid" v-has="'main_edit'" class="el-dropdown-menu__item" @click="$emit('sync')">
<li v-if="from !== this.$CONSTANTS.fromRoute.chartTemp && chartInfo.pid" v-has="'main_edit'" class="el-dropdown-menu__item" @click="sync">
<i class="nz-icon nz-icon-sync" style="font-size: 16px;"></i>
<span>{{$t('overall.syncChart')}}</span>
</li>

View File

@@ -43,18 +43,25 @@ export default {
chart: this.chartInfo,
type: 'edit'
})
this.dropdownMenuShow = false
},
removeChart () {
this.$store.dispatch('dispatchDelChart', {
chart: this.chartInfo,
type: 'delete'
})
this.dropdownMenuShow = false
},
duplicate () {
this.$store.dispatch('dispatchEditChart', {
chart: this.chartInfo,
type: 'duplicate'
})
this.dropdownMenuShow = false
},
sync () {
this.$emit('sync')
this.dropdownMenuShow = false
},
clickos () {
this.dropdownMenuShow = false