123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190 |
- package com.diagbot.client;
- import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
- import com.diagbot.client.hystrix.CdssHystrix;
- import com.diagbot.dto.RespDTO;
- import com.diagbot.entity.MappingConfig;
- import com.diagbot.entity.wrapper.MappingConfigWrapper;
- import com.diagbot.vo.IdListVO;
- import com.diagbot.vo.IdVO;
- import com.diagbot.vo.MappingConfigPageVO;
- import com.diagbot.vo.MappingConfigVO;
- import org.springframework.cloud.openfeign.FeignClient;
- import org.springframework.http.MediaType;
- import org.springframework.transaction.annotation.Transactional;
- import org.springframework.web.bind.annotation.PostMapping;
- import org.springframework.web.bind.annotation.RequestBody;
- import org.springframework.web.bind.annotation.RequestParam;
- import org.springframework.web.bind.annotation.RequestPart;
- import org.springframework.web.multipart.MultipartFile;
- import javax.servlet.http.HttpServletResponse;
- import javax.validation.Valid;
- import java.util.List;
- /**
- * @Description:
- * @Author:zhaops
- * @time: 2021/6/21 15:33
- */
- @FeignClient(name = "cdss", url = "${cdss.url}", fallback = CdssHystrix.class)
- public interface CdssClient {
- /**
- * 数据导入模板导出
- *
- * @param mappingConfigVO
- */
- @PostMapping("/tran/mappingConfig/exportExcelModule")
- void exportExcelModule(@RequestBody @Valid MappingConfigVO mappingConfigVO);
- /**
- * 预匹配导入术语校验
- *
- * @param file
- * @param type
- */
- @PostMapping(value = "/tran/mappingConfig/dataVerify", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
- RespDTO<Boolean> dataVerify(@RequestPart("file") MultipartFile file,
- @RequestParam("type") Integer type);
- /**
- * 预匹配
- *
- * @param file
- * @param response
- * @param type
- */
- @PostMapping(value = "/tran/mappingConfig/precDataMatch", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
- void precDataMatch(@RequestParam("file") MultipartFile file,
- HttpServletResponse response,
- @RequestParam("type") Integer type);
- /**
- * 预匹配_远程调用
- *
- * @param file
- * @param type
- * @return
- */
- @PostMapping(value = "/tran/mappingConfig/precDataMatch_remote", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
- RespDTO<List<MappingConfigWrapper>> precDataMatch_remote(@RequestPart("file") MultipartFile file,
- @RequestParam("type") Integer type);
- /**
- * 数据导入校验
- *
- * @param file
- * @param hospitalId
- * @param type
- * @param userId
- */
- @PostMapping(value = "/tran/mappingConfig/importExcelDataVerify", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
- RespDTO<Boolean> importExcelDataVerify(@RequestPart("file") MultipartFile file,
- @RequestParam("hospitalId") Long hospitalId,
- @RequestParam("type") Integer type,
- @RequestParam("uesrId") String userId);
- /**
- * 数据导入
- *
- * @param file
- * @param hospitalId
- * @param type
- * @param userId
- */
- @PostMapping(value = "/tran/mappingConfig/importExcel", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
- RespDTO<Boolean> importExcel(@RequestPart("file") MultipartFile file,
- @RequestParam("hospitalId") Long hospitalId,
- @RequestParam("type") Integer type,
- @RequestParam("uesrId") String userId);
- /**
- * 数据导入
- *
- * @param file
- * @param hospitalId
- * @param type
- * @param userId
- */
- @PostMapping(value = "/tran/mappingConfig/importExcel_remote", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
- RespDTO<List<MappingConfigWrapper>> importExcel_remote(@RequestPart("file") MultipartFile file,
- @RequestParam("hospitalId") Long hospitalId,
- @RequestParam("type") Integer type,
- @RequestParam("uesrId") String userId);
- /**
- * 数据导出_远程调用
- *
- * @param mappingConfigPageVO
- * @return
- */
- @PostMapping("/tran/mappingConfig/exportExcel_remote")
- RespDTO<List<MappingConfigWrapper>> exportExcel_remote(@RequestBody @Valid MappingConfigPageVO mappingConfigPageVO);
- /**
- * 分页查询
- *
- * @param mappingConfigPageVO
- * @return
- */
- @PostMapping("/tran/mappingConfig/getPage")
- RespDTO<Page<MappingConfigWrapper>> getPage(@RequestBody @Valid MappingConfigPageVO mappingConfigPageVO);
- /**
- * 获取映射关系
- *
- * @param idVO
- * @return
- */
- @PostMapping("/tran/mappingConfig/getRecord")
- @Transactional
- RespDTO<MappingConfigWrapper> getRecord(@RequestBody @Valid IdVO idVO);
- /**
- * 映射关系是否已存在
- *
- * @param mappingConfig
- * @return
- */
- @PostMapping("/tran/mappingConfig/isExistRecord")
- RespDTO<Boolean> isExistRecord(@RequestBody @Valid MappingConfig mappingConfig);
- /**
- * 查询已映射关系
- *
- * @param mappingConfigVO
- * @return
- */
- @PostMapping("/tran/mappingConfig/getRelatedMapping")
- RespDTO<List<MappingConfigWrapper>> getRelatedMapping(@RequestBody @Valid MappingConfigVO mappingConfigVO);
- /**
- * 保存或修改映射关系
- *
- * @param mappingConfig
- * @return
- */
- @PostMapping("/tran/mappingConfig/saveOrUpdateRecord")
- RespDTO<Boolean> saveOrUpdateRecord(@RequestBody @Valid MappingConfig mappingConfig);
- /**
- * 删除映射关系
- *
- * @param idVO
- * @return
- */
- @PostMapping("/tran/mappingConfig/deleteRecord")
- RespDTO<Boolean> deleteRecord(@RequestBody @Valid IdVO idVO);
- /**
- * 批量删除映射关系
- *
- * @param idListVO
- * @return
- */
- @PostMapping("/tran/mappingConfig/deleteRecords")
- RespDTO<Boolean> deleteRecords(@RequestBody @Valid IdListVO idListVO);
- }
|