|
@ -4,8 +4,7 @@ import com.yihu.jw.entity.base.patient.BasePatientDO;
|
|
|
import com.yihu.jw.entity.base.security.Token;
|
|
|
import com.yihu.jw.entity.base.sms.SmsDO;
|
|
|
import com.yihu.jw.entity.base.sms.SmsTemplateDO;
|
|
|
import com.yihu.jw.patient.service.personal_Info.PatientService;
|
|
|
import com.yihu.jw.patient.dao.personal_info.PatientDao;
|
|
|
import com.yihu.jw.patient.dao.BasePatientDao;
|
|
|
import com.yihu.jw.patient.service.personal_Info.PatientService;
|
|
|
import com.yihu.jw.patient.util.CommonUtils;
|
|
|
import com.yihu.jw.patient.util.ConstantUtils;
|
|
@ -25,6 +24,7 @@ import com.yihu.jw.util.security.MD5;
|
|
|
import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
import io.swagger.annotations.ApiParam;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
|
import org.springframework.util.CollectionUtils;
|
|
@ -58,14 +58,14 @@ public class PatientEndpoint extends EnvelopRestEndpoint {
|
|
|
private BaseSmsGatewayService baseSmsGatewayService;
|
|
|
|
|
|
@Autowired
|
|
|
private PatientDao patientDao;
|
|
|
@Autowired
|
|
|
private PatientService patientService;
|
|
|
private BasePatientDao basePatientDao;
|
|
|
|
|
|
@Autowired
|
|
|
private RSAService rsaService;
|
|
|
|
|
|
@Autowired
|
|
|
private TokenService tokenService;
|
|
|
|
|
|
@Autowired
|
|
|
private BaseSmsService baseSmsService;
|
|
|
|
|
@ -104,7 +104,7 @@ public class PatientEndpoint extends EnvelopRestEndpoint {
|
|
|
}
|
|
|
|
|
|
//验证手机是否被注册
|
|
|
List<BasePatientDO> list = patientDao.findByMobileAndDel(mobile,"1");
|
|
|
List<BasePatientDO> list = basePatientDao.findByMobileAndDel(mobile,"1");
|
|
|
if(list!=null && list.size()> 0){
|
|
|
envelop.setMessage("该手机号已经注册!");
|
|
|
envelop.setStatus(-1);
|
|
@ -178,7 +178,7 @@ public class PatientEndpoint extends EnvelopRestEndpoint {
|
|
|
}
|
|
|
|
|
|
//验证手机是否被注册
|
|
|
List<BasePatientDO> list = patientDao.findByMobileAndDel(mobile,"1");
|
|
|
List<BasePatientDO> list = basePatientDao.findByMobileAndDel(mobile,"1");
|
|
|
if(CollectionUtils.isEmpty(list)){
|
|
|
envelop.setMessage("该手机未注册");
|
|
|
envelop.setStatus(-1);
|
|
@ -330,8 +330,9 @@ public class PatientEndpoint extends EnvelopRestEndpoint {
|
|
|
|
|
|
@GetMapping(value = BaseRequestMapping.BasePatient.idcardOccupied)
|
|
|
@ApiOperation(value = "判断身份证是否被占用,false-未占用,true-已占用")
|
|
|
public Envelop idcardOccupied(@ApiParam(name = "idcard", value = "居民身份证号", required = true) @RequestParam String idcard) throws Exception {
|
|
|
return success(patientService.existsByIdcard(idcard));
|
|
|
public Envelop idcardOccupied(@ApiParam(name = "id", value = "居民标识", required = true) @RequestParam String id,
|
|
|
@ApiParam(name = "idcard", value = "居民身份证号", required = true) @RequestParam String idcard) throws Exception {
|
|
|
return success(patientService.existsByIdcard(idcard,id));
|
|
|
}
|
|
|
|
|
|
@PostMapping(value = BaseRequestMapping.BasePatient.completeInfo)
|