|
@ -27,6 +27,7 @@ import com.yihu.wlyy.service.BaseService;
|
|
|
import com.yihu.wlyy.util.DateUtil;
|
|
|
import com.yihu.wlyy.util.HttpClientUtil;
|
|
|
import com.yihu.wlyy.util.SystemConf;
|
|
|
import org.springframework.util.StringUtils;
|
|
|
|
|
|
import javax.print.Doc;
|
|
|
|
|
@ -120,10 +121,10 @@ public class SMSService extends BaseService {
|
|
|
if (type == 2 || type == 4 || type == 10) {//患者
|
|
|
List<Patient> patients = patientDao.findByMobile(mobile);
|
|
|
if (patients != null && patients.size() > 0) {
|
|
|
SignFamily sign= signFamilyDao.findByPatient(code);
|
|
|
SignFamily sign = signFamilyDao.findByPatient(code);
|
|
|
sms.setUserType(0);
|
|
|
sms.setUserCode(code);
|
|
|
if(sign!=null){
|
|
|
if (sign != null) {
|
|
|
sms.setHospital(sign.getHospital());
|
|
|
}
|
|
|
}
|
|
@ -141,11 +142,13 @@ public class SMSService extends BaseService {
|
|
|
sms.setUserCode(d.getCode());
|
|
|
sms.setHospital(d.getHospital());
|
|
|
} else {
|
|
|
SignFamily signFamily = signFamilyDao.findByMobile(mobile);
|
|
|
if (signFamily != null) {
|
|
|
sms.setUserType(0);
|
|
|
sms.setUserCode(signFamily.getPatient());
|
|
|
sms.setHospital(signFamily.getHospital());
|
|
|
if (!StringUtils.isEmpty(code)) {
|
|
|
SignFamily signFamily = signFamilyDao.findByPatient(code);
|
|
|
if (signFamily != null) {
|
|
|
sms.setUserType(0);
|
|
|
sms.setUserCode(signFamily.getPatient());
|
|
|
sms.setHospital(signFamily.getHospital());
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}
|