|
|
|
@ -17,6 +17,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
|
import org.springframework.web.bind.annotation.RequestMethod;
|
|
|
|
|
import org.springframework.web.bind.annotation.ResponseBody;
|
|
|
|
|
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
|
|
import javax.servlet.http.HttpSession;
|
|
|
|
|
import java.text.ParseException;
|
|
|
|
@ -52,7 +53,9 @@ public class FontController {
|
|
|
|
|
* 提供第三方按多个分段id和记账号查询病历pdf
|
|
|
|
|
* */
|
|
|
|
|
@RequestMapping("showRecordByPatientId")
|
|
|
|
|
public String showRecordByPatientId(String assortIds, String patientId,String visitId, Model model){
|
|
|
|
|
public String showRecordByPatientId( HttpServletResponse response, String assortIds, String patientId, String visitId, Model model){
|
|
|
|
|
response.setCharacterEncoding("utf-8");
|
|
|
|
|
System.out.println(System.getProperty("file.encoding"));//当前文件的编码方式
|
|
|
|
|
if(StringUtils.isBlank(assortIds)){
|
|
|
|
|
return retrunErrorPage(model,"病案分类Id不能为空!");
|
|
|
|
|
}
|
|
|
|
@ -95,6 +98,7 @@ public class FontController {
|
|
|
|
|
* 返回错误页面
|
|
|
|
|
* */
|
|
|
|
|
private String retrunErrorPage(Model model, String errorMsg){
|
|
|
|
|
System.out.println(System.getProperty("file.encoding"));//当前文件的编码方式
|
|
|
|
|
model.addAttribute("errorMsg",errorMsg);
|
|
|
|
|
return "font/error";
|
|
|
|
|
}
|
|
|
|
@ -103,6 +107,7 @@ public class FontController {
|
|
|
|
|
* 判断分类id是否存在
|
|
|
|
|
* */
|
|
|
|
|
private String checkAssortIds(String assortIds){
|
|
|
|
|
System.out.println(System.getProperty("file.encoding"));//当前文件的编码方式
|
|
|
|
|
Zd_Assort assort = new Zd_Assort();
|
|
|
|
|
assort.setPrintFlag("0");
|
|
|
|
|
List<Zd_Assort> assortList = null;
|
|
|
|
@ -187,7 +192,9 @@ public class FontController {
|
|
|
|
|
*/
|
|
|
|
|
@ResponseBody
|
|
|
|
|
@RequestMapping(value = "/getRecordTypeTree")
|
|
|
|
|
public String getRecordTypeTree(String patientId,String assortIds){
|
|
|
|
|
public String getRecordTypeTree(HttpServletResponse response,String patientId,String assortIds){
|
|
|
|
|
response.setCharacterEncoding("utf-8");
|
|
|
|
|
System.out.println(System.getProperty("file.encoding"));//当前文件的编码方式
|
|
|
|
|
List<AssortTypeTree> treeList = new ArrayList<>();
|
|
|
|
|
if(StringUtils.isNotBlank(patientId) && StringUtils.isNotBlank(assortIds)){
|
|
|
|
|
List<Archive_Detail> list = new ArrayList<>();
|
|
|
|
@ -328,6 +335,7 @@ public class FontController {
|
|
|
|
|
@ResponseBody
|
|
|
|
|
@RequestMapping(value = "/getPdfToPdf",method = RequestMethod.POST)
|
|
|
|
|
public Msg getPdfToPdf(HttpServletResponse response, String detailIds, HttpSession session){
|
|
|
|
|
response.setCharacterEncoding("utf-8");
|
|
|
|
|
try {
|
|
|
|
|
Archive_Detail detail = new Archive_Detail();
|
|
|
|
|
if(StringUtils.isNotBlank(detailIds)){
|
|
|
|
@ -348,6 +356,7 @@ public class FontController {
|
|
|
|
|
@ResponseBody
|
|
|
|
|
@RequestMapping(value = "showPdf")
|
|
|
|
|
public void showPdf(HttpServletResponse response, HttpSession session){
|
|
|
|
|
response.setCharacterEncoding("utf-8");
|
|
|
|
|
try {
|
|
|
|
|
archiveDetailService.showPdf(response,session,pdfWater);
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|