Browse Source

获取心理咨询师详情接口修改

feature/yujt_analysisHomeChange
yujt 5 years ago
parent
commit
ccfc01ece4
  1. 10
      epdc-cloud-api/src/main/java/com/elink/esua/epdc/controller/ApiPropertyController.java
  2. 8
      epdc-cloud-api/src/main/java/com/elink/esua/epdc/feign/PropertyFeignClient.java
  3. 5
      epdc-cloud-api/src/main/java/com/elink/esua/epdc/feign/fallback/PropertyFeignClientFallback.java
  4. 9
      epdc-cloud-api/src/main/java/com/elink/esua/epdc/service/PropertyService.java
  5. 7
      epdc-cloud-api/src/main/java/com/elink/esua/epdc/service/impl/PropertyServiceImpl.java

10
epdc-cloud-api/src/main/java/com/elink/esua/epdc/controller/ApiPropertyController.java

@ -22,7 +22,6 @@ import com.elink.esua.epdc.dto.police.result.PoliceResultDTO;
import com.elink.esua.epdc.dto.project.form.ProjectListFormDTO;
import com.elink.esua.epdc.dto.project.form.ProjectScoreFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistInfoFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyAnswerFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyQuestionFormDTO;
import com.elink.esua.epdc.dto.psychology.result.PsychologistInfoResultDTO;
@ -382,15 +381,14 @@ public class ApiPropertyController {
/**
* 心理咨询师详细信息
*
* @param userDetail 用户信息
* @param formDto 查询参数
* @param psychologistId 咨询师id
* @return com.elink.esua.epdc.commons.tools.utils.Result<java.util.List < com.elink.esua.epdc.dto.epdc.result.PsychologistInfoResultDTO>>
* @author zhangyuan
* @date 2020/6/8 09:17
*/
@GetMapping("psychology/psychologistInfo")
public Result<PsychologistInfoResultDTO> psychologistInfo(@LoginUser TokenDto userDetail, PsychologistInfoFormDTO formDto) {
return propertyService.psychologistInfo(userDetail, formDto);
@GetMapping("psychology/psychologistInfo/{psychologistId}")
public Result<PsychologistInfoResultDTO> psychologistInfo(@PathVariable("psychologistId") String psychologistId) {
return propertyService.psychologistInfo(psychologistId);
}
/**

8
epdc-cloud-api/src/main/java/com/elink/esua/epdc/feign/PropertyFeignClient.java

@ -19,7 +19,6 @@ import com.elink.esua.epdc.dto.project.form.ProjectScoreFormDTO;
import com.elink.esua.epdc.dto.project.result.ProjectDetailResultDTO;
import com.elink.esua.epdc.dto.project.result.ProjectListResultDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistInfoFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyAnswerFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyQuestionFormDTO;
import com.elink.esua.epdc.dto.psychology.result.PsychologistInfoResultDTO;
@ -36,6 +35,7 @@ import com.elink.esua.epdc.feign.fallback.PropertyFeignClientFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
@ -304,13 +304,13 @@ public interface PropertyFeignClient {
/***
* 心理咨询师详细信息
* @param fromDTO
* @param psychologistId
* @return com.elink.esua.epdc.commons.tools.utils.Result<java.util.List < com.elink.esua.epdc.dto.epdc.result.PsychologistInfoResultDTO>>
* @author zhangyuan
* @date 2020/6/8 9:25
*/
@GetMapping(value = "property/epdc-app/psychology/psychologistInfo", consumes = MediaType.APPLICATION_JSON_VALUE)
Result<PsychologistInfoResultDTO> psychologistInfo(@RequestBody PsychologistInfoFormDTO fromDTO);
@GetMapping(value = "property/epdc-app/psychology/psychologistInfo/{psychologistId}", consumes = MediaType.APPLICATION_JSON_VALUE)
Result<PsychologistInfoResultDTO> psychologistInfo(@PathVariable("psychologistId") String psychologistId);
/***
* 提交心理咨询问题

5
epdc-cloud-api/src/main/java/com/elink/esua/epdc/feign/fallback/PropertyFeignClientFallback.java

@ -20,7 +20,6 @@ import com.elink.esua.epdc.dto.project.form.ProjectScoreFormDTO;
import com.elink.esua.epdc.dto.project.result.ProjectDetailResultDTO;
import com.elink.esua.epdc.dto.project.result.ProjectListResultDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistInfoFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyAnswerFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyQuestionFormDTO;
import com.elink.esua.epdc.dto.psychology.result.PsychologistInfoResultDTO;
@ -175,8 +174,8 @@ public class PropertyFeignClientFallback implements PropertyFeignClient {
}
@Override
public Result<PsychologistInfoResultDTO> psychologistInfo(PsychologistInfoFormDTO formDto) {
return ModuleUtils.feignConError(ServiceConstant.EPDC_PROPERTY_SERVER, "psychologistInfo", formDto);
public Result<PsychologistInfoResultDTO> psychologistInfo(String psychologistId) {
return ModuleUtils.feignConError(ServiceConstant.EPDC_PROPERTY_SERVER, "psychologistInfo", psychologistId);
}
@Override

9
epdc-cloud-api/src/main/java/com/elink/esua/epdc/service/PropertyService.java

@ -23,7 +23,6 @@ import com.elink.esua.epdc.dto.project.form.ProjectScoreFormDTO;
import com.elink.esua.epdc.dto.project.result.ProjectDetailResultDTO;
import com.elink.esua.epdc.dto.project.result.ProjectListResultDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistInfoFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyAnswerFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyQuestionFormDTO;
import com.elink.esua.epdc.dto.psychology.result.PsychologistInfoResultDTO;
@ -35,6 +34,7 @@ import com.elink.esua.epdc.dto.topic.form.TopicListFormDTO;
import com.elink.esua.epdc.dto.topic.form.TopicSubmitFormDTO;
import com.elink.esua.epdc.dto.topic.result.TopicDetailResultDTO;
import com.elink.esua.epdc.dto.topic.result.TopicListResultDTO;
import org.springframework.web.bind.annotation.PathVariable;
import java.util.List;
@ -296,15 +296,14 @@ public interface PropertyService {
Result<List<PsychologistResultDTO>> listPsychiatrist(TokenDto userDetail, PsychologistFormDTO formDto);
/**
* 心理咨询师列表
* 心理咨询师详细信息
*
* @param userDetail 用户信息
* @param formDto 查询参数
* @param psychologistId 咨询师id
* @return com.elink.esua.epdc.commons.tools.utils.Result<java.util.List < com.elink.esua.epdc.dto.epdc.result.PsychologistInfoResultDTO>>
* @author zhangyuan
* @date 2020/6/8 09:15
*/
Result<PsychologistInfoResultDTO> psychologistInfo(TokenDto userDetail, PsychologistInfoFormDTO formDto);
Result<PsychologistInfoResultDTO> psychologistInfo(String psychologistId);
/**
* 提交心理咨询问题

7
epdc-cloud-api/src/main/java/com/elink/esua/epdc/service/impl/PropertyServiceImpl.java

@ -29,7 +29,6 @@ import com.elink.esua.epdc.dto.project.form.ProjectScoreFormDTO;
import com.elink.esua.epdc.dto.project.result.ProjectDetailResultDTO;
import com.elink.esua.epdc.dto.project.result.ProjectListResultDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologistInfoFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyAnswerFormDTO;
import com.elink.esua.epdc.dto.psychology.form.PsychologyQuestionFormDTO;
import com.elink.esua.epdc.dto.psychology.result.PsychologistInfoResultDTO;
@ -49,6 +48,7 @@ import com.elink.esua.epdc.service.PropertyService;
import com.elink.esua.epdc.utils.UserTagUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.PathVariable;
import java.util.List;
@ -344,9 +344,8 @@ public class PropertyServiceImpl implements PropertyService {
}
@Override
public Result<PsychologistInfoResultDTO> psychologistInfo(TokenDto userDetail, PsychologistInfoFormDTO formDto) {
formDto.setGridId(userDetail.getGridId());
return propertyFeignClient.psychologistInfo(formDto);
public Result<PsychologistInfoResultDTO> psychologistInfo(String psychologistId) {
return propertyFeignClient.psychologistInfo(psychologistId);
}
@Override

Loading…
Cancel
Save