eight
2025-04-15 01a81beea99c0298a3b6178c7796f4c27b30c6c7
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/doctor/DoctorController.java
@@ -135,7 +135,7 @@
    {
        queueService.finishNextPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getToBeCheckedPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getCheckRelatedPatient(roomId, bedNo);
        // 过滤出  就诊中的,准备叫号
        QueueDO onStageItem = queueDOList.stream().filter(item ->
@@ -161,7 +161,7 @@
    {
        queueService.finishReceiveNextPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getToBeCheckedPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getCheckRelatedPatient(roomId, bedNo);
        // 过滤出  就诊中的,准备叫号
        QueueDO onStageItem = queueDOList.stream().filter(item ->
@@ -187,7 +187,7 @@
    {
        queueService.finishInstallNextPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getToBeInstalledPatient(roomId, bedNo); // 待安装的患者
        List<QueueDO> queueDOList = queueService.getInstallRelatedPatient(roomId, bedNo); // 待安装的患者
        List<QueueDO> installingQueueDOList = queueDOList.stream().filter(queueDO ->
                queueDO.getStatus() == QueueStatusEnum.INSTALLING.getStatus() && queueDO.getAffinityItem() == 0
@@ -205,6 +205,20 @@
    }
    // 常规检查过号、领用过号
    @GetMapping("/pass-waiting-patient")
    @Operation(summary = "过号排队中患者")
    @Parameter(name = "patId", description = "患者编号", required = true, example = "20247845")
    @Parameter(name = "checkType", description = "预约检查类型", required = true, example = "100")
    @PreAuthorize("@ss.hasPermission('ecg:doctor:task')")
    public CommonResult<Integer> passWaitingPatient(
            @RequestParam("patId") String patId,
            @RequestParam("checkType") Integer checkType)
    {
        queueService.passWaitingPatient( patId, checkType );
        return success(0);
    }
    // 常规检查过号、领用过号
    @GetMapping("/pass-next-patient")
    @Operation(summary = "过号、下一位患者")
    @Parameter(name = "roomId", description = "诊室编号", required = true, example = "116")
@@ -216,7 +230,7 @@
    {
        queueService.passNextPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getToBeCheckedPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getCheckRelatedPatient(roomId, bedNo);
        // 过滤出  就诊中的,准备叫号
        QueueDO onStageItem = queueDOList.stream().filter(item -> Objects.equals(item.getStatus(), QueueStatusEnum.ONSTAGE.getStatus())).findFirst().orElse(null);
@@ -240,7 +254,7 @@
    {
        queueService.passInstallNextPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getToBeInstalledPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getInstallRelatedPatient(roomId, bedNo);
        List<QueueDO> installingQueueDOList = queueDOList.stream().filter(queueDO -> queueDO.getStatus() == QueueStatusEnum.INSTALLING.getStatus()).toList();
        // 过滤出  [安装中] 的,准备叫号   该工位应该 最多只有一个 [安装中]
@@ -324,7 +338,7 @@
            @RequestParam("roomId") Long roomId,
            @RequestParam("bedNo") String bedNo)
    {
        List<QueueDO> queueDOList = queueService.getToBeCheckedPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getCheckRelatedPatient(roomId, bedNo);
        return success(BeanUtils.toBean(queueDOList, QueueRespVO.class));
    }
@@ -337,7 +351,7 @@
            @RequestParam("roomId") Long roomId,
            @RequestParam("bedNo") String bedNo)
    {
        List<QueueDO> queueDOList = queueService.getToBeInstalledPatient(roomId, bedNo);
        List<QueueDO> queueDOList = queueService.getInstallRelatedPatient(roomId, bedNo);
        return success(BeanUtils.toBean(queueDOList, QueueRespVO.class));
    }
@@ -381,6 +395,22 @@
        return success(patientStatisticVO);
    }
    @GetMapping("/recall-pass-waiting-patient")
    @Operation(summary = "过号-排队中 患者召回")
    @Parameter(name = "patId", description = "患者编号", required = true, example = "B2")
    @Parameter(name = "checkType", description = "预约检查类型", required = true, example = "100")
    @PreAuthorize("@ss.hasPermission('ecg:doctor:task')")
    public CommonResult<String> recallPatient(
            @RequestParam("patId") String patId,
            @RequestParam("checkType") Integer checkType)
    {
        Integer result = queueService.recallPassWaitingPatient(patId, checkType);
        if (null == result || 0 == result)
            return error(PATIENT_NOT_EXISTS);
        return success("操作成功");
    }
    @GetMapping("/recall-patient")
    @Operation(summary = "过号病人召回")
    @Parameter(name = "roomId", description = "诊室编号", required = true, example = "116")