|
@@ -1,14 +1,14 @@
|
|
|
package com.diagbot.facade;
|
|
|
|
|
|
-import org.springframework.stereotype.Component;
|
|
|
-
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
import com.diagbot.dto.HospitalInfoDTO;
|
|
|
import com.diagbot.entity.HospitalInfo;
|
|
|
import com.diagbot.enums.IsDeleteEnum;
|
|
|
import com.diagbot.service.impl.HospitalInfoServiceImpl;
|
|
|
import com.diagbot.util.BeanUtil;
|
|
|
+import com.diagbot.vo.HospitalCheckVO;
|
|
|
import com.diagbot.vo.HospitalInfoVO;
|
|
|
+import org.springframework.stereotype.Component;
|
|
|
|
|
|
/**
|
|
|
* @Description:
|
|
@@ -20,7 +20,7 @@ public class HospitalInfoFacade extends HospitalInfoServiceImpl {
|
|
|
|
|
|
private static final Object HospitalInfoDTO = null;
|
|
|
|
|
|
- /**
|
|
|
+ /**
|
|
|
* 获取医院信息
|
|
|
*
|
|
|
* @param hospitalInfoVO
|
|
@@ -31,13 +31,23 @@ public class HospitalInfoFacade extends HospitalInfoServiceImpl {
|
|
|
return hospitalInfoDTOList;
|
|
|
}
|
|
|
*/
|
|
|
- public HospitalInfoDTO getHospitalInfo(HospitalInfoVO hospitalInfoVO) {
|
|
|
- QueryWrapper<HospitalInfo> queryWrapper = new QueryWrapper<HospitalInfo>();
|
|
|
+ public HospitalInfoDTO getHospitalInfo(HospitalInfoVO hospitalInfoVO) {
|
|
|
+ QueryWrapper<HospitalInfo> queryWrapper = new QueryWrapper<HospitalInfo>();
|
|
|
queryWrapper.eq("is_deleted", IsDeleteEnum.N.getKey())
|
|
|
- .eq("code", hospitalInfoVO.getCode());
|
|
|
+ .eq("code", hospitalInfoVO.getCode());
|
|
|
HospitalInfo datas = this.getOne(queryWrapper, false);
|
|
|
- HospitalInfoDTO data =new HospitalInfoDTO();
|
|
|
+ HospitalInfoDTO data = new HospitalInfoDTO();
|
|
|
BeanUtil.copyProperties(datas, data);
|
|
|
return data;
|
|
|
}
|
|
|
+
|
|
|
+ public Boolean checkHospital(HospitalCheckVO hospitalCheckVO) {
|
|
|
+ QueryWrapper<HospitalInfo> queryWrapper = new QueryWrapper<HospitalInfo>();
|
|
|
+ queryWrapper.eq("is_deleted", IsDeleteEnum.N.getKey())
|
|
|
+ .eq("code", hospitalCheckVO.getHospitalCode());
|
|
|
+ if (this.count(queryWrapper) > 0) {
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ return false;
|
|
|
+ }
|
|
|
}
|