吉安感知网项目-后端
xiebin
2026-01-06 d207a86cdf1ab52ef8cb7cd83bad8fceab8038cf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
package org.sxkj.system.feign;
 
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import lombok.AllArgsConstructor;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tenant.annotation.NonDS;
import org.springblade.core.tool.utils.StringUtil;
import org.springframework.web.bind.annotation.RestController;
import org.sxkj.system.cache.SysCache;
import org.sxkj.system.entity.DevicePerShareEntity;
import org.sxkj.system.service.IDevicePerShareService;
import org.sxkj.system.vo.ShareParam;
import springfox.documentation.annotations.ApiIgnore;
 
import java.util.Collections;
import java.util.List;
 
/**
 * @Description 借调服务远程调度
 * @Author AIX
 * @Date 2025/9/18 17:04
 * @Version 1.0
 */
@NonDS
@ApiIgnore
@RestController
@AllArgsConstructor
public class ManageDevicePerShareClient implements IManageDevicePerShareClient {
 
    private final IDevicePerShareService devicePerShareService;
 
    @Override
    public List<DevicePerShareEntity> findActiveLoansByToDeptId(ShareParam param, Long deptId) {
        // 参数校验
        if (deptId == null) {
            return Collections.emptyList();
        }
 
        // 执行自定义SQL查询
        return devicePerShareService.findActiveLoansByToDeptId(param, SysCache.getDeptParentIds(deptId));
    }
 
    @Override
    public List<String> findActiveLoansAreaCodeByToDeptId(ShareParam param, Long deptId) {
        // 参数校验
        if (deptId == null) {
            return Collections.emptyList();
        }
 
        // 执行自定义SQL查询
        return devicePerShareService.findActiveLoansAreaCodeByToDeptId(param, SysCache.getDeptParentIds(deptId));
    }
}