|
|
|
|
@ -147,55 +147,6 @@ function onloadPdfMethod() {
|
|
|
|
|
|
|
|
|
|
//加载pdf按钮功能
|
|
|
|
|
function onloadPdf(scanPages, sources) {
|
|
|
|
|
/*var batchSize = 10; // 每批处理10个PDF文件
|
|
|
|
|
var scanPagesArray = scanPages.split(',');
|
|
|
|
|
var sourcesArray = sources.split(',');
|
|
|
|
|
var totalFiles = scanPagesArray.length;
|
|
|
|
|
var batches = Math.ceil(totalFiles / batchSize);
|
|
|
|
|
function processBatch(batchIndex){
|
|
|
|
|
var start = batchIndex * batchSize;
|
|
|
|
|
var end = Math.min(start + batchSize, totalFiles);
|
|
|
|
|
var batchScanPages = scanPagesArray.slice(start, end) + "";
|
|
|
|
|
var batchSources = sourcesArray.slice(start, end) + "";
|
|
|
|
|
|
|
|
|
|
$("#iframeLoad").val("");
|
|
|
|
|
$("#printPicLoaded").val("");
|
|
|
|
|
var patientId = $("#patientId").val();
|
|
|
|
|
//根目录字段识别名称
|
|
|
|
|
var flag = parent.$("#flag").val();
|
|
|
|
|
$.ajax({
|
|
|
|
|
type: 'post',
|
|
|
|
|
url: path + "/commom/showRecordContentBlood",
|
|
|
|
|
data: {
|
|
|
|
|
patientId: patientId,
|
|
|
|
|
scanPages: batchScanPages,
|
|
|
|
|
flag: flag,
|
|
|
|
|
sources: batchSources,
|
|
|
|
|
batchIndex: batchIndex
|
|
|
|
|
},
|
|
|
|
|
datType: 'json',
|
|
|
|
|
success: function (data) {
|
|
|
|
|
if (data.code == 0) {
|
|
|
|
|
var str = path + "/commom/getRecordContentBlood?patientId=" + patientId + "&batchIndex=" + batchIndex;
|
|
|
|
|
if (sources.includes("99") ||sources.includes("服务") ||sources.includes("null")||sources.includes("pacs")||sources.includes("扫描上传")) {
|
|
|
|
|
$("#iframe1").attr("src", path + "/static/pdfjs/web/viewer.html?file=" + encodeURIComponent(str))
|
|
|
|
|
} else {
|
|
|
|
|
$("#iframe1").attr("src", path + "/static/pdfjs/web/viewer2.html?file=" + encodeURIComponent(str))
|
|
|
|
|
var rootPaths = parent.$("#rootPaths").val();
|
|
|
|
|
var print = $("#print").val();
|
|
|
|
|
if (print == 1) {
|
|
|
|
|
selectPrintPic(patientId, rootPaths, scanPages, sources);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
// 处理每个批次
|
|
|
|
|
for (var i = 0; i < batches; i++) {
|
|
|
|
|
processBatch(i);
|
|
|
|
|
}*/
|
|
|
|
|
|
|
|
|
|
$("#iframeLoad").val("");
|
|
|
|
|
$("#printPicLoaded").val("");
|
|
|
|
|
var patientId = $("#patientId").val();
|
|
|
|
|
|