修改BUG

This commit is contained in:
lxd 2025-03-17 10:17:38 +08:00
parent 914ca940b1
commit 2f588f74dc
2 changed files with 18 additions and 6 deletions

View File

@ -424,15 +424,24 @@ public class InspectPatientController {
switch (type) { switch (type) {
case "XCG": case "XCG":
model = "cbc"; model = "cbc";
barCode = patientDO.getXcgcode(); if(patientDO.getXcgcode()!=null)
{
barCode = patientDO.getXcgcode();
}
break; break;
case "NCG": case "NCG":
model = "rt"; model = "rt";
barCode = patientDO.getNcgcode(); if(patientDO.getNcgcode()!=null)
{
barCode = patientDO.getNcgcode();
}
break; break;
case "SHQX": case "SHQX":
model = "bt"; model = "bt";
barCode = patientDO.getShqx(); if(patientDO.getShqx()!=null)
{
barCode = patientDO.getShqx();
}
break; break;
} }
ConfigDO config = configService.getConfigByKey("url.reporttj"); ConfigDO config = configService.getConfigByKey("url.reporttj");
@ -455,7 +464,7 @@ public class InspectPatientController {
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
return success(false); return success(true);
} }
} }

View File

@ -163,7 +163,7 @@ public class InspectPatientServiceImpl implements InspectPatientService {
} }
//患者体检报告单相关 //患者体检报告单相关
private List<BufferedImage> createPDF_playwright(String htmlContent) { private List<BufferedImage> createPDF_playwright(String htmlContent) throws Exception {
List<BufferedImage> _out = new ArrayList<>(); List<BufferedImage> _out = new ArrayList<>();
try { try {
Playwright playwright = null; Playwright playwright = null;
@ -206,6 +206,7 @@ public class InspectPatientServiceImpl implements InspectPatientService {
} }
} catch (Exception e) { } catch (Exception e) {
_out = null; _out = null;
throw e;
} finally { } finally {
try { try {
if (document != null) document.close(); if (document != null) document.close();
@ -215,6 +216,7 @@ public class InspectPatientServiceImpl implements InspectPatientService {
} }
} catch (Exception ex) { } catch (Exception ex) {
_out = null; _out = null;
throw ex;
} finally { } finally {
try { try {
if (page != null && !page.isClosed()) page.close(); if (page != null && !page.isClosed()) page.close();
@ -231,6 +233,7 @@ public class InspectPatientServiceImpl implements InspectPatientService {
} }
} catch (Exception exOut) { } catch (Exception exOut) {
_out = null; _out = null;
throw exOut;
} finally { } finally {
System.gc(); System.gc();
} }
@ -588,7 +591,7 @@ public class InspectPatientServiceImpl implements InspectPatientService {
outRes.put("msg", "https://pacs.gw12320.com/video/" + fosPath_file); outRes.put("msg", "https://pacs.gw12320.com/video/" + fosPath_file);
} catch (Exception ex) { } catch (Exception ex) {
outRes.put("code", -200); outRes.put("code", -200);
outRes.put("msg", ""); outRes.put("msg", ex.getMessage());
} finally { } finally {
try { try {
if (officeManager != null && officeManager.isRunning()) { if (officeManager != null && officeManager.isRunning()) {