lyh
2025-01-17 ea704e018a27c26ef6deeaea4adc8a28b4d0b27e
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
package org.jeecg.modules.dnc.mapper;
 
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.dnc.entity.DeviceGroup;
import org.jeecg.modules.dnc.dto.DeviceGroupExt;
import org.apache.ibatis.annotations.Param;
 
import java.util.List;
 
public interface DeviceGroupMapper extends BaseMapper<DeviceGroup> {
    /**
     * 获取所有分组信息 父子关系
     * @return
     */
    List<DeviceGroupExt> findExtAll();
 
    /**
     * 获取所有分组信息 父子关系
     * @return
     */
    List<DeviceGroupExt> findExtByDeparts(@Param("departIds") List<String> departIds);
 
    /**
     * 根据父节点获取子节点下的数据
     * @param parentId
     * @return
     */
    List<DeviceGroupExt> findByParentId(@Param("parentId") String parentId);
 
    /**
     * 获取用户授权关联的设备分组
     * @param userId
     * @return
     */
    List<DeviceGroupExt> getByUserPerms(@Param("userId") String userId);
 
    /**
     * 获取用户授权关联的设备分组 向上查询父
     * @param userId
     * @return
     */
    List<DeviceGroupExt> getByUserPermsAs(@Param("userId") String userId);
}