diff --git a/src/components/doctorCheck/CheckPicture.vue b/src/components/doctorCheck/CheckPicture.vue index e0267bc..cc3a2ee 100644 --- a/src/components/doctorCheck/CheckPicture.vue +++ b/src/components/doctorCheck/CheckPicture.vue @@ -194,6 +194,7 @@ export default { } }, + // 采图 btnGetPic() { if (!this.doctorCheck.RegisterCheckId) { this.$message.warning({ showClose: true, message: "未选中组合项目!" }); @@ -235,15 +236,19 @@ export default { break; } this.checkPictures.push({ pictureFilename: baseHead + lres.data.Image }) + let fileName = lres.data.FilePath + let dotIndex = fileName.lastIndexOf('\\'); + if (dotIndex > -1) fileName = fileName.substring(dotIndex, fileName.length); let body = { registerCheckId: this.dataTransOpts.tableS.register_check.id, pictureBaseStrs: [{ - fileName: '接口要换掉', //lres.data.FilePath + fileName, + localPathName: lres.data.FilePath, pictureBaseStr: baseHead + lres.data.Image }] } - postapi('/api/app/registercheckpicture/uploadregistercheckpicturemany', body).then(res => { + postapi('/api/app/RegisterCheckPicture/InstrumentMapping', body).then(res => { if (res.code > -1) { this.getCheckPictures(this.dataTransOpts.tableS.register_check.id) } @@ -377,7 +382,7 @@ export default { // immediate: true, handler(newVal, oldVal) { console.log(`watch 检查图片 newVal:${newVal} oldVal:${oldVal} registerCheckId: ${this.dataTransOpts.tableS.register_check.id}`); - if(newVal != oldVal) this.getCheckPictures(this.dataTransOpts.tableS.register_check.id); + if (newVal != oldVal) this.getCheckPictures(this.dataTransOpts.tableS.register_check.id); } },