|
@@ -431,6 +431,7 @@
|
|
},
|
|
},
|
|
printclose() {
|
|
printclose() {
|
|
this.isShowPrint = false
|
|
this.isShowPrint = false
|
|
|
|
+
|
|
this.getList()
|
|
this.getList()
|
|
},
|
|
},
|
|
printSmall() {
|
|
printSmall() {
|
|
@@ -535,9 +536,11 @@
|
|
url:this.global.uploadPath,
|
|
url:this.global.uploadPath,
|
|
data: formdata,
|
|
data: formdata,
|
|
}).then((response) => {
|
|
}).then((response) => {
|
|
|
|
+ // debugger
|
|
|
|
+ // console.log(response,111111111111)
|
|
//编辑接口
|
|
//编辑接口
|
|
- this.printData.pictureAddress = response.data.url
|
|
|
|
- this.inspect.pictureAddress = response.data.url
|
|
|
|
|
|
+ this.printData.pictureAddress = response.data.data.url
|
|
|
|
+ this.inspect.pictureAddress = response.data.data.url
|
|
addOut(this.inspect)
|
|
addOut(this.inspect)
|
|
.toPromise()
|
|
.toPromise()
|
|
.then((response) => {})
|
|
.then((response) => {})
|
|
@@ -546,27 +549,27 @@
|
|
})
|
|
})
|
|
},
|
|
},
|
|
closeDialog() {
|
|
closeDialog() {
|
|
- html2canvas(this.$refs.saveImg.$el).then((canvas) => {
|
|
|
|
- let dataURL = canvas.toDataURL('image/png')
|
|
|
|
- this.imgUrl = dataURL
|
|
|
|
- if (this.imgUrl !== '') {
|
|
|
|
- let b = this.dataURLtoFile(this.imgUrl, 'printImage')
|
|
|
|
- let formdata = new FormData()
|
|
|
|
- formdata.append('file', b)
|
|
|
|
- axios({
|
|
|
|
- method: 'post',
|
|
|
|
- url:this.global.uploadPath,
|
|
|
|
- data: formdata,
|
|
|
|
- }).then((response) => {
|
|
|
|
- //编辑接口
|
|
|
|
- this.printData.pictureAddress = response.data.url
|
|
|
|
- this.inspect.pictureAddress = response.data.url
|
|
|
|
- addOut(this.inspect)
|
|
|
|
- .toPromise()
|
|
|
|
- .then((response) => {})
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
|
|
+ // html2canvas(this.$refs.saveImg.$el).then((canvas) => {
|
|
|
|
+ // let dataURL = canvas.toDataURL('image/png')
|
|
|
|
+ // this.imgUrl = dataURL
|
|
|
|
+ // if (this.imgUrl !== '') {
|
|
|
|
+ // let b = this.dataURLtoFile(this.imgUrl, 'printImage')
|
|
|
|
+ // let formdata = new FormData()
|
|
|
|
+ // formdata.append('file', b)
|
|
|
|
+ // axios({
|
|
|
|
+ // method: 'post',
|
|
|
|
+ // url:this.global.uploadPath,
|
|
|
|
+ // data: formdata,
|
|
|
|
+ // }).then((response) => {
|
|
|
|
+ // //编辑接口
|
|
|
|
+ // this.printData.pictureAddress = response.data.url
|
|
|
|
+ // this.inspect.pictureAddress = response.data.url
|
|
|
|
+ // addOut(this.inspect)
|
|
|
|
+ // .toPromise()
|
|
|
|
+ // .then((response) => {})
|
|
|
|
+ // })
|
|
|
|
+ // }
|
|
|
|
+ // })
|
|
this.isShowPrint = false
|
|
this.isShowPrint = false
|
|
},
|
|
},
|
|
print() {
|
|
print() {
|