|
@@ -179,9 +179,9 @@ export default {
|
|
|
var ele = this.preview
|
|
|
setTimeout(() => {
|
|
|
const targetDom = document.getElementById('Gambol')
|
|
|
- var copyDom = targetDom.cloneNode(true)
|
|
|
- document.querySelector('body').appendChild(copyDom)
|
|
|
- html2canvas(document.getElementsByClassName('reportContent')[1], { useCORS: true }).then(canvas => {
|
|
|
+ // var copyDom = targetDom.cloneNode(true)
|
|
|
+ // document.querySelector('body').appendChild(copyDom)
|
|
|
+ html2canvas(document.getElementsByClassName('reportContent')[0], { useCORS: true }).then(canvas => {
|
|
|
var url = canvas.toDataURL('image/png', 1)
|
|
|
url = url.toString().substring(url.indexOf(',') + 1)
|
|
|
var postData = { 'reportId': ele.id, 'imgStr': url, 'url': window.location.href, 'emailUser': e.name, 'copyTo': e.names }
|
|
@@ -189,7 +189,7 @@ export default {
|
|
|
res.code === 200 ? this.$message({ type: 'success', message: '发送测试报告成功' }) : this.$message({ type: 'error', message: '发送测试报告失败,请联系管理员!' })
|
|
|
this.send = false
|
|
|
this.handleClose()
|
|
|
- document.querySelector('body').removeChild(copyDom)
|
|
|
+ // document.querySelector('body').removeChild(copyDom)
|
|
|
loading.close()
|
|
|
})
|
|
|
})
|