qinzhipeng_v 5 years ago
parent
commit
3a208872a4
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/views/Platform/presentation/Templates/TestReport.vue

+ 2 - 1
src/views/Platform/presentation/Templates/TestReport.vue

@@ -216,7 +216,7 @@ export default {
       const ele = this.preview
       setTimeout(() => {
         const targetDom = document.getElementById('resumeId')
-        const copyDom = targetDom.cloneNode(true)
+        let copyDom = targetDom.cloneNode(true)
         document.querySelector('body').appendChild(copyDom)
         html2canvas(copyDom, { useCORS: true }).then(canvas => {
           const imgData = canvas.toDataURL('image/png')
@@ -226,6 +226,7 @@ export default {
             res.code === 200 ? this.$message.success('发送测试报告成功') : this.$message.error('发送测试报告失败,请联系管理员!')
             this.handleClose1()
             document.querySelector('body').removeChild(copyDom)
+            copyDom = null
           })
         })
       }, 500)