Unverified 提交 c8a84337 authored 作者: 王嘉豪's avatar 王嘉豪 提交者: GitHub

Merge pull request #1355 from dataease/pr@v1.5@refactor_panel-pdf

refactor: 仪表板导出pdf优化,防止导出画面不全
......@@ -4,6 +4,7 @@ export function tree(data) {
return request({
url: '/api/panelView/tree',
method: 'post',
timeout: 30000,
data
})
}
......@@ -12,6 +13,7 @@ export function viewsWithIds(data) {
return request({
url: '/api/panelView/viewsWithIds',
method: 'post',
timeout: 30000,
loading: true,
data
})
......@@ -21,6 +23,7 @@ export function findOne(id) {
return request({
url: '/api/panelView/findOne/' + id,
method: 'get',
timeout: 30000,
loading: true
})
}
......
......@@ -4,6 +4,7 @@
<div
id="canvasInfoTemp"
ref="canvasInfoTemp"
:style="{height:mainHeight}"
class="main-class"
@mouseup="deselectCurComponent"
@mousedown="handleMouseDown"
......@@ -153,8 +154,14 @@ export default {
erd.listenTo(mainDom, element => {
_this.$nextTick(() => {
_this.restore()
})
})
// 监听div变动事件
const tempCanvas = document.getElementById('canvasInfoTemp')
erd.listenTo(tempCanvas, element => {
_this.$nextTick(() => {
// 将mainHeight 修改为px 临时解决html2canvas 截图不全的问题
_this.mainHeight = mainDom.scrollHeight + 'px!important'
_this.mainHeight = tempCanvas.scrollHeight + 'px!important'
})
})
eventBus.$on('openChartDetailsDialog', this.openChartDetailsDialog)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论