eight
2024-12-12 2bc90e242eceb83d9aa80d48ea9f991c0f9b99c6
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/api/doctor/DoctorApiImpl.java
@@ -7,6 +7,7 @@
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
@Service
public class DoctorApiImpl implements DoctorApi {
@@ -16,13 +17,14 @@
    @Override
    public ErrorCode bedDoctorOff(Long userId, String userName) {
        RoomDO roomDO = queueService.getDocRoomInfo(userId);
        List<RoomDO> roomDOList = queueService.getDocRoomInfo(userId);
        // 未入座, 跳过
        if (null == roomDO) {
        if (roomDOList.isEmpty()) {
            return GlobalErrorCodeConstants.SUCCESS;
        }
        return queueService.startBedDoctorOff(roomDO.getRoomId(), roomDO.getBedNo(), userId, userName);
        roomDOList.forEach( bedItem -> queueService.startBedDoctorOff(bedItem.getRoomId(), bedItem.getBedNo(), userId, userName));
        return GlobalErrorCodeConstants.SUCCESS;
    }
}