lyh
2025-06-16 24e0bdd24a10449c98013cdb5bcc5e37735f5a91
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
package org.jeecg.modules.dnc.service;
 
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.dnc.entity.DocInfo;
import org.jeecg.modules.dnc.entity.PartsInfo;
import org.jeecg.modules.dnc.request.TreeInfoRequest;
import org.jeecg.modules.system.entity.MdcProduction;
import org.jeecg.modules.system.entity.SysUser;
 
import java.util.Collection;
import java.util.List;
 
public interface IPartsInfoService extends IService<PartsInfo> {
    /**
     * 添加零件信息
     * @param partsInfo
     * @return
     */
    boolean addPartsInfo(PartsInfo partsInfo);
 
    /**
     * 编辑零件信息
     * @param id
     * @param partsInfo
     * @return
     */
    boolean editPartsInfo(String id, PartsInfo partsInfo);
 
    /**
     * 根据用户id获取授权的零件信息
     * @param userId
     * @return
     */
    List<PartsInfo> getByUserPerms(String userId);
 
    /**
     * 根据用户id获取授权的零件信息
     * @param userId
     * @param componentId
     * @return
     */
    List<PartsInfo> getByUserPerms(String userId, String componentId, String queryParam);
 
    /**
     * 根据产品id获取
     * @param productId
     * @return
     */
    List<PartsInfo> getByProductId(String productId);
 
    /**
     * 根据产品id 和部件id获取
     * @param productId
     * @param componentId
     * @return
     */
    List<PartsInfo> getByComponentId(String productId, String componentId);
 
    /**
     * 根据产品id删除下面的所有子节点
     * @param partsInfoList
     * @return
     */
    boolean deleteCollection(List<PartsInfo> partsInfoList);
 
    /**
     * 删除零件
     * @param partsId
     * @return
     */
    boolean deletePartsInfo(String partsId);
 
 
    /**
     * 分配用户权限
     * @param partsInfo
     * @param userList
     * @return
     */
    boolean assignAddUser(PartsInfo partsInfo, Collection<SysUser> userList);
 
    /**
     * 移除用户权限
     * @param partsInfo
     * @param userList
     * @return
     */
    boolean assignRemoveUser(PartsInfo partsInfo, Collection<SysUser> userList);
    /**
     * 分配部门权限
     * @param partsInfo
     * @param departmentList
     * @return
     */
    boolean assignAddDepart(PartsInfo partsInfo, Collection<MdcProduction> departmentList);
 
    /**
     * 分配部门权限
     * @param partsInfo
     * @param departmentList
     * @return
     */
    boolean assignRemoveDepart(PartsInfo partsInfo, Collection<MdcProduction> departmentList);
 
    /**
     * 根据一组部件查找零件
     * @param productId
     * @param componentIds
     * @return
     */
    List<PartsInfo> getByComponentIdList(String productId, List<String> componentIds);
 
    /**
     * 获取唯一 零件编号
     * @param partsCode
     * @return
     */
    PartsInfo getByCode(String partsCode);
 
    /**
     * 通过零件号、材质等查询对应电子样板
     * @param treeInfoRequest
     * @return
     */
    List<DocInfo> getByPartsInfo(TreeInfoRequest treeInfoRequest);
}