NEZ-1243 fix: asset endpint 底部弹窗添加同步按钮

This commit is contained in:
zhangyu
2021-11-16 17:30:01 +08:00
parent 78d56bedf1
commit 81e62990f9
3 changed files with 7 additions and 3 deletions

View File

@@ -41,6 +41,9 @@
<el-dropdown-item v-has="'panel_chart_add'">
<div id="chart-temp-add" @click="addChartByTemp"><i class="nz-icon nz-icon-add"></i>{{ $t('overall.AddByTemplate') }}</div>
</el-dropdown-item>
<el-dropdown-item v-has="'panel_chart_edit'">
<div id="chart-temp-sync" @click="chartBySync"><i class="nz-icon nz-icon-sync"></i>{{ $t('overall.syncChart') }}</div>
</el-dropdown-item>
</template>
</top-tool-more-options>
</div>
@@ -74,6 +77,9 @@
<el-dropdown-item v-has="'panel_chart_add'">
<div id="chart-temp-add" @click="addChartByTemp"><i class="nz-icon nz-icon-add"></i>{{ $t('overall.AddByTemplate') }}</div>
</el-dropdown-item>
<el-dropdown-item v-has="'panel_chart_edit'">
<div id="chart-temp-sync" @click="chartBySync"><i class="nz-icon nz-icon-sync"></i>{{ $t('overall.syncChart') }}</div>
</el-dropdown-item>
</template>
</top-tool-more-options>
</div>
@@ -553,7 +559,7 @@ export default {
chartBySync () {
this.$post('visual/panel/chart/syncTmpl', { pid: this.obj.id }).then(res => {
if (res.code === 200) {
this.getTableData()
this.getTableData(this.obj.id)
this.$message.success(this.$t('tip.syncSuccess'))
} else {
this.$message.error(res.msg)