赫艾后端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2277 lines
67 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
6 months ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
9 months ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. package com.heai.modules.pms.controller;
  2. import com.heai.common.utils.PageUtils;
  3. import com.heai.common.utils.R;
  4. import com.heai.modules.base.entity.BuData;
  5. import com.heai.modules.oss.entity.SysOssEntity;
  6. import com.heai.modules.pms.data.*;
  7. import com.heai.modules.pms.entity.vo.CheckSubDetailValueVo;
  8. import com.heai.modules.pms.service.EamService;
  9. import com.heai.modules.pms.service.QcService;
  10. import com.heai.modules.pms.util.ResponseData;
  11. import com.heai.modules.sys.entity.SysSceneDynamicControlModelEntity;
  12. import org.springframework.beans.factory.annotation.Autowired;
  13. import org.springframework.web.bind.annotation.*;
  14. import org.springframework.web.multipart.MultipartFile;
  15. import java.util.*;
  16. /**
  17. * @description: 质量管理控制层
  18. * @author: fengyuan_yang
  19. * @date: 2023/3/20 17:02
  20. **/
  21. @RestController
  22. @RequestMapping("/pms/qc")
  23. public class QcController {
  24. @Autowired
  25. private QcService qcService;
  26. @Autowired
  27. private EamService eamService;
  28. // ======================= 检验方法API =======================
  29. /**
  30. * @description: 条件查询检验方法
  31. * @author: fengyuan_yang
  32. * @date: 2023/3/24 11:28
  33. * @param: [data]
  34. * @return: java.util.Map<java.lang.String,java.lang.Object>
  35. **/
  36. @PostMapping("/qcMethodSearch")
  37. public R qcMethodSearch(@RequestBody QcMethodData data){
  38. PageUtils page = qcService.qcMethodSearch(data);
  39. return R.ok().put("page", page);
  40. }
  41. /**
  42. * @description: 新增检验方法
  43. * @author: fengyuan_yang
  44. * @date: 2023/3/24 11:30
  45. * @param: [data]
  46. * @return: com.heai.modules.pms.util.ResponseData
  47. **/
  48. @PostMapping(value="/qcMethodSave")
  49. public R qcMethodSave (@RequestBody QcMethodData data) {
  50. qcService.qcMethodSave(data);
  51. return R.ok();
  52. }
  53. /**
  54. * @description: 修改检验方法
  55. * @author: fengyuan_yang
  56. * @date: 2023/3/24 11:31
  57. * @param: [data]
  58. * @return: com.heai.modules.pms.util.ResponseData
  59. **/
  60. @PostMapping(value="/qcMethodUpdate")
  61. public R qcMethodUpdate(@RequestBody QcMethodData data){
  62. qcService.qcMethodUpdate(data);
  63. return R.ok();
  64. }
  65. /**
  66. * @description: 删除检验方法
  67. * @author: fengyuan_yang
  68. * @date: 2023/3/24 11:32
  69. * @param: [data]
  70. * @return: com.heai.modules.pms.util.ResponseData
  71. **/
  72. @PostMapping(value="/qcMethodDelete")
  73. @ResponseBody
  74. public R qcMethodDelete(@RequestBody QcMethodData data){
  75. qcService.qcMethodDelete(data);
  76. return R.ok();
  77. }
  78. // ======================= 检验项目API =======================
  79. /**
  80. * @description: 查询检验项目
  81. * @author: fengyuan_yang
  82. * @date: 2023/3/20 17:03
  83. * @param: [data]
  84. * @return: java.lang.Object
  85. **/
  86. @PostMapping(value="/qcItemSearch")
  87. public R qcItemSearch(@RequestBody QcItemData data){
  88. PageUtils page = qcService.qcItemSearch(data);
  89. return R.ok().put("page", page);
  90. }
  91. /**
  92. * @description: 新增检验项目
  93. * @author: fengyuan_yang
  94. * @date: 2023/3/20 21:46
  95. * @param: [data]
  96. * @return: java.lang.Object
  97. **/
  98. @PostMapping(value="/qcItemSave")
  99. public R qcItemSave(@RequestBody QcItemData data){
  100. qcService.qcItemSave(data);
  101. return R.ok();
  102. }
  103. /**
  104. * @description: 修改检验项目
  105. * @author: fengyuan_yang
  106. * @date: 2023/3/20 22:27
  107. * @param: [data]
  108. * @return: java.lang.Object
  109. **/
  110. @PostMapping(value="/qcItemUpdate")
  111. @ResponseBody
  112. public R qcItemUpdate(@RequestBody QcItemData data){
  113. qcService.qcItemUpdate(data);
  114. return R.ok();
  115. }
  116. /**
  117. * @description: 删除检验项目
  118. * @author: fengyuan_yang
  119. * @date: 2023/3/20 23:12
  120. * @param: [data]
  121. * @return: java.lang.Object
  122. **/
  123. @PostMapping(value="/qcItemDelete")
  124. @ResponseBody
  125. public R qcItemDelete(@RequestBody QcItemData data){
  126. qcService.qcItemDelete(data);
  127. return R.ok();
  128. }
  129. /**
  130. * @description: 检验项目导入
  131. * @author: fengyuan_yang
  132. * @date: 2023/4/15 12:58
  133. * @param: [file]
  134. * @return: com.heai.common.utils.R
  135. **/
  136. @PostMapping("/uploadExcel")
  137. public R taskUploadExcel(@RequestParam(value = "file") MultipartFile file, @ModelAttribute GetParamInData data){
  138. qcService.taskUploadExcel(file, data);
  139. return R.ok();
  140. }
  141. // ======================= 根据物料设置检验模板API =======================
  142. /**
  143. * @description: 快速获取模板列表
  144. * @author: fengyuan_yang
  145. * @date: 2023/3/30 11:29
  146. * @param: [inData]
  147. * @return: com.heai.common.utils.R
  148. **/
  149. @PostMapping("/getItemLists")
  150. public R getItemLists(@RequestBody QcTemplateData data){
  151. // 可选模板
  152. List<QcTemplateData> row1 = qcService.getTemplateList(data);
  153. // 已有模板
  154. List<QcTemplateData> row2 = qcService.getPartTemplateList(data);
  155. return R.ok().put("row1", row1).put("row2", row2);
  156. }
  157. /**
  158. * @description: 物料属性设置模板新增
  159. * @author: fengyuan_yang
  160. * @date: 2023/7/9 22:55
  161. * @param: [data]
  162. * @return: com.heai.common.utils.R
  163. **/
  164. @PostMapping("/getPartTemplateLists")
  165. public R getPartTemplateLists(@RequestBody QcTemplateData data){
  166. // 可选模板
  167. List<QcTemplateData> row1 = qcService.getTemplateListAll(data);
  168. // 已有模板
  169. List<QcTemplateData> row2 = qcService.getPartTemplateList(data);
  170. return R.ok().put("row1", row1).put("row2", row2);
  171. }
  172. // ======================= 质检员信息维护API =======================
  173. /**
  174. * @description: 查询质检员信息列表
  175. * @author: fengyuan_yang
  176. * @date: 2023/3/31 8:48
  177. * @param: [data]
  178. * @return: com.heai.common.utils.R
  179. **/
  180. @PostMapping(value="/inspectorSearch")
  181. public R inspectorSearch(){
  182. List<QcInspectorData> list = qcService.inspectorSearch();
  183. return R.ok().put("rows", list);
  184. }
  185. /**
  186. * @description: 新增质检员信息
  187. * @author: fengyuan_yang
  188. * @date: 2023/3/31 8:59
  189. * @param: [data]
  190. * @return: com.heai.common.utils.R
  191. **/
  192. @PostMapping("/inspectorSave")
  193. public ResponseData inspectorSave(@RequestBody QcInspectorData data){
  194. ResponseData responseData = new ResponseData();
  195. try {
  196. responseData = qcService.inspectorSave(data);
  197. } catch (Exception e) {
  198. responseData.setCode("400");
  199. responseData.setMsg(e.getMessage());
  200. }
  201. return responseData;
  202. }
  203. /**
  204. * @description: 修改质检员信息
  205. * @author: fengyuan_yang
  206. * @date: 2023/3/31 9:03
  207. * @param: [data]
  208. * @return: com.heai.common.utils.R
  209. **/
  210. @PostMapping("/inspectorUpdate")
  211. public ResponseData inspectorUpdate(@RequestBody QcInspectorData data){
  212. ResponseData responseData = new ResponseData();
  213. try {
  214. responseData = qcService.inspectorUpdate(data);
  215. } catch (Exception e) {
  216. responseData.setCode("400");
  217. responseData.setMsg(e.getMessage());
  218. }
  219. return responseData;
  220. }
  221. /**
  222. * @description: 删除质检员信息
  223. * @author: fengyuan_yang
  224. * @date: 2023/3/31 9:07
  225. * @param: [data]
  226. * @return: com.heai.common.utils.R
  227. **/
  228. @PostMapping("/inspectorDelete")
  229. public ResponseData inspectorDelete(@RequestBody QcInspectorData data){
  230. ResponseData responseData = new ResponseData();
  231. try {
  232. responseData = qcService.inspectorDelete(data);
  233. } catch (Exception e) {
  234. responseData.setCode("400");
  235. responseData.setMsg(e.getMessage());
  236. }
  237. return responseData;
  238. }
  239. // ======================= 样本量字码矩阵维护API =======================
  240. /**
  241. * @description: 查询抽检方案
  242. * @author: fengyuan_yang
  243. * @date: 2023/4/7 16:14
  244. * @param: [data]
  245. * @return: com.heai.common.utils.R
  246. **/
  247. @PostMapping(value="/samplingInspectionPlanSearch")
  248. public R samplingInspectionPlanSearch(@RequestBody QcSamplingInspectionPlanData data){
  249. PageUtils page = qcService.samplingInspectionPlanSearch(data);
  250. return R.ok().put("page", page);
  251. }
  252. /**
  253. * @description: 新增抽样方案
  254. * @author: fengyuan_yang
  255. * @date: 2023/4/10 9:48
  256. * @param: [data]
  257. * @return: com.heai.common.utils.R
  258. **/
  259. @PostMapping(value="/samplingInspectionPlanSave")
  260. public R samplingInspectionPlanSave(@RequestBody QcSamplingInspectionPlanData data){
  261. qcService.samplingInspectionPlanSave(data);
  262. return R.ok();
  263. }
  264. /**
  265. * @description: 修改抽样方案
  266. * @author: fengyuan_yang
  267. * @date: 2023/4/10 12:58
  268. * @param: [data]
  269. * @return: com.heai.common.utils.R
  270. **/
  271. @PostMapping(value="/samplingInspectionPlanUpdate")
  272. public R samplingInspectionPlanUpdate(@RequestBody QcSamplingInspectionPlanData data){
  273. qcService.samplingInspectionPlanUpdate(data);
  274. return R.ok();
  275. }
  276. /**
  277. * @description: 删除抽样方案
  278. * @author: fengyuan_yang
  279. * @date: 2023/4/10 13:02
  280. * @param: [data]
  281. * @return: com.heai.common.utils.R
  282. **/
  283. @PostMapping(value="/samplingInspectionPlanDelete")
  284. public R samplingInspectionPlanDelete(@RequestBody QcSamplingInspectionPlanData data){
  285. qcService.samplingInspectionPlanDelete(data);
  286. return R.ok();
  287. }
  288. // ======================= 检验模板API =======================
  289. /**
  290. * @description: 查询模板
  291. * @author: fengyuan_yang
  292. * @date: 2023/4/10 15:55
  293. * @param: [data]
  294. * @return: com.heai.common.utils.R
  295. **/
  296. @PostMapping(value="/templateSearch")
  297. public R templateSearch(@RequestBody QcTemplateData data){
  298. PageUtils page = qcService.templateSearch(data);
  299. return R.ok().put("page", page);
  300. }
  301. /**
  302. * @description: 新增模板
  303. * @author: fengyuan_yang
  304. * @date: 2023/4/10 17:12
  305. * @param: [data]
  306. * @return: com.heai.common.utils.R
  307. **/
  308. @PostMapping(value="/templateSave")
  309. public R templateSave(@RequestBody QcTemplateData data){
  310. qcService.templateSave(data);
  311. return R.ok();
  312. }
  313. /**
  314. * @description: 修改模板
  315. * @author: fengyuan_yang
  316. * @date: 2023/4/10 17:38
  317. * @param: [data]
  318. * @return: com.heai.common.utils.R
  319. **/
  320. @PostMapping(value="/templateUpdate")
  321. public R templateUpdate(@RequestBody QcTemplateData data){
  322. qcService.templateUpdate(data);
  323. return R.ok();
  324. }
  325. /**
  326. * @description: 删除模板
  327. * @author: fengyuan_yang
  328. * @date: 2023/4/12 14:27
  329. * @param: [data]
  330. * @return: com.heai.common.utils.R
  331. **/
  332. @PostMapping(value="/templateDelete")
  333. public R templateDelete(@RequestBody QcTemplateData data){
  334. qcService.templateDelete(data);
  335. return R.ok();
  336. }
  337. /**
  338. * @description: 搜索所有检验类型
  339. * @author: fengyuan_yang
  340. * @date: 2023/4/18 17:09
  341. * @param: []
  342. * @return: com.heai.common.utils.R
  343. **/
  344. @PostMapping(value="/inspectionTypeSearch")
  345. public R inspectionTypeSearch(@RequestBody QcInspectionTypeData data){
  346. List<QcInspectionTypeData> list = qcService.inspectionTypeSearch(data);
  347. return R.ok().put("rows", list);
  348. }
  349. /**
  350. * @description: 搜索所有设备
  351. * @author: fengyuan_yang
  352. * @date: 2023/4/19 14:35
  353. * @param: []
  354. * @return: com.heai.common.utils.R
  355. **/
  356. @PostMapping(value="/objectSearch")
  357. public R objectSearch (@RequestBody EamObjectData data) {
  358. List<EamObjectData> list = qcService.objectSearch(data);
  359. return R.ok().put("rows", list);
  360. }
  361. /**
  362. * @description: 查询项目列表
  363. * @author: fengyuan_yang
  364. * @date: 2023/4/11 9:39
  365. * @param: [data]
  366. * @return: com.heai.common.utils.R
  367. **/
  368. @PostMapping(value="/templateDetailsSearch")
  369. public R templateDetailsSearch(@RequestBody QcTemplateData data){
  370. List<QcTemplateData> list = qcService.templateDetailsSearch(data);
  371. return R.ok().put("rows", list);
  372. }
  373. /**
  374. * @description: 新增模板的检验项目
  375. * @author: fengyuan_yang
  376. * @date: 2023/4/11 10:04
  377. * @param: [data]
  378. * @return: com.heai.common.utils.R
  379. **/
  380. @PostMapping("/addItemDetails")
  381. public R addItemDetails(@RequestBody QcTemplateData data){
  382. qcService.addItemDetails(data);
  383. return R.ok();
  384. }
  385. /**
  386. * @description: 快速新增
  387. * @author: fengyuan_yang
  388. * @date: 2023/4/12 13:45
  389. * @param: [inData]
  390. * @return: com.heai.common.utils.R
  391. **/
  392. @PostMapping("/getItemList")
  393. public R getItemList(@RequestBody QcTemplateData data){
  394. // 获取当前项目不包含的明细
  395. List<QcTemplateData> row1 = qcService.getItemList(data);
  396. // 获取当前项目所包含的明细
  397. List<QcTemplateData> row2 = qcService.templateDetailsSearch(data);
  398. return R.ok().put("row1", row1).put("row2", row2);
  399. }
  400. /**
  401. * @description: 查询项目
  402. * @author: fengyuan_yang
  403. * @date: 2023/11/19 13:03
  404. * @param: [data]
  405. * @return: com.heai.common.utils.R
  406. **/
  407. @PostMapping("/getItem")
  408. public R getItem(@RequestBody QcTemplateData data){
  409. List<QcTemplateData> rows = qcService.getItem(data);
  410. return R.ok().put("rows", rows);
  411. }
  412. /**
  413. * @description: 删除模板的检验项目
  414. * @author: fengyuan_yang
  415. * @date: 2023/4/11 10:57
  416. * @param: [inData]
  417. * @return: com.heai.common.utils.R
  418. **/
  419. @PostMapping("/delItemDetails")
  420. public R delItemDetails(@RequestBody QcTemplateData data){
  421. qcService.delItemDetails(data);
  422. return R.ok();
  423. }
  424. /**
  425. * @description: 新增项目明细的最大最小值
  426. * @author: fengyuan_yang
  427. * @date: 2023/4/16 17:26
  428. * @param: [data]
  429. * @return: com.heai.common.utils.R
  430. **/
  431. @PostMapping("/saveItemDetailed")
  432. public R saveItemDetailed(@RequestBody QcTemplateData data){
  433. qcService.saveItemDetailed(data);
  434. return R.ok();
  435. }
  436. /**
  437. * @description: 检验模板导入
  438. * @author: fengyuan_yang
  439. * @date: 2023/4/22 16:29
  440. * @param: [file]
  441. * @return: com.heai.common.utils.R
  442. **/
  443. @PostMapping("/uploadTemplateExcel")
  444. public R uploadTemplateExcel(@RequestParam(value = "file") MultipartFile file, @ModelAttribute GetParamInData data){
  445. qcService.uploadTemplateExcel(file, data);
  446. return R.ok();
  447. }
  448. // ======================= 样本量API =======================
  449. /**
  450. * @description: 查询样本量
  451. * @author: fengyuan_yang
  452. * @date: 2023/4/17 10:48
  453. * @param: [data]
  454. * @return: com.heai.common.utils.R
  455. **/
  456. @PostMapping("/samplingQtySearch")
  457. public R samplingQtySearch(@RequestBody QcSamplingInspectionQtyData data){
  458. PageUtils page = qcService.samplingQtySearch(data);
  459. return R.ok().put("page", page);
  460. }
  461. /**
  462. * @description: 新增样本量
  463. * @author: fengyuan_yang
  464. * @date: 2023/4/17 11:24
  465. * @param: [data]
  466. * @return: com.heai.common.utils.R
  467. **/
  468. @PostMapping("/samplingQtySave")
  469. public R samplingQtySave(@RequestBody QcSamplingInspectionQtyData data){
  470. qcService.samplingQtySave(data);
  471. return R.ok();
  472. }
  473. /**
  474. * @description: 修改样本量
  475. * @author: fengyuan_yang
  476. * @date: 2023/4/17 13:01
  477. * @param: [data]
  478. * @return: com.heai.common.utils.R
  479. **/
  480. @PostMapping("/samplingQtyUpdate")
  481. public R samplingQtyUpdate(@RequestBody QcSamplingInspectionQtyData data){
  482. qcService.samplingQtyUpdate(data);
  483. return R.ok();
  484. }
  485. /**
  486. * @description: 删除样本量
  487. * @author: fengyuan_yang
  488. * @date: 2023/4/17 13:22
  489. * @param: [data]
  490. * @return: com.heai.common.utils.R
  491. **/
  492. @PostMapping("/samplingQtyDelete")
  493. public R samplingQtyDelete(@RequestBody QcSamplingInspectionQtyData data){
  494. qcService.samplingQtyDelete(data);
  495. return R.ok();
  496. }
  497. // ======================= 批量级次API =======================
  498. /**
  499. * @description: 查询批量级次
  500. * @author: fengyuan_yang
  501. * @date: 2023/4/17 13:38
  502. * @param: [data]
  503. * @return: com.heai.common.utils.R
  504. **/
  505. @PostMapping("/samplingQtyRankSearch")
  506. public R samplingQtyRankSearch(@RequestBody QcSamplingInspectionQtyRankData data){
  507. PageUtils page = qcService.samplingQtyRankSearch(data);
  508. return R.ok().put("page", page);
  509. }
  510. /**
  511. * @description: 新增批量级次
  512. * @author: fengyuan_yang
  513. * @date: 2023/4/17 11:24
  514. * @param: [data]
  515. * @return: com.heai.common.utils.R
  516. **/
  517. @PostMapping("/samplingQtyRankSave")
  518. public R samplingQtyRankSave(@RequestBody QcSamplingInspectionQtyRankData data){
  519. qcService.samplingQtyRankSave(data);
  520. return R.ok();
  521. }
  522. /**
  523. * @description: 修改批量级次
  524. * @author: fengyuan_yang
  525. * @date: 2023/4/17 13:01
  526. * @param: [data]
  527. * @return: com.heai.common.utils.R
  528. **/
  529. @PostMapping("/samplingQtyRankUpdate")
  530. public R samplingQtyRankUpdate(@RequestBody QcSamplingInspectionQtyRankData data){
  531. qcService.samplingQtyRankUpdate(data);
  532. return R.ok();
  533. }
  534. /**
  535. * @description: 删除批量级次
  536. * @author: fengyuan_yang
  537. * @date: 2023/4/17 13:22
  538. * @param: [data]
  539. * @return: com.heai.common.utils.R
  540. **/
  541. @PostMapping("/samplingQtyRankDelete")
  542. public R samplingQtyRankDelete(@RequestBody QcSamplingInspectionQtyRankData data){
  543. qcService.samplingQtyRankDelete(data);
  544. return R.ok();
  545. }
  546. // ======================= 检验等级API =======================
  547. /**
  548. * @description: 查询检验等级
  549. * @author: fengyuan_yang
  550. * @date: 2023/4/17 13:38
  551. * @param: [data]
  552. * @return: com.heai.common.utils.R
  553. **/
  554. @PostMapping("/samplingLevelSearch")
  555. public R samplingLevelSearch(@RequestBody QcSamplingInspectionLevelData data){
  556. PageUtils page = qcService.samplingLevelSearch(data);
  557. return R.ok().put("page", page);
  558. }
  559. /**
  560. * @description: 新增检验等级
  561. * @author: fengyuan_yang
  562. * @date: 2023/4/17 11:24
  563. * @param: [data]
  564. * @return: com.heai.common.utils.R
  565. **/
  566. @PostMapping("/samplingLevelSave")
  567. public R samplingLevelSave(@RequestBody QcSamplingInspectionLevelData data){
  568. qcService.samplingLevelSave(data);
  569. return R.ok();
  570. }
  571. /**
  572. * @description: 修改检验等级
  573. * @author: fengyuan_yang
  574. * @date: 2023/4/17 13:01
  575. * @param: [data]
  576. * @return: com.heai.common.utils.R
  577. **/
  578. @PostMapping("/samplingLevelUpdate")
  579. public R samplingLevelUpdate(@RequestBody QcSamplingInspectionLevelData data){
  580. qcService.samplingLevelUpdate(data);
  581. return R.ok();
  582. }
  583. /**
  584. * @description: 删除检验等级
  585. * @author: fengyuan_yang
  586. * @date: 2023/4/17 13:22
  587. * @param: [data]
  588. * @return: com.heai.common.utils.R
  589. **/
  590. @PostMapping("/samplingLevelDelete")
  591. public R samplingLevelDelete(@RequestBody QcSamplingInspectionLevelData data){
  592. qcService.samplingLevelDelete(data);
  593. return R.ok();
  594. }
  595. // ======================= 物料属性设置API =======================
  596. /**
  597. * @description: 查询物料属性
  598. * @author: fengyuan_yang
  599. * @date: 2023/4/19 11:42
  600. * @param: [data]
  601. * @return: com.heai.common.utils.R
  602. **/
  603. @PostMapping(value="/qcPartAttributeSearch")
  604. public R qcPartAttributeSearch(@RequestBody QcPartAttributeData data){
  605. PageUtils page = qcService.qcPartAttributeSearch(data);
  606. return R.ok().put("page", page);
  607. }
  608. /**
  609. * @description: 新增物料属性
  610. * @author: fengyuan_yang
  611. * @date: 2023/4/19 17:14
  612. * @param: [data]
  613. * @return: com.heai.common.utils.R
  614. **/
  615. @PostMapping("/qcPartAttributeSave")
  616. public R qcPartAttributeSave(@RequestBody QcPartAttributeData data){
  617. qcService.qcPartAttributeSave(data);
  618. return R.ok();
  619. }
  620. /**
  621. * @description: 物料属性修改
  622. * @author: fengyuan_yang
  623. * @date: 2023/10/27 13:25
  624. * @param: [data]
  625. * @return: com.heai.common.utils.R
  626. **/
  627. @PostMapping("/overLoadSearchPartInfo")
  628. public R overLoadSearchPartInfo(@RequestBody QcPartAttributeData data){
  629. PageUtils page = qcService.qcPartAttributeSearch(data);
  630. return R.ok().put("list", page.getList());
  631. }
  632. /**
  633. * @description: 物料属性修改
  634. * @author: fengyuan_yang
  635. * @date: 2023/10/27 13:25
  636. * @param: [data]
  637. * @return: com.heai.common.utils.R
  638. **/
  639. @PostMapping("/qcPartAttributeEdit")
  640. public R qcPartAttributeEdit(@RequestBody QcPartAttributeData data){
  641. qcService.qcPartAttributeEdit(data);
  642. return R.ok();
  643. }
  644. /**
  645. * @description: 删除物料属性
  646. * @author: fengyuan_yang
  647. * @date: 2023/4/20 16:42
  648. * @param: [data]
  649. * @return: com.heai.common.utils.R
  650. **/
  651. @PostMapping("/qcPartAttributeDelete")
  652. public R qcPartAttributeDelete(@RequestBody QcPartAttributeData data){
  653. qcService.qcPartAttributeDelete(data);
  654. return R.ok();
  655. }
  656. /**
  657. * @description: 查询物料模板
  658. * @author: fengyuan_yang
  659. * @date: 2023/4/19 17:50
  660. * @param: [data]
  661. * @return: com.heai.common.utils.R
  662. **/
  663. @PostMapping("/searchPartAttributeDetails")
  664. public R searchPartAttributeDetails(@RequestBody QcTemplateData data){
  665. List<QcTemplateData> list = qcService.searchPartAttributeDetails(data);
  666. return R.ok().put("rows", list).put("total", list.size());
  667. }
  668. /**
  669. * @description: 新增物料属性模板
  670. * @author: fengyuan_yang
  671. * @date: 2023/4/20 9:33
  672. * @param: [data]
  673. * @return: com.heai.common.utils.R
  674. **/
  675. @PostMapping("/savePartAttributeDetails")
  676. public R savePartAttributeDetails(@RequestBody QcTemplateData data){
  677. qcService.savePartAttributeDetails(data);
  678. return R.ok();
  679. }
  680. /**
  681. * @description: 删除物料属性模板
  682. * @author: fengyuan_yang
  683. * @date: 2023/4/20 13:10
  684. * @param: [data]
  685. * @return: com.heai.common.utils.R
  686. **/
  687. @PostMapping("/deletePartAttributeDetails")
  688. public R deletePartAttributeDetails(@RequestBody QcTemplateData data){
  689. qcService.deletePartAttributeDetails(data);
  690. return R.ok();
  691. }
  692. /**
  693. * @description: 新增物料属性模板详情
  694. * @author: fengyuan_yang
  695. * @date: 2023/4/20 15:32
  696. * @param: [data]
  697. * @return: com.heai.common.utils.R
  698. **/
  699. @PostMapping("/saveAttributeDetailed")
  700. public R saveAttributeDetailed(@RequestBody QcTemplateData data){
  701. qcService.saveAttributeDetailed(data);
  702. return R.ok();
  703. }
  704. /**
  705. * 物料属性-检验标准明细(qc_part_attr_detailed)
  706. */
  707. @PostMapping("/partAttrDetailedSearch")
  708. public R partAttrDetailedSearch(@RequestBody QcTemplateData data) {
  709. List<QcTemplateData> list = qcService.partAttrDetailedSearch(data);
  710. return R.ok().put("rows", list);
  711. }
  712. @PostMapping("/getPartAttrItemList")
  713. public R getPartAttrItemList(@RequestBody QcTemplateData data) {
  714. List<QcTemplateData> row1 = qcService.getPartAttrItemList(data);
  715. List<QcTemplateData> row2 = qcService.partAttrDetailedSearch(data);
  716. return R.ok().put("row1", row1).put("row2", row2);
  717. }
  718. @PostMapping("/getPartAttrItem")
  719. public R getPartAttrItem(@RequestBody QcTemplateData data) {
  720. List<QcTemplateData> rows = qcService.getPartAttrItem(data);
  721. return R.ok().put("rows", rows);
  722. }
  723. @PostMapping("/addPartAttrItemDetails")
  724. public R addPartAttrItemDetails(@RequestBody QcTemplateData data) {
  725. qcService.addPartAttrItemDetails(data);
  726. return R.ok();
  727. }
  728. @PostMapping("/delPartAttrItemDetails")
  729. public R delPartAttrItemDetails(@RequestBody QcTemplateData data) {
  730. qcService.delPartAttrItemDetails(data);
  731. return R.ok();
  732. }
  733. @PostMapping("/savePartAttrDetailed")
  734. public R savePartAttrDetailed(@RequestBody QcTemplateData data) {
  735. qcService.savePartAttrDetailed(data);
  736. return R.ok();
  737. }
  738. @PostMapping("/goUpPartAttrItem")
  739. public R goUpPartAttrItem(@RequestBody QcTemplateData data) {
  740. qcService.goUpPartAttrItem(data);
  741. return R.ok();
  742. }
  743. @PostMapping("/goDownPartAttrItem")
  744. public R goDownPartAttrItem(@RequestBody QcTemplateData data) {
  745. qcService.goDownPartAttrItem(data);
  746. return R.ok();
  747. }
  748. /**
  749. * @description: 物料属性导入
  750. * @author: fengyuan_yang
  751. * @date: 2023/4/23 11:33
  752. * @param: [file]
  753. * @return: com.heai.common.utils.R
  754. **/
  755. @PostMapping("/uploadPartAttributeExcel")
  756. public R uploadPartAttributeExcel(@RequestParam(value = "file") MultipartFile file, @ModelAttribute GetParamInData data){
  757. qcService.uploadPartAttributeExcel(file, data);
  758. return R.ok();
  759. }
  760. // ======================= 分类属性设置API =======================
  761. /**
  762. * @description: 查询类别属性
  763. * @author: fengyuan_yang
  764. * @date: 2023/4/21 9:08
  765. * @param: [data]
  766. * @return: com.heai.common.utils.R
  767. **/
  768. @PostMapping(value="/qcFamilyAttributeSearch")
  769. public R qcFamilyAttributeSearch(@RequestBody QcPartAttributeData data){
  770. PageUtils page = qcService.qcFamilyAttributeSearch(data);
  771. return R.ok().put("page", page);
  772. }
  773. /**
  774. * @description: 新增类别属性
  775. * @author: fengyuan_yang
  776. * @date: 2023/4/21 9:29
  777. * @param: [data]
  778. * @return: com.heai.common.utils.R
  779. **/
  780. @PostMapping("/qcFamilyAttributeSave")
  781. public R qcFamilyAttributeSave(@RequestBody QcPartAttributeData data){
  782. qcService.qcFamilyAttributeSave(data);
  783. return R.ok();
  784. }
  785. /**
  786. * @description: 删除类别属性
  787. * @author: fengyuan_yang
  788. * @date: 2023/4/21 9:56
  789. * @param: [data]
  790. * @return: com.heai.common.utils.R
  791. **/
  792. @PostMapping("/qcFamilyAttributeDelete")
  793. public R qcFamilyAttributeDelete(@RequestBody QcPartAttributeData data){
  794. qcService.qcFamilyAttributeDelete(data);
  795. return R.ok();
  796. }
  797. /**
  798. * @description: 类别属性导入
  799. * @author: fengyuan_yang
  800. * @date: 2023/4/23 15:58
  801. * @param: [file]
  802. * @return: com.heai.common.utils.R
  803. **/
  804. @PostMapping("/uploadFamilyAttributeExcel")
  805. public R uploadFamilyAttributeExcel(@RequestParam(value = "file") MultipartFile file, @ModelAttribute GetParamInData data){
  806. qcService.uploadFamilyAttributeExcel(file, data);
  807. return R.ok();
  808. }
  809. // ======================= 抽样方案API =======================
  810. /**
  811. * @description: 查询抽样方案
  812. * @author: fengyuan_yang
  813. * @date: 2023/4/21 13:32
  814. * @param: [data]
  815. * @return: com.heai.common.utils.R
  816. **/
  817. @PostMapping(value="/samplingProgrammeSearch")
  818. public R samplingProgrammeSearch(@RequestBody QcSamplingInspectionProgrammeData data){
  819. PageUtils page = qcService.samplingProgrammeSearch(data);
  820. return R.ok().put("page", page);
  821. }
  822. /**
  823. * @description: 新增抽样方案
  824. * @author: fengyuan_yang
  825. * @date: 2023/4/21 13:47
  826. * @param: [data]
  827. * @return: com.heai.common.utils.R
  828. **/
  829. @PostMapping("/samplingProgrammeSave")
  830. public R samplingProgrammeSave(@RequestBody QcSamplingInspectionProgrammeData data){
  831. qcService.samplingProgrammeSave(data);
  832. return R.ok();
  833. }
  834. /**
  835. * @description: 删除抽样方案
  836. * @author: fengyuan_yang
  837. * @date: 2023/4/23 8:58
  838. * @param: [data]
  839. * @return: com.heai.common.utils.R
  840. **/
  841. @PostMapping("/samplingProgrammeDelete")
  842. public R samplingProgrammeDelete(@RequestBody QcSamplingInspectionProgrammeData data){
  843. qcService.samplingProgrammeDelete(data);
  844. return R.ok();
  845. }
  846. /**
  847. * @description: 搜索抽样方案中的矩阵
  848. * @author: fengyuan_yang
  849. * @date: 2023/4/21 15:43
  850. * @param: [data]
  851. * @return: com.heai.common.utils.R
  852. **/
  853. @PostMapping("/searchSamplingProgrammeDetails")
  854. public R searchSamplingProgrammeDetails(@RequestBody QcSamplingInspectionProgrammeData data){
  855. List<QcSamplingInspectionProgrammeData> list = qcService.searchSamplingProgrammeDetails(data);
  856. return R.ok().put("rows", list);
  857. }
  858. /**
  859. * @description: 获取矩阵列表
  860. * @author: fengyuan_yang
  861. * @date: 2023/4/21 16:38
  862. * @param: [data]
  863. * @return: com.heai.common.utils.R
  864. **/
  865. @PostMapping("/getPlanLists")
  866. public R getPlanLists(@RequestBody QcSamplingInspectionProgrammeData data){
  867. // 获取该方案不包含的矩阵
  868. List<QcSamplingInspectionProgrammeData> row1 = qcService.getPlanList(data);
  869. // 获取当前方案所包含的矩阵
  870. List<QcSamplingInspectionProgrammeData> row2 = qcService.getProgrammePlanList(data);
  871. return R.ok().put("row1", row1).put("row2", row2);
  872. }
  873. /**
  874. * @description: 新增抽样方案中的矩阵
  875. * @author: fengyuan_yang
  876. * @date: 2023/4/21 17:41
  877. * @param: [data]
  878. * @return: com.heai.common.utils.R
  879. **/
  880. @PostMapping("/saveSamplingProgrammeDetails")
  881. public R saveSamplingProgrammeDetails(@RequestBody QcSamplingInspectionProgrammeData data){
  882. qcService.saveSamplingProgrammeDetails(data);
  883. return R.ok();
  884. }
  885. /**
  886. * @description: 删除抽样方案中的矩阵
  887. * @author: fengyuan_yang
  888. * @date: 2023/4/21 17:52
  889. * @param: [data]
  890. * @return: com.heai.common.utils.R
  891. **/
  892. @PostMapping("/deleteSamplingProgrammeDetails")
  893. public R deleteSamplingProgrammeDetails(@RequestBody QcSamplingInspectionProgrammeData data){
  894. qcService.deleteSamplingProgrammeDetails(data);
  895. return R.ok();
  896. }
  897. // ======================= FAI检验API =======================
  898. /**
  899. * @description: FAI记录查询
  900. * @author: fengyuan_yang
  901. * @date: 2023/4/24 10:10
  902. * @param: [data]
  903. * @return: com.heai.common.utils.R
  904. **/
  905. @PostMapping(value="/qcFAIInspectionSearch")
  906. public R qcFAIInspectionSearch(@RequestBody QcFAIRecordData data){
  907. PageUtils page = qcService.qcFAIInspectionSearch(data);
  908. return R.ok().put("page", page);
  909. }
  910. /**
  911. * @description: FAI明细记录查询
  912. * @author: fengyuan_yang
  913. * @date: 2023/4/25 9:16
  914. * @param: [data]
  915. * @return: com.heai.common.utils.R
  916. **/
  917. @PostMapping("/faiDetailSearch")
  918. public R faiDetailSearch(@RequestBody QcFAIRecordData data){
  919. List<QcFAIRecordData> list = qcService.faiDetailSearch(data);
  920. return R.ok().put("rows", list);
  921. }
  922. /**
  923. * @description: 保存FAI检验记录
  924. * @author: fengyuan_yang
  925. * @date: 2023/3/30 8:50
  926. * @param: [data]
  927. * @return: com.heai.common.utils.R
  928. **/
  929. @PostMapping("/saveFAIDetailedRecord")
  930. public R saveFAIDetailedRecord(@RequestBody QcFAIRecordData data){
  931. qcService.saveFAIDetailedRecord(data);
  932. return R.ok();
  933. }
  934. /**
  935. * @description: 删除FAI检验记录
  936. * @author: fengyuan_yang
  937. * @date: 2023/3/30 9:03
  938. * @param: [data]
  939. * @return: com.heai.common.utils.R
  940. **/
  941. @PostMapping("/faiRecordDelete")
  942. public R faiRecordDelete(@RequestBody QcFAIRecordData data){
  943. qcService.faiRecordDelete(data);
  944. return R.ok();
  945. }
  946. /**
  947. * @description: FAI审核
  948. * @author: fengyuan_yang
  949. * @date: 2023/3/31 17:17
  950. * @param: [data]
  951. * @return: com.heai.common.utils.R
  952. **/
  953. @PostMapping("/saveFAISubmitResult")
  954. public R saveFAISubmitResult(@RequestBody QcFAIRecordData data){
  955. qcService.saveFAISubmitResult(data);
  956. return R.ok();
  957. }
  958. /**
  959. * @description: 新增FAI子明细
  960. * @author: fengyuan_yang
  961. * @date: 2023/4/4 13:50
  962. * @param: [data]
  963. * @return: com.heai.common.utils.R
  964. **/
  965. @PostMapping("/saveFAISubDetailed")
  966. public R saveFAISubDetailed(@RequestBody QcSubDetailInformationData data){
  967. Integer count = qcService.saveFAISubDetailed(data);
  968. return R.ok().put("count", count);
  969. }
  970. /**
  971. * @description: 查询FAI子明细
  972. * @author: fengyuan_yang
  973. * @date: 2023/4/4 16:06
  974. * @param: [data]
  975. * @return: com.heai.common.utils.R
  976. **/
  977. @PostMapping("/selectFAISubDetailedRecord")
  978. public R selectFAISubDetailedRecord(@RequestBody SubDetailValues data){
  979. List<SubDetailValues> list = qcService.selectFAISubDetailedRecord(data);
  980. return R.ok().put("rows", list);
  981. }
  982. /**
  983. * @description: 检查FAI是否已提交
  984. * @author: fengyuan_yang
  985. * @date: 2023/4/5 9:50
  986. * @param: [data]
  987. * @return: com.heai.common.utils.R
  988. **/
  989. @PostMapping("/checkFAIIsSubmit")
  990. public R checkFAIIsSubmit(@RequestBody SubDetailValues data){
  991. Integer flag = qcService.checkFAIIsSubmit(data);
  992. return R.ok().put("flag", flag);
  993. }
  994. /**
  995. * @description: 检查FAI子明细中的实测值是否在规定范围
  996. * @author: fengyuan_yang
  997. * @date: 2023/4/6 16:13
  998. * @param: [data]
  999. * @return: com.heai.common.utils.R
  1000. **/
  1001. @PostMapping("/checkFAISubDetailValue")
  1002. public R checkFAISubDetailValue(@RequestBody CheckSubDetailValueVo data){
  1003. Integer flag = qcService.checkFAISubDetailValue(data);
  1004. return R.ok().put("flag", flag);
  1005. }
  1006. /**
  1007. * @description: 新增FAI检验
  1008. * @author: fengyuan_yang
  1009. * @date: 2023/9/18 10:03
  1010. * @param: [data]
  1011. * @return: com.heai.common.utils.R
  1012. **/
  1013. @PostMapping("/saveFAIInspection")
  1014. public R saveFAIInspection(@RequestBody QcFAIRecordData data){
  1015. qcService.saveFAIInspection(data);
  1016. return R.ok();
  1017. }
  1018. // ======================= FQC检验API =======================
  1019. /**
  1020. * @description: FQC记录查询
  1021. * @author: fengyuan_yang
  1022. * @date: 2023/9/18 11:32
  1023. * @param: [data]
  1024. * @return: com.heai.common.utils.R
  1025. **/
  1026. @PostMapping(value="/qcFQCInspectionSearch")
  1027. public R qcFQCInspectionSearch(@RequestBody QcFAIRecordData data){
  1028. PageUtils page = qcService.qcFQCInspectionSearch(data);
  1029. return R.ok().put("page", page);
  1030. }
  1031. /**
  1032. * @description: FQC记录新增
  1033. * @author: fengyuan_yang
  1034. * @date: 2023/9/18 11:34
  1035. * @param: [data]
  1036. * @return: com.heai.common.utils.R
  1037. **/
  1038. @PostMapping("/saveFQCInspection")
  1039. public R saveFQCInspection(@RequestBody QcFAIRecordData data){
  1040. qcService.saveFQCInspection(data);
  1041. return R.ok();
  1042. }
  1043. /**
  1044. * @description: FQC明细记录查询
  1045. * @author: fengyuan_yang
  1046. * @date: 2023/9/18 13:04
  1047. * @param: [data]
  1048. * @return: com.heai.common.utils.R
  1049. **/
  1050. @PostMapping("/fqcDetailSearch")
  1051. public R fqcDetailSearch(@RequestBody QcFAIRecordData data){
  1052. List<QcFAIRecordData> list = qcService.fqcDetailSearch(data);
  1053. return R.ok().put("rows", list);
  1054. }
  1055. /**
  1056. * @description: 删除FQC检验记录
  1057. * @author: fengyuan_yang
  1058. * @date: 2023/9/18 13:07
  1059. * @param: [data]
  1060. * @return: com.heai.common.utils.R
  1061. **/
  1062. @PostMapping("/fqcRecordDelete")
  1063. public R fqcRecordDelete(@RequestBody QcFAIRecordData data){
  1064. qcService.fqcRecordDelete(data);
  1065. return R.ok();
  1066. }
  1067. /**
  1068. * @description: 保存FQC检验记录
  1069. * @author: fengyuan_yang
  1070. * @date: 2023/9/18 13:12
  1071. * @param: [data]
  1072. * @return: com.heai.common.utils.R
  1073. **/
  1074. @PostMapping("/saveFQCDetailedRecord")
  1075. public R saveFQCDetailedRecord(@RequestBody QcFAIRecordData data){
  1076. qcService.saveFQCDetailedRecord(data);
  1077. return R.ok();
  1078. }
  1079. /**
  1080. * @description: FQC审核
  1081. * @author: fengyuan_yang
  1082. * @date: 2023/9/18 13:20
  1083. * @param: [data]
  1084. * @return: com.heai.common.utils.R
  1085. **/
  1086. @PostMapping("/saveFQCSubmitResult")
  1087. public R saveFQCSubmitResult(@RequestBody QcFAIRecordData data){
  1088. qcService.saveFQCSubmitResult(data);
  1089. return R.ok();
  1090. }
  1091. /**
  1092. * @description: 新增FQC子明细
  1093. * @author: fengyuan_yang
  1094. * @date: 2023/9/18 13:24
  1095. * @param: [data]
  1096. * @return: com.heai.common.utils.R
  1097. **/
  1098. @PostMapping("/saveFQCSubDetailed")
  1099. public R saveFQCSubDetailed(@RequestBody QcSubDetailInformationData data){
  1100. Integer count = qcService.saveFQCSubDetailed(data);
  1101. return R.ok().put("count", count);
  1102. }
  1103. /**
  1104. * @description: 查询FQC子明细
  1105. * @author: fengyuan_yang
  1106. * @date: 2023/9/18 13:28
  1107. * @param: [data]
  1108. * @return: com.heai.common.utils.R
  1109. **/
  1110. @PostMapping("/selectFQCSubDetailedRecord")
  1111. public R selectFQCSubDetailedRecord(@RequestBody SubDetailValues data){
  1112. List<SubDetailValues> list = qcService.selectFQCSubDetailedRecord(data);
  1113. return R.ok().put("rows", list);
  1114. }
  1115. /**
  1116. * @description: 检查是否已提交
  1117. * @author: fengyuan_yang
  1118. * @date: 2023/9/18 13:31
  1119. * @param: [data]
  1120. * @return: com.heai.common.utils.R
  1121. **/
  1122. @PostMapping("/checkFQCIsSubmit")
  1123. public R checkFQCIsSubmit(@RequestBody SubDetailValues data){
  1124. Integer flag = qcService.checkFQCIsSubmit(data);
  1125. return R.ok().put("flag", flag);
  1126. }
  1127. /**
  1128. * @description: 检查FQC子明细中的实测值是否在规定范围
  1129. * @author: fengyuan_yang
  1130. * @date: 2023/9/18 13:35
  1131. * @param: [data]
  1132. * @return: com.heai.common.utils.R
  1133. **/
  1134. @PostMapping("/checkFQCSubDetailValue")
  1135. public R checkFQCSubDetailValue(@RequestBody CheckSubDetailValueVo data){
  1136. Integer flag = qcService.checkFQCSubDetailValue(data);
  1137. return R.ok().put("flag", flag);
  1138. }
  1139. // ======================= IPQC检验API =======================
  1140. /**
  1141. * @description: IPQC记录查询
  1142. * @author: fengyuan_yang
  1143. * @date: 2023/4/24 10:10
  1144. * @param: [data]
  1145. * @return: com.heai.common.utils.R
  1146. **/
  1147. @PostMapping(value="/qcIPQCInspectionSearch")
  1148. public R qcIPQCInspectionSearch(@RequestBody QcFAIRecordData data){
  1149. PageUtils page = qcService.qcIPQCInspectionSearch(data);
  1150. return R.ok().put("page", page);
  1151. }
  1152. /**
  1153. * @description: IPQC明细记录查询
  1154. * @author: fengyuan_yang
  1155. * @date: 2023/4/25 9:16
  1156. * @param: [data]
  1157. * @return: com.heai.common.utils.R
  1158. **/
  1159. @PostMapping("/ipqcDetailSearch")
  1160. public R ipqcDetailSearch(@RequestBody QcFAIRecordData data){
  1161. List<QcFAIRecordData> list = qcService.ipqcDetailSearch(data);
  1162. return R.ok().put("rows", list);
  1163. }
  1164. /**
  1165. * @description: 删除IPQC检验记录
  1166. * @author: fengyuan_yang
  1167. * @date: 2023/3/30 9:03
  1168. * @param: [data]
  1169. * @return: com.heai.common.utils.R
  1170. **/
  1171. @PostMapping("/ipqcRecordDelete")
  1172. public R ipqcRecordDelete(@RequestBody QcFAIRecordData data){
  1173. qcService.ipqcRecordDelete(data);
  1174. return R.ok();
  1175. }
  1176. /**
  1177. * @description: 保存IPQC检验记录
  1178. * @author: fengyuan_yang
  1179. * @date: 2023/4/26 17:26
  1180. * @param: [data]
  1181. * @return: com.heai.common.utils.R
  1182. **/
  1183. @PostMapping("/saveIPQCDetailedRecord")
  1184. public R saveIPQCDetailedRecord(@RequestBody QcFAIRecordData data){
  1185. qcService.saveIPQCDetailedRecord(data);
  1186. return R.ok();
  1187. }
  1188. /**
  1189. * @description: IPQC审核
  1190. * @author: fengyuan_yang
  1191. * @date: 2023/4/26 17:36
  1192. * @param: [data]
  1193. * @return: com.heai.common.utils.R
  1194. **/
  1195. @PostMapping("/saveIPQCSubmitResult")
  1196. public R saveIPQCSubmitResult(@RequestBody QcFAIRecordData data){
  1197. qcService.saveIPQCSubmitResult(data);
  1198. return R.ok();
  1199. }
  1200. /**
  1201. * @description: 新增IPQC子明细信息
  1202. * @author: fengyuan_yang
  1203. * @date: 2023/4/26 17:46
  1204. * @param: [data]
  1205. * @return: com.heai.common.utils.R
  1206. **/
  1207. @PostMapping("/saveIPQCSubDetailed")
  1208. public R saveIPQCSubDetailed(@RequestBody QcSubDetailInformationData data){
  1209. Integer count = qcService.saveIPQCSubDetailed(data);
  1210. return R.ok().put("count", count);
  1211. }
  1212. /**
  1213. * @description: 查询IPQC子明细
  1214. * @author: fengyuan_yang
  1215. * @date: 2023/4/26 17:56
  1216. * @param: [data]
  1217. * @return: com.heai.common.utils.R
  1218. **/
  1219. @PostMapping("/selectIPQCSubDetailedRecord")
  1220. public R selectIPQCSubDetailedRecord(@RequestBody SubDetailValues data){
  1221. List<SubDetailValues> list = qcService.selectIPQCSubDetailedRecord(data);
  1222. return R.ok().put("rows", list);
  1223. }
  1224. /**
  1225. * @description: 检查IPQC是否已提交
  1226. * @author: fengyuan_yang
  1227. * @date: 2023/4/27 8:59
  1228. * @param: [data]
  1229. * @return: com.heai.common.utils.R
  1230. **/
  1231. @PostMapping("/checkIPQCIsSubmit")
  1232. public R checkIPQCIsSubmit(@RequestBody SubDetailValues data){
  1233. Integer flag = qcService.checkIPQCIsSubmit(data);
  1234. return R.ok().put("flag", flag);
  1235. }
  1236. /**
  1237. * @description: 检查IPQC子明细中的实测值是否在规定范围
  1238. * @author: fengyuan_yang
  1239. * @date: 2023/4/27 9:06
  1240. * @param: [data]
  1241. * @return: com.heai.common.utils.R
  1242. **/
  1243. @PostMapping("/checkIPQCSubDetailValue")
  1244. public R checkIPQCSubDetailValue(@RequestBody CheckSubDetailValueVo data){
  1245. Integer flag = qcService.checkIPQCSubDetailValue(data);
  1246. return R.ok().put("flag", flag);
  1247. }
  1248. /**
  1249. * @description: 查询工序列表
  1250. * @author: fengyuan_yang
  1251. * @date: 2023/4/27 15:30
  1252. * @param: [data]
  1253. * @return: com.heai.common.utils.R
  1254. **/
  1255. @PostMapping("/getOperationList")
  1256. public R getOperationList(@RequestBody QcFAIRecordData data){
  1257. List<QcFAIRecordData> list = qcService.getOperationList(data);
  1258. return R.ok().put("rows", list);
  1259. }
  1260. /**
  1261. * @description: 查询机台列表
  1262. * @author: fengyuan_yang
  1263. * @date: 2023/4/27 17:01
  1264. * @param: [data]
  1265. * @return: com.heai.common.utils.R
  1266. **/
  1267. @PostMapping("/getResourceList")
  1268. public R getResourceList(@RequestBody QcFAIRecordData data){
  1269. List<QcFAIRecordData> list = qcService.getResourceList(data);
  1270. return R.ok().put("rows", list);
  1271. }
  1272. /**
  1273. * @description: 查询物料列表
  1274. * @author: fengyuan_yang
  1275. * @date: 2023/4/27 17:36
  1276. * @param: [data]
  1277. * @return: com.heai.common.utils.R
  1278. **/
  1279. @PostMapping("/getPartList")
  1280. public R getPartList(@RequestBody QcFAIRecordData data){
  1281. List<QcFAIRecordData> list = qcService.getPartList(data);
  1282. return R.ok().put("rows", list);
  1283. }
  1284. /**
  1285. * @description: 新增巡检记录
  1286. * @author: fengyuan_yang
  1287. * @date: 2023/4/27 18:19
  1288. * @param: [data]
  1289. * @return: com.heai.common.utils.R
  1290. **/
  1291. @PostMapping("/saveOsInspection")
  1292. public R saveOsInspection(@RequestBody QcFAIRecordData data){
  1293. qcService.saveOsInspection(data);
  1294. return R.ok();
  1295. }
  1296. /**
  1297. * @description: 检查动控是否开启
  1298. * @author: fengyuan_yang
  1299. * @date: 2023/10/18 13:22
  1300. * @param: [data]
  1301. * @return: com.heai.common.utils.R
  1302. **/
  1303. @PostMapping("/queryController")
  1304. public R queryController(@RequestBody SysSceneDynamicControlModelEntity data){
  1305. List<SysSceneDynamicControlModelEntity> list = qcService.queryController(data);
  1306. if (!list.isEmpty()){
  1307. return R.ok().put("rows", list.get(0));
  1308. }
  1309. return R.ok().put("rows", null);
  1310. }
  1311. /**
  1312. * @description: 获取检验模板列表
  1313. * @author: fengyuan_yang
  1314. * @date: 2023/10/18 13:50
  1315. * @param: [data]
  1316. * @return: com.heai.common.utils.R
  1317. **/
  1318. @PostMapping("/queryTemplateList")
  1319. public R queryTemplateList(@RequestBody QcTemplateData data){
  1320. List<QcTemplateData> list = qcService.queryTemplateList(data);
  1321. return R.ok().put("rows", list);
  1322. }
  1323. // ======================= IQC检验API =======================
  1324. /**
  1325. * @description: IQC检验记录查询
  1326. * @author: fengyuan_yang
  1327. * @date: 2023/4/29 13:38
  1328. * @param: [data]
  1329. * @return: com.heai.common.utils.R
  1330. **/
  1331. @PostMapping(value="/qcIQCInspectionSearch")
  1332. public R qcIQCInspectionSearch(@RequestBody QcFAIRecordData data){
  1333. PageUtils page = qcService.qcIQCInspectionSearch(data);
  1334. return R.ok().put("page", page);
  1335. }
  1336. /**
  1337. * @description: iqc检验记录查询
  1338. * @author: fengyuan_yang
  1339. * @date: 2023/5/4 11:46
  1340. * @param: [data]
  1341. * @return: com.heai.common.utils.R
  1342. **/
  1343. @PostMapping("/iqcDetailSearch")
  1344. public R iqcDetailSearch(@RequestBody QcFAIRecordData data){
  1345. List<QcFAIRecordData> list = qcService.iqcDetailSearch(data);
  1346. return R.ok().put("rows", list);
  1347. }
  1348. /**
  1349. * @description: 查询IQC子明细记录
  1350. * @author: fengyuan_yang
  1351. * @date: 2023/5/4 13:11
  1352. * @param: [data]
  1353. * @return: com.heai.common.utils.R
  1354. **/
  1355. @PostMapping("/selectIQCSubDetailedRecord")
  1356. public R selectIQCSubDetailedRecord(@RequestBody SubDetailValues data){
  1357. List<SubDetailValues> list = qcService.selectIQCSubDetailedRecord(data);
  1358. return R.ok().put("rows", list);
  1359. }
  1360. /**
  1361. * @description: 检查子明细中的实测值是否在规定范围
  1362. * @author: fengyuan_yang
  1363. * @date: 2023/5/4 13:17
  1364. * @param: [data]
  1365. * @return: com.heai.common.utils.R
  1366. **/
  1367. @PostMapping("/checkIQCSubDetailValue")
  1368. public R checkIQCSubDetailValue(@RequestBody CheckSubDetailValueVo data){
  1369. Integer flag = qcService.checkIQCSubDetailValue(data);
  1370. return R.ok().put("flag", flag);
  1371. }
  1372. /**
  1373. * @description: 新增明细信息
  1374. * @author: fengyuan_yang
  1375. * @date: 2023/5/4 13:27
  1376. * @param: [data]
  1377. * @return: com.heai.common.utils.R
  1378. **/
  1379. @PostMapping("/saveIQCDetailedRecord")
  1380. public R saveIQCDetailedRecord(@RequestBody QcFAIRecordData data){
  1381. qcService.saveIQCDetailedRecord(data);
  1382. return R.ok();
  1383. }
  1384. /**
  1385. * @description: 检查是否已提交
  1386. * @author: fengyuan_yang
  1387. * @date: 2023/5/4 13:59
  1388. * @param: [data]
  1389. * @return: com.heai.common.utils.R
  1390. **/
  1391. @PostMapping("/checkIQCIsSubmit")
  1392. public R checkIQCIsSubmit(@RequestBody SubDetailValues data){
  1393. Integer flag = qcService.checkIQCIsSubmit(data);
  1394. return R.ok().put("flag", flag);
  1395. }
  1396. /**
  1397. * @description: 新增子明细信息
  1398. * @author: fengyuan_yang
  1399. * @date: 2023/5/4 15:54
  1400. * @param: [data]
  1401. * @return: com.heai.common.utils.R
  1402. **/
  1403. @PostMapping("/saveIQCSubDetailed")
  1404. public R saveIQCSubDetailed(@RequestBody QcSubDetailInformationData data){
  1405. Integer count = qcService.saveIQCSubDetailed(data);
  1406. return R.ok().put("count", count);
  1407. }
  1408. /**
  1409. * @description: 审核
  1410. * @author: fengyuan_yang
  1411. * @date: 2023/5/4 17:31
  1412. * @param: [data]
  1413. * @return: com.heai.common.utils.R
  1414. **/
  1415. @PostMapping("/saveIQCSubmitResult")
  1416. public R saveIQCSubmitResult(@RequestBody QcFAIRecordData data){
  1417. qcService.saveIQCSubmitResult(data);
  1418. return R.ok();
  1419. }
  1420. /**
  1421. * 取消审核
  1422. * @param data
  1423. * @return
  1424. */
  1425. @PostMapping("/cancelApproval")
  1426. public R cancelApproval(@RequestBody QcFAIRecordData data){
  1427. qcService.cancelApproval(data);
  1428. return R.ok();
  1429. }
  1430. /**
  1431. * 取消审核
  1432. * @param data
  1433. * @return
  1434. */
  1435. @PostMapping("/cancelApproval2")
  1436. public R cancelApproval2(@RequestBody QcFAIRecordData data){
  1437. qcService.cancelApproval2(data);
  1438. return R.ok();
  1439. }
  1440. /**
  1441. * @description: 删除检验记录
  1442. * @author: fengyuan_yang
  1443. * @date: 2023/5/4 17:38
  1444. * @param: [data]
  1445. * @return: com.heai.common.utils.R
  1446. **/
  1447. @PostMapping("/iqcRecordDelete")
  1448. public R iqcRecordDelete(@RequestBody QcFAIRecordData data){
  1449. qcService.iqcRecordDelete(data);
  1450. return R.ok();
  1451. }
  1452. /**
  1453. * 任务重载
  1454. * @param data
  1455. * @return
  1456. */
  1457. @PostMapping("/iqcRecordOverLoad")
  1458. public R iqcRecordOverLoad(@RequestBody QcFAIRecordData data){
  1459. qcService.iqcRecordOverLoad(data);
  1460. return R.ok();
  1461. }
  1462. // ======================= SQC检验API =======================
  1463. @PostMapping(value="/qcSQCInspectionSearch")
  1464. public R qcSQCInspectionSearch(@RequestBody QcFAIRecordData data){
  1465. PageUtils page = qcService.qcSQCInspectionSearch(data);
  1466. return R.ok().put("page", page);
  1467. }
  1468. @PostMapping("/sqcDetailSearch")
  1469. public R sqcDetailSearch(@RequestBody QcFAIRecordData data){
  1470. List<QcFAIRecordData> list = qcService.sqcDetailSearch(data);
  1471. return R.ok().put("rows", list);
  1472. }
  1473. @PostMapping("/selectSQCSubDetailedRecord")
  1474. public R selectSQCSubDetailedRecord(@RequestBody SubDetailValues data){
  1475. List<SubDetailValues> list = qcService.selectSQCSubDetailedRecord(data);
  1476. return R.ok().put("rows", list);
  1477. }
  1478. @PostMapping("/checkSQCSubDetailValue")
  1479. public R checkSQCSubDetailValue(@RequestBody CheckSubDetailValueVo data){
  1480. Integer flag = qcService.checkSQCSubDetailValue(data);
  1481. return R.ok().put("flag", flag);
  1482. }
  1483. @PostMapping("/saveSQCDetailedRecord")
  1484. public R saveSQCDetailedRecord(@RequestBody QcFAIRecordData data){
  1485. qcService.saveSQCDetailedRecord(data);
  1486. return R.ok();
  1487. }
  1488. @PostMapping("/checkSQCIsSubmit")
  1489. public R checkSQCIsSubmit(@RequestBody SubDetailValues data){
  1490. Integer flag = qcService.checkSQCIsSubmit(data);
  1491. return R.ok().put("flag", flag);
  1492. }
  1493. @PostMapping("/saveSQCSubDetailed")
  1494. public R saveSQCSubDetailed(@RequestBody QcSubDetailInformationData data){
  1495. Integer count = qcService.saveSQCSubDetailed(data);
  1496. return R.ok().put("count", count);
  1497. }
  1498. @PostMapping("/saveSQCSubmitResult")
  1499. public R saveSQCSubmitResult(@RequestBody QcFAIRecordData data){
  1500. qcService.saveSQCSubmitResult(data);
  1501. return R.ok();
  1502. }
  1503. @PostMapping("/sqcRecordDelete")
  1504. public R sqcRecordDelete(@RequestBody QcFAIRecordData data){
  1505. qcService.sqcRecordDelete(data);
  1506. return R.ok();
  1507. }
  1508. @PostMapping("/sqcRecordOverLoad")
  1509. public R sqcRecordOverLoad(@RequestBody QcFAIRecordData data){
  1510. qcService.sqcRecordOverLoad(data);
  1511. return R.ok();
  1512. }
  1513. /**
  1514. * @description: 查询文件ID
  1515. * @author: fengyuan_yang
  1516. * @date: 2023/7/5 9:18
  1517. * @param: [data]
  1518. * @return: com.heai.common.utils.R
  1519. **/
  1520. @PostMapping("/queryFileId")
  1521. public R queryFileId(@RequestBody SysOssEntity data){
  1522. SysOssEntity sysOss = qcService.queryFileId(data);
  1523. return R.ok().put("data",sysOss);
  1524. }
  1525. /**
  1526. * @description: 获取工序列表
  1527. * @author: fengyuan_yang
  1528. * @date: 2023/7/7 15:39
  1529. * @param: [data]
  1530. * @return: com.heai.common.utils.R
  1531. **/
  1532. @PostMapping("/getOperationDescList")
  1533. public R getOperationDescList(@RequestBody QcPartAttributeData data){
  1534. List<QcPartAttributeData> list = qcService.getOperationDescList(data);
  1535. return R.ok().put("rows", list);
  1536. }
  1537. /**
  1538. * @description: 获取供应商列表
  1539. * @author: fengyuan_yang
  1540. * @date: 2023/7/9 22:32
  1541. * @param: [data]
  1542. * @return: com.heai.common.utils.R
  1543. **/
  1544. @PostMapping("/getManufacturerList")
  1545. public R getManufacturerList(@RequestBody QcPartAttributeData data){
  1546. List<QcPartAttributeData> list = qcService.getManufacturerList(data);
  1547. return R.ok().put("rows", list);
  1548. }
  1549. /**
  1550. * @description: 获取所有机台
  1551. * @author: fengyuan_yang
  1552. * @date: 2023/9/15 11:36
  1553. * @param: [data]
  1554. * @return: com.heai.common.utils.R
  1555. **/
  1556. @PostMapping("/getAllResourceList")
  1557. public R getAllResourceList(@RequestBody QcFAIRecordData data){
  1558. List<QcFAIRecordData> list = qcService.getAllResourceList(data);
  1559. return R.ok().put("rows", list);
  1560. }
  1561. /**
  1562. * @description: 获取工单列表
  1563. * @author: fengyuan_yang
  1564. * @date: 2023/9/15 15:59
  1565. * @param: [data]
  1566. * @return: com.heai.common.utils.R
  1567. **/
  1568. @PostMapping("/getOrderNoList")
  1569. public R getOrderNoList(@RequestBody QcFAIRecordData data){
  1570. // PageUtils page = qcService.getOrderNoList(data);
  1571. // return R.ok().put("page", page);
  1572. List<QcFAIRecordData> list = qcService.getOrderNoList(data);
  1573. return R.ok().put("rows", list);
  1574. }
  1575. /**
  1576. * @description: 获取物料其它信息
  1577. * @author: fengyuan_yang
  1578. * @date: 2023/10/20 15:19
  1579. * @param: [data]
  1580. * @return: com.heai.common.utils.R
  1581. **/
  1582. @PostMapping("/getPartInformation")
  1583. public R getPartInformation(@RequestBody QcFAIRecordData data){
  1584. List<QcFAIRecordData> list = qcService.getPartInformation(data);
  1585. return R.ok().put("rows", list);
  1586. }
  1587. /**
  1588. * @description: 获取特殊工序列表
  1589. * @author: fengyuan_yang
  1590. * @date: 2023/10/20 15:30
  1591. * @param: [data]
  1592. * @return: com.heai.common.utils.R
  1593. **/
  1594. @PostMapping("/getSpecialOperationList")
  1595. public R getSpecialOperationList(@RequestBody QcFAIRecordData data){
  1596. List<QcFAIRecordData> list = qcService.getSpecialOperationList(data);
  1597. return R.ok().put("rows", list);
  1598. }
  1599. /**
  1600. * @description: 获取处置措施列表
  1601. * @author: fengyuan_yang
  1602. * @date: 2023/10/23 13:14
  1603. * @param: []
  1604. * @return: com.heai.common.utils.R
  1605. **/
  1606. @PostMapping(value="/disposalMeasuresSearch")
  1607. public R disposalMeasuresSearch(@RequestBody QcFAIRecordData data){
  1608. List<QcFAIRecordData> list = qcService.disposalMeasuresSearch(data);
  1609. return R.ok().put("rows", list);
  1610. }
  1611. /**
  1612. * @description: 查询文件路径
  1613. * @author: fengyuan_yang
  1614. * @date: 2023/11/1 16:48
  1615. * @param: [data]
  1616. * @return: com.heai.common.utils.R
  1617. **/
  1618. @PostMapping("/searchItemFileUrl")
  1619. public R searchItemFileUrl(@RequestBody QcFAIRecordData data){
  1620. List<SysOssEntity> list = qcService.searchItemFileUrl(data);
  1621. return R.ok().put("rows", list);
  1622. }
  1623. /**
  1624. * @description: 删除图片
  1625. * @author: fengyuan_yang
  1626. * @date: 2023/11/1 16:53
  1627. * @param: [data]
  1628. * @return: com.heai.common.utils.R
  1629. **/
  1630. @PostMapping("/imageDelete")
  1631. public R imageDelete(@RequestBody SysOssEntity data){
  1632. qcService.imageDelete(data);
  1633. return R.ok();
  1634. }
  1635. /**
  1636. * @description: 模糊查询标签号
  1637. * @author: fengyuan_yang
  1638. * @date: 2023/11/3 16:48
  1639. * @param: [data]
  1640. * @return: com.heai.common.utils.R
  1641. **/
  1642. @PostMapping("/getRollNo")
  1643. public R getRollNo(@RequestBody QcFAIRecordData data){
  1644. List<QcFAIRecordData> list = qcService.getRollNo(data);
  1645. return R.ok().put("rows", list);
  1646. }
  1647. /**
  1648. * @description: 标签号回车事件
  1649. * @author: fengyuan_yang
  1650. * @date: 2023/11/7 10:22
  1651. * @param: [data]
  1652. * @return: com.heai.common.utils.R
  1653. **/
  1654. @PostMapping("/rollNoEnter")
  1655. public R rollNoEnter(@RequestBody QcFAIRecordData data){
  1656. List<QcFAIRecordData> list = qcService.rollNoEnter(data);
  1657. return R.ok().put("rows", list);
  1658. }
  1659. /**
  1660. * @description: 查询物料集合
  1661. * @author: fengyuan_yang
  1662. * @date: 2023/11/7 14:48
  1663. * @param: [data]
  1664. * @return: com.heai.common.utils.R
  1665. **/
  1666. @PostMapping("/queryPartList")
  1667. public R queryPartList(@RequestBody QcFAIRecordData data){
  1668. List<QcFAIRecordData> list = qcService.queryPartList(data);
  1669. return R.ok().put("rows", list);
  1670. }
  1671. /**
  1672. * @description: 查询单位列表
  1673. * @author: fengyuan_yang
  1674. * @date: 2023/11/8 9:27
  1675. * @param: [data]
  1676. * @return: com.heai.common.utils.R
  1677. **/
  1678. @PostMapping(value="/umSearch")
  1679. public R umSearch(@RequestBody QcFAIRecordData data){
  1680. List<QcFAIRecordData> list = qcService.umSearch(data);
  1681. return R.ok().put("rows", list);
  1682. }
  1683. /**
  1684. * @description: 检验单子明细导入
  1685. * @author: fengyuan_yang
  1686. * @date: 2023/11/12 12:13
  1687. * @param: [file, data]
  1688. * @return: com.heai.common.utils.R
  1689. **/
  1690. @PostMapping("/subDetailUpload")
  1691. public R subDetailUpload(@RequestParam(value = "file") MultipartFile file, @ModelAttribute GetParamInData data){
  1692. Map<String, Integer> countMap = qcService.subDetailUpload(file, data);
  1693. return R.ok().put("countMap", countMap);
  1694. }
  1695. /**
  1696. * 获取检验方法列表
  1697. * @param data
  1698. * @return
  1699. */
  1700. @PostMapping("/queryMethodList")
  1701. public R queryMethodList(@RequestBody QcMethodData data) {
  1702. List<QcMethodData> list = qcService.queryMethodList(data);
  1703. return R.ok().put("rows", list);
  1704. }
  1705. /**
  1706. * 文件上传
  1707. * @param list
  1708. * @param inData
  1709. * @return
  1710. */
  1711. @PostMapping("/upload")
  1712. public R upload(@RequestParam("file") MultipartFile[] list, @ModelAttribute GetParamInData inData){
  1713. List<SysOssEntity> ossEntity = qcService.upload(list, inData);
  1714. return R.ok().put("ossEntity", ossEntity);
  1715. }
  1716. /**
  1717. * 获取用户bu
  1718. * @param data
  1719. * @return
  1720. */
  1721. @PostMapping("/getSiteAndBuByUserName")
  1722. public R getSiteAndBuByUserName(@RequestBody BuData data){
  1723. List<BuData> list = eamService.getSiteAndBuByUserName(data);
  1724. return R.ok().put("rows", list);
  1725. }
  1726. /**
  1727. * 获取用户bu
  1728. * @param data
  1729. * @return
  1730. */
  1731. @PostMapping("/getSiteAndBuByUserName2")
  1732. public R getSiteAndBuByUserName2(@RequestBody BuData data){
  1733. List<BuData> list = eamService.getSiteAndBuByUserName2(data);
  1734. return R.ok().put("rows", list);
  1735. }
  1736. /**
  1737. * 获取派工单号
  1738. * @param data
  1739. * @return
  1740. */
  1741. @PostMapping("/searchSeqInfo")
  1742. public R searchSeqInfo(@RequestBody QcFAIRecordData data){
  1743. List<QcFAIRecordData> list = qcService.searchSeqInfo(data);
  1744. return R.ok().put("rows", list);
  1745. }
  1746. /**
  1747. * 获取物料信息
  1748. * @param data
  1749. * @return
  1750. */
  1751. @PostMapping("/searchPartInfo")
  1752. public R searchPartInfo(@RequestBody QcFAIRecordData data){
  1753. List<QcFAIRecordData> list = qcService.searchPartInfo(data);
  1754. return R.ok().put("rows", list);
  1755. }
  1756. /**
  1757. * 获取采购类型
  1758. * @return
  1759. */
  1760. @PostMapping("/orderTypeSearch")
  1761. public R orderTypeSearch(){
  1762. List<QcFAIRecordData> list = qcService.orderTypeSearch();
  1763. return R.ok().put("rows", list);
  1764. }
  1765. /**
  1766. * 开始检验
  1767. * @param data
  1768. * @return
  1769. */
  1770. @PostMapping("/actionIQCInspection")
  1771. public R actionIQCInspection(@RequestBody EamObjectInData data){
  1772. qcService.actionIQCInspection(data);
  1773. return R.ok();
  1774. }
  1775. @PostMapping("/actionSQCInspection")
  1776. public R actionSQCInspection(@RequestBody EamObjectInData data){
  1777. qcService.actionSQCInspection(data);
  1778. return R.ok();
  1779. }
  1780. /**
  1781. * 开始检验
  1782. * @param data
  1783. * @return
  1784. */
  1785. @PostMapping("/actionFAIInspection")
  1786. public R actionFAIInspection(@RequestBody EamObjectInData data){
  1787. qcService.actionFAIInspection(data);
  1788. return R.ok();
  1789. }
  1790. /**
  1791. * 开始检验
  1792. * @param data
  1793. * @return
  1794. */
  1795. @PostMapping("/actionIPQCInspection")
  1796. public R actionIPQCInspection(@RequestBody EamObjectInData data){
  1797. qcService.actionIPQCInspection(data);
  1798. return R.ok();
  1799. }
  1800. /**
  1801. * 开始检验
  1802. * @param data
  1803. * @return
  1804. */
  1805. @PostMapping("/actionFQCInspection")
  1806. public R actionFQCInspection(@RequestBody EamObjectInData data){
  1807. qcService.actionFQCInspection(data);
  1808. return R.ok();
  1809. }
  1810. /**
  1811. * 数据采集
  1812. * @param data
  1813. * @return
  1814. */
  1815. @PostMapping("/dataAcquisition")
  1816. public R dataAcquisition(@RequestBody QcFAIRecordData data){
  1817. Map<String, Integer> countMap = qcService.dataAcquisition(data);
  1818. return R.ok().put("rows", countMap);
  1819. }
  1820. /**
  1821. * 获取采集条件路径
  1822. * @return
  1823. */
  1824. @PostMapping("/getEquipmentNoList")
  1825. public R getEquipmentNoList(@RequestBody EquipmentFolderLocationData data) {
  1826. List<EquipmentFolderLocationData> list = qcService.getEquipmentNoList(data);
  1827. return R.ok().put("rows", list);
  1828. }
  1829. /**
  1830. * 获取责任人列表
  1831. * @param data
  1832. * @return
  1833. */
  1834. @PostMapping("/getResponsibleOperatorList")
  1835. public R getResponsibleOperatorList(@RequestBody EamAdminData data){
  1836. List<EamAdminData> list = qcService.getResponsibleOperatorList(data);
  1837. return R.ok().put("rows", list);
  1838. }
  1839. /**
  1840. * 获取采集数据内容
  1841. * @return
  1842. */
  1843. @PostMapping("/getDataContentList")
  1844. public R getDataContentList(@RequestBody QcCollectionDataContentData data) {
  1845. List<QcCollectionDataContentData> list = qcService.getDataContentList(data);
  1846. return R.ok().put("rows", list);
  1847. }
  1848. /**
  1849. * 查询设备列表
  1850. * @param data
  1851. * @return
  1852. */
  1853. @PostMapping("getObjectList")
  1854. public R getObjectList(@RequestBody EamObjectInData data) {
  1855. // 获取当前项目不包含的设备
  1856. List<EamObjectInData> row1 = qcService.getObjectList1(data);
  1857. // 获取当前项目所包含的设备
  1858. List<EamObjectInData> row2 = qcService.getObjectList2(data);
  1859. return R.ok().put("row1", row1).put("row2", row2);
  1860. }
  1861. /**
  1862. * 根据条件查询可选设备
  1863. * @param data
  1864. * @return
  1865. */
  1866. @PostMapping("getObjectListBy")
  1867. public R getObjectListBy(@RequestBody EamObjectInData data) {
  1868. List<EamObjectInData> rows = qcService.getObjectListBy(data);
  1869. return R.ok().put("rows", rows);
  1870. }
  1871. /**
  1872. * 新增项目设备
  1873. * @param data
  1874. * @return
  1875. */
  1876. @PostMapping("/addItemObject")
  1877. public R addItemObject(@RequestBody EamObjectInData data){
  1878. qcService.addItemObject(data);
  1879. return R.ok();
  1880. }
  1881. /**
  1882. * 删除项目设备
  1883. * @param data
  1884. * @return
  1885. */
  1886. @PostMapping("/deleteItemObject")
  1887. public R deleteItemObject(@RequestBody EamObjectInData data){
  1888. qcService.deleteItemObject(data);
  1889. return R.ok();
  1890. }
  1891. /**
  1892. * 删除项目设备
  1893. * @param data
  1894. * @return
  1895. */
  1896. @PostMapping("/updateItemObject")
  1897. public R updateItemObject(@RequestBody EamObjectInData data){
  1898. qcService.updateItemObject(data);
  1899. return R.ok();
  1900. }
  1901. /**
  1902. * 查询项目设备
  1903. * @param data
  1904. * @return
  1905. */
  1906. @PostMapping("/getIQCItemObjectList")
  1907. public R getIQCItemObjectList(@RequestBody EamObjectInData data){
  1908. List<EamObjectInData> list = qcService.getIQCItemObjectList(data);
  1909. return R.ok().put("rows", list);
  1910. }
  1911. @PostMapping("/getSQCItemObjectList")
  1912. public R getSQCItemObjectList(@RequestBody EamObjectInData data){
  1913. List<EamObjectInData> list = qcService.getSQCItemObjectList(data);
  1914. return R.ok().put("rows", list);
  1915. }
  1916. /**
  1917. * 查询项目设备
  1918. * @param data
  1919. * @return
  1920. */
  1921. @PostMapping("/getFAIItemObjectList")
  1922. public R getFAIItemObjectList(@RequestBody EamObjectInData data){
  1923. List<EamObjectInData> list = qcService.getFAIItemObjectList(data);
  1924. return R.ok().put("rows", list);
  1925. }
  1926. /**
  1927. * 查询项目设备
  1928. * @param data
  1929. * @return
  1930. */
  1931. @PostMapping("/getFQCItemObjectList")
  1932. public R getFQCItemObjectList(@RequestBody EamObjectInData data){
  1933. List<EamObjectInData> list = qcService.getFQCItemObjectList(data);
  1934. return R.ok().put("rows", list);
  1935. }
  1936. /**
  1937. * 查询项目设备
  1938. * @param data
  1939. * @return
  1940. */
  1941. @PostMapping("/getIPQCItemObjectList")
  1942. public R getIPQCItemObjectList(@RequestBody EamObjectInData data){
  1943. List<EamObjectInData> list = qcService.getIPQCItemObjectList(data);
  1944. return R.ok().put("rows", list);
  1945. }
  1946. /**
  1947. * 获取检验标准
  1948. * @param data
  1949. * @return
  1950. */
  1951. @PostMapping("/getInspectionStandards")
  1952. public R getInspectionStandards(@RequestBody QcInspectionStandardData data){
  1953. List<QcInspectionStandardData> list = qcService.getInspectionStandards(data);
  1954. return R.ok().put("rows", list);
  1955. }
  1956. /**
  1957. * 新增检验标准
  1958. * @param data
  1959. * @return
  1960. */
  1961. @PostMapping("/saveInspectionStandard")
  1962. public R saveInspectionStandard(@RequestBody QcInspectionStandardData data){
  1963. qcService.saveInspectionStandard(data);
  1964. return R.ok();
  1965. }
  1966. /**
  1967. * 根据项目数据采集
  1968. * @param data
  1969. * @return
  1970. */
  1971. @PostMapping("/dataAcquisitionByItem")
  1972. public R dataAcquisitionByItem(@RequestBody QcFAIRecordData data){
  1973. Map<String, Integer> countMap = qcService.dataAcquisitionByItem(data);
  1974. return R.ok().put("rows", countMap);
  1975. }
  1976. /**
  1977. * @Description 属性上移
  1978. * @Title goUpItemForBM
  1979. * @param inData
  1980. * @author rq
  1981. * @date 2023/11/28 16:20
  1982. * @return R
  1983. * @throw
  1984. */
  1985. @PostMapping("/goUpItemQC")
  1986. @ResponseBody
  1987. public R goUpItemQC(@RequestBody QcTemplateData inData){
  1988. qcService.goUpItem(inData);
  1989. return R.ok();
  1990. }
  1991. /**
  1992. * @Description 属性下移
  1993. * @Title goDownForBM
  1994. * @param inData
  1995. * @author rq
  1996. * @date 2023/11/28 16:20
  1997. * @return R
  1998. * @throw
  1999. */
  2000. @PostMapping("/goDownItemQC")
  2001. @ResponseBody
  2002. public R goDownItemQC(@RequestBody QcTemplateData inData){
  2003. qcService.goDownItem(inData);
  2004. return R.ok();
  2005. }
  2006. /**
  2007. * @Description 查询 外采设备维护 数据
  2008. * @Title queryEquipmentFolderLocationList
  2009. * @param inData
  2010. * @author zhb
  2011. * @date 2025/8/11
  2012. * @return R
  2013. * @throw
  2014. */
  2015. @PostMapping("/queryEquipmentFolderLocationList")
  2016. @ResponseBody
  2017. public R queryEquipmentFolderLocationList(@RequestBody QCEquipmentFolderLocation inData){
  2018. List<QCEquipmentFolderLocation> list = qcService.queryEquipmentFolderLocationList(inData);
  2019. return R.ok().put("rows", list).put("total", list.size());
  2020. }
  2021. /**
  2022. * @Description 删除外采设备维护 数据
  2023. * @Title queryEquipmentFolderLocationList
  2024. * @param inData
  2025. * @author zhb
  2026. * @date 2025/8/11
  2027. * @return R
  2028. * @throw
  2029. */
  2030. @PostMapping("/deleteEquipmentFolderLocationList")
  2031. @ResponseBody
  2032. public R deleteEquipmentFolderLocationList(@RequestBody List<QCEquipmentFolderLocation> inData){
  2033. qcService.deleteEquipmentFolderLocationList(inData);
  2034. return R.ok();
  2035. }
  2036. /**
  2037. * @Description 获取外采设备维护 采集方式列表
  2038. * @Title getSuffixList
  2039. * @author zhb
  2040. * @date 2025/8/12
  2041. * @return R
  2042. * @throw
  2043. */
  2044. @PostMapping("/getSuffixList")
  2045. @ResponseBody
  2046. public R getSuffixList(){
  2047. List<String> list = qcService.getSuffixList();
  2048. return R.ok().put("rows", list);
  2049. }
  2050. /**
  2051. * @Description 保存外采设备维护 数据
  2052. * @Title queryEquipmentFolderLocationList
  2053. * @param inData
  2054. * @author zhb
  2055. * @date 2025/8/11
  2056. * @return R
  2057. * @throw
  2058. */
  2059. @PostMapping("/saveEquipmentFolderLocationList")
  2060. @ResponseBody
  2061. public R saveEquipmentFolderLocationList(@RequestBody QCEquipmentFolderLocation inData){
  2062. R r = qcService.saveEquipmentFolderLocationList(inData);
  2063. return r;
  2064. }
  2065. }