RemoteDeptService.java 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. package com.boman.system.api;
  2. import com.boman.common.core.constant.ServiceNameConstants;
  3. import com.boman.system.api.domain.SysDept;
  4. import org.springframework.cloud.openfeign.FeignClient;
  5. import org.springframework.web.bind.annotation.GetMapping;
  6. import org.springframework.web.bind.annotation.PathVariable;
  7. import java.util.List;
  8. /**
  9. * @author shiqian
  10. * @date 2021年04月07日 10:31
  11. **/
  12. @FeignClient(contextId = "remoteDeptService", value = ServiceNameConstants.SYSTEM_SERVICE)
  13. public interface RemoteDeptService {
  14. /**
  15. * 功能描述: 根据id查找
  16. *
  17. * @param id deptId
  18. * @return com.boman.common.core.web.domain.AjaxResult
  19. */
  20. @GetMapping(value = "/dept/getById/{id}")
  21. SysDept getById(@PathVariable("id") Long id);
  22. /**
  23. * 功能描述: 拿到部门下所有的部门, 包含传过来的deptId
  24. *
  25. * @param deptId deptId
  26. * @return com.boman.common.core.web.domain.AjaxResult
  27. */
  28. @GetMapping("/dept/list/children/depts/{deptId}")
  29. List<SysDept> listChildrenDepts(@PathVariable(value = "deptId") Long deptId);
  30. }