From 438b6be5ea9ed484b50a45a0f210b80180473491 Mon Sep 17 00:00:00 2001 From: lyh <925863403@qq.com> Date: 星期二, 11 二月 2025 11:51:45 +0800 Subject: [PATCH] dnc与mdc部门进行整合 使用Mdc部门进行处理 修改所属部门为所属车间 修改yml文件数据库地址 --- lxzn-module-dnc/src/main/java/org/jeecg/modules/activiti/controller/ActivitiDefinitionController.java | 33 ++++++++++++++++++--------------- 1 files changed, 18 insertions(+), 15 deletions(-) diff --git a/lxzn-module-dnc/src/main/java/org/jeecg/modules/activiti/controller/ActivitiDefinitionController.java b/lxzn-module-dnc/src/main/java/org/jeecg/modules/activiti/controller/ActivitiDefinitionController.java index 5699c5a..ea9b77f 100644 --- a/lxzn-module-dnc/src/main/java/org/jeecg/modules/activiti/controller/ActivitiDefinitionController.java +++ b/lxzn-module-dnc/src/main/java/org/jeecg/modules/activiti/controller/ActivitiDefinitionController.java @@ -3,6 +3,7 @@ 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.modules.activiti.entity.ActivitiDefinition; import org.jeecg.modules.activiti.request.ActivitiDefinitionRequest; @@ -14,15 +15,15 @@ import org.springframework.web.bind.annotation.*; @Slf4j -@Api(tags = "DNC娴佺▼閰嶇疆") +@Api(tags = "DNC鎸囨淳璁惧娴佺▼閰嶇疆") @RestController @RequestMapping("/nc/definition") public class ActivitiDefinitionController { @Autowired private IActivitiDefinitionService definitionService; - @AutoLog(value = "DNC娴佺▼閰嶇疆-娣诲姞閰嶇疆") - @ApiOperation(value = "DNC娴佺▼閰嶇疆-娣诲姞閰嶇疆", notes = "DNC娴佺▼閰嶇疆-娣诲姞閰嶇疆") + @AutoLog(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-娣诲姞閰嶇疆") + @ApiOperation(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-娣诲姞閰嶇疆", notes = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-娣诲姞閰嶇疆") @PostMapping("/add") public ResponseResult addDefinition(@RequestBody ActivitiDefinition definition) { boolean b = definitionService.addDefinition(definition); @@ -31,18 +32,18 @@ return new ResponseResult(CommonCode.FAIL); } - @AutoLog(value = "DNC娴佺▼閰嶇疆-淇敼閰嶇疆") - @ApiOperation(value = "DNC娴佺▼閰嶇疆-淇敼閰嶇疆", notes = "DNC娴佺▼閰嶇疆-淇敼閰嶇疆") - @PutMapping("/edit/{id}") - public ResponseResult editDefinition(@PathVariable("id") String id, @RequestBody ActivitiDefinition definition) { - boolean b = definitionService.editDefinition(id, definition); + @AutoLog(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-淇敼閰嶇疆") + @ApiOperation(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-淇敼閰嶇疆", notes = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-淇敼閰嶇疆") + @PutMapping("/edit") + public ResponseResult editDefinition( @RequestBody ActivitiDefinition definition) { + boolean b = definitionService.updateById(definition); if(b) return new ResponseResult(CommonCode.SUCCESS); return new ResponseResult(CommonCode.FAIL); } - @AutoLog(value = "DNC娴佺▼閰嶇疆-鍒犻櫎閰嶇疆") - @ApiOperation(value = "DNC娴佺▼閰嶇疆-鍒犻櫎閰嶇疆", notes = "DNC娴佺▼閰嶇疆-鍒犻櫎閰嶇疆") + @AutoLog(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-鍒犻櫎閰嶇疆") + @ApiOperation(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-鍒犻櫎閰嶇疆", notes = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-鍒犻櫎閰嶇疆") @DeleteMapping("/delete") public ResponseResult deleteDefinition(@RequestParam("id") String id) { boolean b = definitionService.deleteDefinition(id); @@ -51,10 +52,12 @@ return new ResponseResult(CommonCode.FAIL); } - @AutoLog(value = "DNC娴佺▼閰嶇疆-鍒嗛〉鏌ヨ閰嶇疆鍒楄〃") - @ApiOperation(value = "DNC娴佺▼閰嶇疆-鍒嗛〉鏌ヨ閰嶇疆鍒楄〃", notes = "DNC娴佺▼閰嶇疆-鍒嗛〉鏌ヨ閰嶇疆鍒楄〃") - @GetMapping("/find/page/{page}/{size}") - public QueryPageResponseResult<ActivitiDefinition> findPageList(@PathVariable("page") int page, @PathVariable("size") int size, ActivitiDefinitionRequest request) { - return definitionService.findPageList(page, size, request); + @AutoLog(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-鍒嗛〉鏌ヨ閰嶇疆鍒楄〃") + @ApiOperation(value = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-鍒嗛〉鏌ヨ閰嶇疆鍒楄〃", notes = "DNC鎸囨淳璁惧娴佺▼閰嶇疆-鍒嗛〉鏌ヨ閰嶇疆鍒楄〃") + @GetMapping("/find/page") + public Result<?> findPageList(@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, + ActivitiDefinitionRequest request) { + return definitionService.findPageList(pageNo, pageSize, request); } } -- Gitblit v1.9.3