|
@@ -1,6 +1,8 @@
|
|
package thyyxxk.webserver.service.zhuyuanyisheng;
|
|
package thyyxxk.webserver.service.zhuyuanyisheng;
|
|
|
|
|
|
|
|
+import ch.qos.logback.core.db.dialect.DBUtil;
|
|
import cn.hutool.core.util.StrUtil;
|
|
import cn.hutool.core.util.StrUtil;
|
|
|
|
+import cn.hutool.db.DbUtil;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
import com.baomidou.dynamic.datasource.annotation.DS;
|
|
import com.baomidou.dynamic.datasource.annotation.DS;
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
@@ -249,18 +251,12 @@ public class YiZhuLuRuServer {
|
|
String userCode = TokenUtil.getInstance().getTokenUserId();
|
|
String userCode = TokenUtil.getInstance().getTokenUserId();
|
|
XinZhenYiZhu patInfo = dao.queryPatientInfo(param.getInpatientNo(), param.getAdmissTimes());
|
|
XinZhenYiZhu patInfo = dao.queryPatientInfo(param.getInpatientNo(), param.getAdmissTimes());
|
|
|
|
|
|
- // 是否可以确认
|
|
|
|
- List<BigDecimal> confirmOrderInformation = new ArrayList<>();
|
|
|
|
-
|
|
|
|
List<XinZhenYzActOrder> confirmYzList = new ArrayList<>();
|
|
List<XinZhenYzActOrder> confirmYzList = new ArrayList<>();
|
|
|
|
|
|
YiZhuCheckData checkData = new YiZhuCheckData(dao);
|
|
YiZhuCheckData checkData = new YiZhuCheckData(dao);
|
|
checkData.init(yiZhuList, patInfo).judgeExclusion();
|
|
checkData.init(yiZhuList, patInfo).judgeExclusion();
|
|
|
|
|
|
- Map<String, Object> checkMap = checkData.startCheck((item) -> {
|
|
|
|
- confirmYzList.add(item);
|
|
|
|
- confirmOrderInformation.add(item.getActOrderNo());
|
|
|
|
- });
|
|
|
|
|
|
+ Map<String, Object> checkMap = checkData.startCheck(confirmYzList::add);
|
|
|
|
|
|
if (checkData.multipleExclusions()) {
|
|
if (checkData.multipleExclusions()) {
|
|
return ResultVoUtil.fail(ExceptionEnum.LOGICAL_ERROR, "一次性不能确认多条全排斥医嘱。");
|
|
return ResultVoUtil.fail(ExceptionEnum.LOGICAL_ERROR, "一次性不能确认多条全排斥医嘱。");
|
|
@@ -565,9 +561,12 @@ public class YiZhuLuRuServer {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ try {
|
|
|
|
+ sqlSession.commit();
|
|
|
|
+ } finally {
|
|
|
|
+ DbUtil.close(sqlSession);
|
|
|
|
+ }
|
|
|
|
|
|
- sqlSession.commit();
|
|
|
|
- sqlSession.close();
|
|
|
|
}
|
|
}
|
|
|
|
|
|
private void setTempInfo(CacheOnce<XinZhenYzActOrder> drug, XinZhenYzActOrder data, XinZhenYiZhu patInfo) {
|
|
private void setTempInfo(CacheOnce<XinZhenYzActOrder> drug, XinZhenYzActOrder data, XinZhenYiZhu patInfo) {
|