提交 d2841177 编写于 作者: rushui.chen's avatar rushui.chen

20200108 修改参数传递方式

上级 58445b96
流水线 #20352 已失败 于阶段
in 1 second
...@@ -11,7 +11,9 @@ import com.pica.cloud.account.account.server.service.DoctorService; ...@@ -11,7 +11,9 @@ import com.pica.cloud.account.account.server.service.DoctorService;
import com.pica.cloud.account.account.server.util.AESUtil; import com.pica.cloud.account.account.server.util.AESUtil;
import com.pica.cloud.account.account.server.util.AccountUtils; import com.pica.cloud.account.account.server.util.AccountUtils;
import com.pica.cloud.base.doctor.doctor.client.DoctorServiceClient; import com.pica.cloud.base.doctor.doctor.client.DoctorServiceClient;
import com.pica.cloud.base.doctor.doctor.common.dto.DoctorDeleteDto;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.codehaus.groovy.transform.tailrec.VariableAccessReplacer;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
...@@ -43,7 +45,7 @@ public class DoctorServiceImpl implements DoctorService { ...@@ -43,7 +45,7 @@ public class DoctorServiceImpl implements DoctorService {
@Transactional @Transactional
@Override @Override
public void modifyDoctorInfo(Doctor doctor,Long doctorId) { public void modifyDoctorInfo(Doctor doctor, Long doctorId) {
Integer id = doctor.getId(); Integer id = doctor.getId();
if (id == null) { if (id == null) {
throw new AccountException(AccountExceptionEnum.PICA_PARAMS_ERROR); throw new AccountException(AccountExceptionEnum.PICA_PARAMS_ERROR);
...@@ -70,19 +72,22 @@ public class DoctorServiceImpl implements DoctorService { ...@@ -70,19 +72,22 @@ public class DoctorServiceImpl implements DoctorService {
@Transactional @Transactional
@Override @Override
public void deleteDoctorInfo(Integer id,Long modifyId) { public void deleteDoctorInfo(Integer id, Long modifyId) {
//p_doctor表修改记录状态 //p_doctor表修改记录状态
Doctor doctor = doctorMapper.selectByPrimaryKey(id); Doctor doctor = doctorMapper.selectByPrimaryKey(id);
if (doctor != null) { if (doctor != null) {
Integer acctId = doctor.getAcctId(); Integer acctId = doctor.getAcctId();
HashMap<String, Long> map = new HashMap<>(); //HashMap<String, Long> map = new HashMap<>();
map.put("id",id.longValue()); //map.put("id", id.longValue());
map.put("modifyId",modifyId); //map.put("modifyId", modifyId);
doctorServiceClient.deleteDoctor(id.longValue(),modifyId); DoctorDeleteDto doctorDeleteDto = new DoctorDeleteDto();
doctorDeleteDto.setId(id.longValue());
doctorDeleteDto.setModifyId(modifyId);
doctorServiceClient.deleteDoctor(doctorDeleteDto);
//doctorMapper.updateDeleteByPrimaryKey(map); //doctorMapper.updateDeleteByPrimaryKey(map);
HashMap<String, Long> acctMap = new HashMap<>(); HashMap<String, Long> acctMap = new HashMap<>();
acctMap.put("modifyId",modifyId); acctMap.put("modifyId", modifyId);
acctMap.put("acctId",acctId.longValue()); acctMap.put("acctId", acctId.longValue());
accountInfoDetailMapper.updateDeleteByPrimaryKey(acctMap); accountInfoDetailMapper.updateDeleteByPrimaryKey(acctMap);
} else { } else {
throw new AccountException(AccountExceptionEnum.PICA_NOT_REGISTER); throw new AccountException(AccountExceptionEnum.PICA_NOT_REGISTER);
...@@ -100,7 +105,7 @@ public class DoctorServiceImpl implements DoctorService { ...@@ -100,7 +105,7 @@ public class DoctorServiceImpl implements DoctorService {
*/ */
@Override @Override
@Transactional @Transactional
public Integer addDoctorInfo(Doctor doctor,Long doctorId) { public Integer addDoctorInfo(Doctor doctor, Long doctorId) {
String mobilePhone = doctor.getMobilePhone(); String mobilePhone = doctor.getMobilePhone();
String mobileEncrypt = AESUtil.encryptV0(mobilePhone); String mobileEncrypt = AESUtil.encryptV0(mobilePhone);
AccountInfoEntity accountInfoEntity = accountInfoDetailMapper.selectByMobile(mobileEncrypt); AccountInfoEntity accountInfoEntity = accountInfoDetailMapper.selectByMobile(mobileEncrypt);
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册