liusheng
9 天以前 c111e3eff1191b29d2d2baf2f485a4bf3a2edc00
ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/PatArchiveController.java
@@ -1,6 +1,7 @@
package com.ruoyi.web.controller.smartor;
import com.github.pagehelper.ISelect;
import com.github.pagehelper.PageInfo;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
@@ -48,7 +49,7 @@
    //@PreAuthorize("@ss.hasPermi('smartor:patarchive:list')")
    @PostMapping("/list")
    public TableDataInfo list(@RequestBody PatArchive patArchive) {
        startPage();
        PageUtils.startPageByPost(patArchive.getPageNum(), patArchive.getPageSize());
        List<PatArchive> list = patArchiveService.selectPatArchiveList(patArchive);
        return getDataTable(list);
    }
@@ -59,7 +60,18 @@
    @ApiOperation("获取患者信息")
    @PostMapping("/getPatientInfoQC")
    public TableDataInfo getPatientInfoQC(@RequestBody PatArchiveReq patArchiveReq) {
        PageUtils.startPageByPost(patArchiveReq.getPageNum(), patArchiveReq.getPageSize());
        if (patArchiveReq.getAllhosp() != 2)
            PageUtils.startPageByPost(patArchiveReq.getPageNum(), patArchiveReq.getPageSize());
        else {
            //因为门诊数据量大,不能再用框架的分面,只能自己再造分页字段,进行分页查询数据(如果用自带的pageSize,框架会在SQL后面再加一个Limit,导致自己定义的Limit不能用了)
            PageUtils.clearPage();
            patArchiveReq.setPageSizeMZ(patArchiveReq.getPageSize());
            patArchiveReq.setPageNumMZ(patArchiveReq.getPageNum());
            patArchiveReq.setPageNum(null);
            patArchiveReq.setPageSize(null);
        }
        if (CollectionUtils.isEmpty(patArchiveReq.getLeavehospitaldistrictcodes()) || patArchiveReq.getLeavehospitaldistrictcodes().size() == 0) {
            patArchiveReq.setLeavehospitaldistrictcodes(null);
        }
@@ -67,6 +79,14 @@
            patArchiveReq.setLeaveldeptcodes(null);
        }
        List<PatArchiveOthreInfo> patientInfo = patArchiveService.getPatientInfoQC(patArchiveReq);
        if (patArchiveReq.getAllhosp() == 2) {
            //因为门诊的数据量大,没法再用框架的分页,只能自己查询
            Long count = patArchiveService.selectPatArchiveInfoByOuthospQCCount(patArchiveReq);
            return getDataTable2(count, patientInfo);
        }
        long count = PageUtils.count(new ISelect() {
            @Override
            public void doSelect() {