提交 edc6edaf authored 作者: wangjiahao's avatar wangjiahao

fix: 表格明细无需显示导出图片按钮

上级 c0140baf
......@@ -38,7 +38,7 @@
</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item @click.native="exportExcel"><svg-icon icon-class="ds-excel" class="ds-icon-excel" />Excle</el-dropdown-item>
<el-dropdown-item icon="el-icon-picture-outline" @click.native="exportViewImg">{{ $t('chart.image') }}</el-dropdown-item>
<el-dropdown-item v-if="showExportImgButton" icon="el-icon-picture-outline" @click.native="exportViewImg">{{ $t('chart.image') }}</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</span>
......@@ -137,6 +137,9 @@ export default {
created() {
},
computed: {
showExportImgButton() {
return this.showChartInfo.type && !this.showChartInfo.type.includes('table')
},
canvasInfoMainStyle() {
if (this.backScreenShot) {
return {
......
......@@ -160,7 +160,7 @@
</el-button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item @click.native="exportExcel"><svg-icon icon-class="ds-excel" class="ds-icon-excel" />Excle</el-dropdown-item>
<el-dropdown-item icon="el-icon-picture-outline" @click.native="exportViewImg">{{ $t('chart.image') }}</el-dropdown-item>
<el-dropdown-item v-if="showExportImgButton" icon="el-icon-picture-outline" @click.native="exportViewImg">{{ $t('chart.image') }}</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</span>
......@@ -952,6 +952,10 @@ export default {
}
},
computed: {
showExportImgButton() {
// if the chart type belong to table,'export image' button should be hidden
return this.showChartInfo.type && !this.showChartInfo.type.includes('table')
},
showGrid() {
if (this.canvasStyleData && this.canvasStyleData.aidedDesign) {
return this.canvasStyleData.aidedDesign.showGrid
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论