Gitea 1 year ago
parent 9a0b7b5157
commit 1feab42ac5
  1. 7
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/requiremententity/controller/RequirementEntityController.java

@ -230,6 +230,10 @@ public class RequirementEntityController extends JeecgController<RequirementEnti
@ApiOperation(value="合并", notes="合并")
@DeleteMapping(value = "/hb")
public Result<?> hb(@RequestParam(name="ids",required=true) String ids,@RequestParam(name="id",required=true) String id) {
RequirementEntity requirementEntity1 = requirementEntityService.getById(id);
if(requirementEntity1.getEntityStatus()==9){
return Result.error("该实体已废弃,需撤回废弃后再保留");
}else{
List<String> listids = Arrays.asList(ids.split(","));
for (int i = 0 ; i < listids.size(); i++){
if(!id.equals(listids.get(i))){
@ -238,12 +242,13 @@ public class RequirementEntityController extends JeecgController<RequirementEnti
requirementEntityService.updateById(requirementEntity);
}
}
RequirementEntity requirementEntity1 = requirementEntityService.getById(id);
requirementEntity1.setEntityStatus(2);
requirementEntityService.updateById(requirementEntity1);
return Result.OK("成功");
}
}
/**
* 导出excel
*

Loading…
Cancel
Save