From cc44920da3d40b8248b67560026e891afdd1a6ab Mon Sep 17 00:00:00 2001 From: lyh <925863403@qq.com> Date: 星期四, 08 五月 2025 17:57:14 +0800 Subject: [PATCH] 1.查询可以被引用的部件接口开发完成 2.借用部件(可批量) 开发完成 3.修改原有新增、修改部件接口 完成 4.修改原有删除文档与导入文档接口 完成 5.修改工作流问题 --- lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/controller/DocInfoController.java | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-) diff --git a/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/controller/DocInfoController.java b/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/controller/DocInfoController.java index 34d77c7..4594a87 100644 --- a/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/controller/DocInfoController.java +++ b/lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/controller/DocInfoController.java @@ -1,9 +1,9 @@ package org.jeecg.modules.dnc.controller; -import cn.hutool.core.util.StrUtil; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import lombok.extern.slf4j.Slf4j; +import org.jeecg.common.api.vo.Result; import org.jeecg.common.aspect.annotation.AutoLog; import org.jeecg.common.system.base.controller.JeecgController; import org.jeecg.modules.dnc.entity.DocFile; @@ -12,7 +12,6 @@ import org.jeecg.modules.dnc.request.DocInfoUploadRequest; import org.jeecg.modules.dnc.response.CommonCode; import org.jeecg.modules.dnc.response.QueryListResponseResult; -import org.jeecg.modules.dnc.response.QueryPageResponseResult; import org.jeecg.modules.dnc.response.ResponseResult; import org.jeecg.modules.dnc.service.IDocInfoService; import org.jeecg.modules.dnc.utils.ValidateUtil; @@ -56,9 +55,9 @@ @AutoLog(value = "鏂囨。琛�-鍒犻櫎鏂囨。淇℃伅") @ApiOperation(value = "鏂囨。琛�-鍒犻櫎鏂囨。淇℃伅", notes = "鏂囨。琛�-鍒犻櫎鏂囨。淇℃伅") - @DeleteMapping("/delete") - public ResponseResult deleteDocInfo(@RequestParam("id") String id) { - boolean b = docInfoService.deleteDocInfo(id); + @DeleteMapping("/delete/{id}/{attrType}/{attrId}") + public ResponseResult deleteDocInfo(@PathVariable("id") String id, @PathVariable("attrType") String attrType, @PathVariable("attrId") String attrId) { + boolean b = docInfoService.deleteDocInfo(id,attrType,attrId); if(!b) return new ResponseResult(CommonCode.FAIL); return new ResponseResult(CommonCode.SUCCESS); @@ -124,15 +123,15 @@ @AutoLog(value = "鏂囨。琛�-鍒嗛〉鏌ヨ鎺ュ彛") @ApiOperation(value = "鏂囨。琛�-鍒嗛〉鏌ヨ鎺ュ彛", notes = "鏂囨。琛�-鍒嗛〉鏌ヨ鎺ュ彛") @GetMapping("/find/page/{page}/{size}") - public QueryPageResponseResult<DocInfo> findPageList(@PathVariable("page") int page, @PathVariable("size") int size, DocInfoQueryRequest docQuery) { + public Result<?> findPageList(@PathVariable("page") int page, @PathVariable("size") int size, DocInfoQueryRequest docQuery) { return docInfoService.findPageList(page, size, docQuery); } @AutoLog(value = "鏂囨。琛�-鏌ヨ璁惧鍙戦�佺洰褰曠殑鏂囨。鐘舵��") @ApiOperation(value = "鏂囨。琛�-鏌ヨ璁惧鍙戦�佺洰褰曠殑鏂囨。鐘舵��", notes = "鏂囨。琛�-鏌ヨ璁惧鍙戦�佺洰褰曠殑鏂囨。鐘舵��") @GetMapping("/find/page/device/{page}/{size}") - public QueryPageResponseResult<DocInfo> findPageListByDevice(@PathVariable("page") int page, @PathVariable("size") int size, DocInfoQueryRequest docQuery) { - return docInfoService.findPageListByDevice(page, size, docQuery); + public Result<?> findPageListByDevice(@PathVariable("page") int page, @PathVariable("size") int size, DocInfoQueryRequest docQuery) { + return Result.ok(docInfoService.findPageListByDevice(page, size, docQuery)); } @AutoLog(value = "鏂囨。琛�-鏂囨。鏂囦欢棰勮") @@ -175,15 +174,16 @@ @AutoLog(value = "鏂囦欢琛�-鏌ヨ鍙寚娲剧殑鏂囨。淇℃伅鍒楄〃") @ApiOperation(value = "鏂囦欢琛�-鏌ヨ鍙寚娲剧殑鏂囨。淇℃伅鍒楄〃", notes = "鏂囦欢琛�-鏌ヨ鍙寚娲剧殑鏂囨。淇℃伅鍒楄〃") @GetMapping("/find/list") - public QueryListResponseResult<DocInfo> findList(DocInfoQueryRequest docQuery) { - return docInfoService.findList(docQuery); + public Result<?> findList(DocInfoQueryRequest docQuery) { + List<DocInfo> docInfoList=docInfoService.findList(docQuery); + return Result.ok(docInfoList); } @AutoLog(value = "鏂囦欢琛�-鎵归噺鍒犻櫎鏂囨。鎺ュ彛") @ApiOperation(value = "鏂囦欢琛�-鎵归噺鍒犻櫎鏂囨。鎺ュ彛", notes = "鏂囦欢琛�-鎵归噺鍒犻櫎鏂囨。鎺ュ彛") - @PostMapping("/batch/remove") - public ResponseResult batchRemoveDocInfo(@RequestBody String[] docIds) { - boolean b = docInfoService.batchRemoveDocInfo(docIds); + @PostMapping("/batch/remove/{docIds}/{attrType}/{attrId}") + public ResponseResult batchRemoveDocInfo(@PathVariable("docIds") String[] docIds, @PathVariable("attrType") String attrType, @PathVariable("attrId") String attrId) { + boolean b = docInfoService.batchRemoveDocInfo(docIds,attrType,attrId); if(!b) return new ResponseResult(CommonCode.FAIL); return new ResponseResult(CommonCode.SUCCESS); -- Gitblit v1.9.3