|
|
|
@ -2,12 +2,12 @@ |
|
|
|
<div> |
|
|
|
<!--组件主体--> |
|
|
|
<div style="display: flex"> |
|
|
|
<div :style="'width:' + (window.pageWidth - 200 - 145) + 'px;'" @contextmenu.prevent="onContextmenu"> |
|
|
|
<div :style="'width:' + (window.pageWidth - 200 - 145) + 'px;'"> |
|
|
|
<div> |
|
|
|
<el-table @body-scrolling="load" :data="tableData" border highlight-current-row |
|
|
|
:height="window.pageHeight < 600 ? 238:Math.floor((window.pageHeight - 243)*2/3)" |
|
|
|
@row-click="rowClick" @row-dblclick="rowDblclick" size="small" row-key="id" |
|
|
|
@selection-change="handleSelectionChange" ref="info" id="info" :row-class-name="handleRowClassName"> |
|
|
|
:height="window.pageHeight < 600 ? 238 : Math.floor((window.pageHeight - 243) * 2 / 3)" @row-click="rowClick" |
|
|
|
size="small" row-key="id" @selection-change="handleSelectionChange" ref="info" id="info" |
|
|
|
:row-class-name="handleRowClassName"> |
|
|
|
<!-- 取消勾选,改为选中 |
|
|
|
<el-table-column type="selection" width="40" show-overflow-tooltip/> |
|
|
|
:height="window.pageHeight < 600 ? 202 : Math.floor(((window.pageHeight - 302) * 2) / 3)" |
|
|
|
@ -109,18 +109,12 @@ |
|
|
|
<el-tabs v-model="tabChoosed" style="margin-top: -22px;"> |
|
|
|
<!-- 给合项目 --> |
|
|
|
<el-tab-pane label="预览" name="1"> |
|
|
|
<div :style="`overflow: scroll; width: 100%;height: ${window.pageHeight < 600 ? 119:Math.floor((window.pageHeight - 243)/3)}px;`"> |
|
|
|
<el-image :src="lisLabel"> |
|
|
|
<div slot="placeholder" class="image-slot"> |
|
|
|
加载中<span class="dot">...</span> |
|
|
|
</div> |
|
|
|
</el-image> |
|
|
|
</div> |
|
|
|
|
|
|
|
<embed :src="lisLabel" type="application/pdf" width="100%" style="margin-top: -56px;" |
|
|
|
:height="(window.pageHeight < 600 ? 119 : Math.floor((window.pageHeight - 243) / 3)) + 56" /> |
|
|
|
</el-tab-pane> |
|
|
|
</el-tabs> |
|
|
|
</div> |
|
|
|
<div style="margin-left: 10px;"> |
|
|
|
<div style="margin-left: 5px;"> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs, '全选')" class="listBtn"> |
|
|
|
<el-button type="success" class="commonbutton" @click="btnChooseAll(1)">全选</el-button> |
|
|
|
</div> |
|
|
|
@ -261,7 +255,8 @@ export default { |
|
|
|
oneClick: 0, // 1 表示行单击一次 |
|
|
|
DbClick: 0, // 1 表示行有单击第二次 |
|
|
|
|
|
|
|
lisLabel: 'https://fuss10.elemecdn.com/1/8e/aeffeb4de74e2fde4bd74fc7b4486jpeg.jpeg', |
|
|
|
printPre: 0, |
|
|
|
lisLabel: '', // data:application/pdf;base64, |
|
|
|
}; |
|
|
|
}, |
|
|
|
|
|
|
|
@ -374,6 +369,7 @@ export default { |
|
|
|
|
|
|
|
//点击体检次数行 |
|
|
|
rowClick(row) { |
|
|
|
/* |
|
|
|
if (this.oneClick == 0) { |
|
|
|
this.oneClick = 1; |
|
|
|
} else { |
|
|
|
@ -389,7 +385,8 @@ export default { |
|
|
|
setTimeout(() => { //300ms内没有第二次点击,执行单击事件 |
|
|
|
if (this.oneClick == 1 && this.DbClick == 0) this.rowClickRetrieve(row) |
|
|
|
}, 300) |
|
|
|
|
|
|
|
*/ |
|
|
|
this.rowClickRetrieve(row) |
|
|
|
}, |
|
|
|
|
|
|
|
rowClickRetrieve(row) { |
|
|
|
@ -452,16 +449,11 @@ export default { |
|
|
|
// 弹出编辑框,只有在编辑框显示时,才去触发获取数据 |
|
|
|
this.dataTransOpts.tableS.patient_register.id = this.tableData[lfind].id |
|
|
|
this.tableDataCurrentRow = deepCopy(this.tableData[lfind]) |
|
|
|
this.dataTransOpts.refresh.register_check_asbitem.M++ //触发所选组合项目刷新 |
|
|
|
//触发条码预览 |
|
|
|
if (this.$peisAPI) this.lisPrint(this.dataTransOpts.tableS.patient_register.id, "0002", "Y", "Y") |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
// 双击 |
|
|
|
rowDblclick(row) { |
|
|
|
this.rowClick(row) |
|
|
|
this.btnEdit() |
|
|
|
}, |
|
|
|
|
|
|
|
//查询 |
|
|
|
async Query() { |
|
|
|
// 查询时,清掉明细数据 (滚动时不清) |
|
|
|
@ -674,7 +666,7 @@ export default { |
|
|
|
}, |
|
|
|
|
|
|
|
//检验条码打印 |
|
|
|
lisPrint(prId, ReportCode, isPreview) { |
|
|
|
lisPrint(prId, ReportCode, isPreview, IsUploadPdf) { |
|
|
|
if (!this.$peisAPI) { |
|
|
|
this.$message.info({ showClose: true, message: "此功能,需要在壳客户端才可运行!" }); |
|
|
|
return; |
|
|
|
@ -686,7 +678,7 @@ export default { |
|
|
|
ReportCode, |
|
|
|
token, |
|
|
|
isBuildImage: 'N', |
|
|
|
IsUploadPdf: 'N', |
|
|
|
IsUploadPdf, |
|
|
|
preViewCanPrint: "N", |
|
|
|
Parameters: [ |
|
|
|
{ Name: "printer", Value: user }, |
|
|
|
@ -696,28 +688,13 @@ export default { |
|
|
|
}; |
|
|
|
|
|
|
|
if (isPreview) { |
|
|
|
/* |
|
|
|
postapi( |
|
|
|
`/api/app/printreport/getlisrequestreport?PatientRegisterId=${prId}` |
|
|
|
) |
|
|
|
.then((res) => { |
|
|
|
if (res.code != -1) { |
|
|
|
toOutShell.ReportTable = { lisRequest: res.data }; |
|
|
|
console.log( |
|
|
|
"JSON.stringify(toOutShell)", |
|
|
|
JSON.stringify(toOutShell) |
|
|
|
); |
|
|
|
return this.$peisAPI.printPre(JSON.stringify(toOutShell)); |
|
|
|
} |
|
|
|
}) |
|
|
|
.catch((err) => { |
|
|
|
this.$message.warning(err); |
|
|
|
}); |
|
|
|
*/ |
|
|
|
this.$peisAPI.printPre(JSON.stringify(toOutShell)) |
|
|
|
.then(res => { |
|
|
|
if (JSON.parse(res).code < 0) { |
|
|
|
let lres = JSON.parse(res) |
|
|
|
if (lres.code < 0) { |
|
|
|
this.$message.warning({ showClose: true, message: JSON.parse(res).message }); |
|
|
|
}else if(IsUploadPdf == 'Y'){ |
|
|
|
this.lisLabel = 'data:application/pdf;base64,' + lres.data |
|
|
|
} |
|
|
|
}) |
|
|
|
.catch((err) => { |
|
|
|
@ -726,39 +703,7 @@ export default { |
|
|
|
}); |
|
|
|
|
|
|
|
} else { |
|
|
|
/* |
|
|
|
postapi( |
|
|
|
`/api/app/printreport/getlisrequestreport?PatientRegisterId=${prId}` |
|
|
|
) |
|
|
|
.then((res) => { |
|
|
|
if (res.code != -1) { |
|
|
|
toOutShell.ReportTable = { lisRequest: res.data }; |
|
|
|
console.log( |
|
|
|
"JSON.stringify(toOutShell)", |
|
|
|
JSON.stringify(toOutShell) |
|
|
|
); |
|
|
|
return this.$peisAPI.print(JSON.stringify(toOutShell)); |
|
|
|
} |
|
|
|
}) |
|
|
|
.then((res) => { |
|
|
|
//console.log("res", res); |
|
|
|
if (JSON.parse(res).code >= 0) { |
|
|
|
//更新打印状态 /api/app/lisrequest/updatelisrequestisprint |
|
|
|
// { |
|
|
|
// "operateType": 0, 操作类型(1.按PatientRegisterId 2.按LisRequestId) |
|
|
|
// "patientRegisterId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", |
|
|
|
// "lisRequestId": "3fa85f64-5717-4562-b3fc-2c963f66afa6" |
|
|
|
// } |
|
|
|
return postapi("/api/app/lisrequest/updatelisrequestisprint", { |
|
|
|
operateType: 1, |
|
|
|
patientRegisterId: prId, |
|
|
|
}); |
|
|
|
} |
|
|
|
}) |
|
|
|
.catch((err) => { |
|
|
|
this.$message.warning(err); |
|
|
|
}); |
|
|
|
*/ |
|
|
|
|
|
|
|
this.$peisAPI.print(JSON.stringify(toOutShell)) |
|
|
|
.then(res => { |
|
|
|
if (JSON.parse(res).code < 0) { |
|
|
|
@ -804,24 +749,6 @@ export default { |
|
|
|
}; |
|
|
|
|
|
|
|
if (isPreview) { |
|
|
|
/* |
|
|
|
postapi( |
|
|
|
`/api/app/printreport/getpacsnoreport?PatientRegisterId=${prId}` |
|
|
|
) |
|
|
|
.then((res) => { |
|
|
|
if (res.code != -1) { |
|
|
|
toOutShell.ReportTable = { lisRequest: res.data }; |
|
|
|
console.log( |
|
|
|
"JSON.stringify(toOutShell)", |
|
|
|
JSON.stringify(toOutShell) |
|
|
|
); |
|
|
|
return this.$peisAPI.printPre(JSON.stringify(toOutShell)); |
|
|
|
} |
|
|
|
}) |
|
|
|
.catch((err) => { |
|
|
|
this.$message.warning(err); |
|
|
|
}); |
|
|
|
*/ |
|
|
|
this.$peisAPI.printPre(JSON.stringify(toOutShell)) |
|
|
|
.then(res => { |
|
|
|
if (JSON.parse(res).code < 0) { |
|
|
|
@ -833,38 +760,6 @@ export default { |
|
|
|
this.$message.warning({ showClose: true, message: `${err}` }); |
|
|
|
}); |
|
|
|
} else { |
|
|
|
/* |
|
|
|
postapi( |
|
|
|
`/api/app/printreport/getpacsnoreport?PatientRegisterId=${prId}` |
|
|
|
) |
|
|
|
.then((res) => { |
|
|
|
if (res.code != -1) { |
|
|
|
toOutShell.ReportTable = { lisRequest: res.data }; |
|
|
|
console.log( |
|
|
|
"JSON.stringify(toOutShell)", |
|
|
|
JSON.stringify(toOutShell) |
|
|
|
); |
|
|
|
return this.$peisAPI.print(JSON.stringify(toOutShell)); |
|
|
|
} |
|
|
|
}) |
|
|
|
.then((res) => { |
|
|
|
if (JSON.parse(res).code >= 0) { |
|
|
|
//更新打印状态 /api/app/lisrequest/updatelisrequestisprint |
|
|
|
// { |
|
|
|
// "operateType": 0, 操作类型(1.按PatientRegisterId 2.按LisRequestId) |
|
|
|
// "patientRegisterId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", |
|
|
|
// "lisRequestId": "3fa85f64-5717-4562-b3fc-2c963f66afa6" |
|
|
|
// } |
|
|
|
return postapi("/api/app/lisrequest/updatelisrequestisprint", { |
|
|
|
operateType: 1, |
|
|
|
patientRegisterId: prId, |
|
|
|
}); |
|
|
|
} |
|
|
|
}) |
|
|
|
.catch((err) => { |
|
|
|
this.$message.warning(err); |
|
|
|
}); |
|
|
|
*/ |
|
|
|
this.$peisAPI.print(JSON.stringify(toOutShell)) |
|
|
|
.then(res => { |
|
|
|
if (JSON.parse(res).code < 0) { |
|
|
|
|