Selaa lähdekoodia

修改节点基础数据

cr 2 viikkoa sitten
vanhempi
commit
3f5c92a472

+ 2 - 2
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/NodeBaseInfoController.java

@@ -292,13 +292,13 @@ public class NodeBaseInfoController extends BladeController {
     @ApiOperation(value = "获取节点基础数据", notes = "获取节点基础数据")
     public R getNodeData(@RequestParam Long pKeyId, Integer classify){
         NodeBaseInfo nodeBaseInfo = nodeBaseInfoService.getBaseMapper().selectOne(new QueryWrapper<NodeBaseInfo>().eq("node_id", pKeyId));
-        String sql="select * from u_information_query where wbs_id="+pKeyId+" and classify="+classify+" and is_deleted=0";
+        String sql="select * from u_information_query where wbs_id="+pKeyId+" and classify="+classify+" and is_deleted=0 order by  create_time DESC";
         List<InformationQuery> query = jdbcTemplate.query(sql, new BeanPropertyRowMapper<>(InformationQuery.class));
         NodeBaseInfoVO baseInfoVO=new NodeBaseInfoVO();
         BeanUtil.copy(nodeBaseInfo, baseInfoVO);
         if(!query.isEmpty()){
             InformationQuery informationQuery = query.get(0);
-            if(informationQuery!=null&&(informationQuery.getStatus()!=0||informationQuery.getStatus()!=3)){
+            if(informationQuery!=null&&(informationQuery.getStatus()==1||informationQuery.getStatus()==2)){
                 baseInfoVO.setIsDisable(1);
             }
         }else {