|
|
|
@ -20,7 +20,7 @@ |
|
|
|
<el-button type="primary" class="commonbutton" @click="btnGetReport">领用报告</el-button> |
|
|
|
</div> |
|
|
|
<div class="listBtn"> |
|
|
|
<el-button type="primary" class="commonbutton" @click="btnUpReport">上传报告</el-button> |
|
|
|
<el-button type="primary" class="commonbutton" @click="btnUpReport">上传Web</el-button> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div> |
|
|
|
@ -135,22 +135,32 @@ export default { |
|
|
|
}; |
|
|
|
|
|
|
|
for (let i = 0; i < this.dataTransOpts.tableM.patient_register.length; i++) { |
|
|
|
|
|
|
|
let e = this.dataTransOpts.tableM.patient_register[i]; |
|
|
|
this.elProgress.percentage = Math.floor(((i + 1) * 100) / this.dataTransOpts.tableM.patient_register.length); |
|
|
|
if (e.completeFlag != '3') continue |
|
|
|
|
|
|
|
// 调上传接口 |
|
|
|
try { |
|
|
|
if (e.completeFlag == '3') { |
|
|
|
toOutShell.BusinessCode = e.patientRegisterId |
|
|
|
let jsonToOutShell = JSON.stringify(toOutShell) |
|
|
|
console.log('toOutShell', jsonToOutShell) |
|
|
|
let res = await this.$peisAPI.upLoadReportPdf(jsonToOutShell) |
|
|
|
if (JSON.parse(res).code < 0) { |
|
|
|
this.$message.warning({ showClose: true, message: JSON.parse(res).message }); |
|
|
|
console.log('$peisAPI.upLoadReportPdf err', res) |
|
|
|
} else { |
|
|
|
// 上传成功 ,更新上传传状态 |
|
|
|
e.isUpload = 'Y' |
|
|
|
console.log('btnUpReport success', JSON.parse(res)) |
|
|
|
} |
|
|
|
} else { |
|
|
|
patientRegisterId = e.patientRegisterId |
|
|
|
let res2 = await postapi('/api/app/TransToWebPeis/TransPatientRegisterByPatientRegisterId', { patientRegisterId }) |
|
|
|
if (res2.code == -1) { |
|
|
|
console.log('TransToWebPeis err', res2) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} catch (error) { |
|
|
|
console.log('error', error) |
|
|
|
this.$message.warning({ showClose: true, message: error }); |
|
|
|
|