zss
2024-01-05 a6d2cf654791065fe9ae41712c147f70380a13f0
src/views/plan/customerorder/index.vue
@@ -879,8 +879,18 @@
            this.$message.error("请选择一条数据")
            return
        }
        downloadWordFile(ids).then(res=>{
            transform(res)
        downloadWordFile(ids).then(response=>{
          // 处理返回的文件流
          const blob = response.data
          const link = document.createElement('a')
          link.href = URL.createObjectURL(blob)
          link.download = '工艺文件.docx'
          document.body.appendChild(link)
          link.click()
          window.setTimeout(function() {
            URL.revokeObjectURL(blob)
            document.body.removeChild(link)
          }, 0)
        }).catch(error=>{
            console.error(error);
        })