dengzedong
3 天以前 07890ec0dcb75572740f25a29c80f6d7bddb39e0
提交 | 用户 | 时间
a6de49 1 package com.iailab.module.data.point.service.impl;
H 2
139c6a 3 import cn.hutool.core.collection.CollUtil;
a6de49 4 import com.alibaba.fastjson.JSONArray;
cfbd83 5 import com.baomidou.dynamic.datasource.annotation.DSTransactional;
a6de49 6 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
250190 7 import com.baomidou.mybatisplus.core.metadata.IPage;
6bf63b 8 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
L 9 import com.iailab.framework.common.pojo.PageResult;
139c6a 10 import com.iailab.framework.common.util.object.BeanUtils;
6bf63b 11 import com.iailab.framework.common.util.object.ConvertUtils;
07890e 12 import com.iailab.module.data.api.point.dto.ApiPointDTO;
01d6f8 13 import com.iailab.module.data.channel.common.service.ChannelSourceService;
a6de49 14 import com.iailab.module.data.common.enums.CommonConstant;
H 15 import com.iailab.module.data.common.enums.IsEnableEnum;
c96e44 16 import com.iailab.module.data.common.enums.IncreaseCodeEnum;
a6de49 17 import com.iailab.module.data.point.common.PointTypeEnum;
6bf63b 18 import com.iailab.module.data.point.dao.DaPointDao;
0ed8ac 19 import com.iailab.module.data.point.dto.DaCumulatePointDTO;
20 import com.iailab.module.data.point.dto.DaMathPointDTO;
a6de49 21 import com.iailab.module.data.point.dto.DaMeasurePointDTO;
H 22 import com.iailab.module.data.point.dto.DaPointDTO;
139c6a 23 import com.iailab.module.data.point.entity.DaMeasurePointEntity;
a6de49 24 import com.iailab.module.data.point.entity.DaPointEntity;
0ed8ac 25 import com.iailab.module.data.point.service.*;
f21253 26 import com.iailab.module.data.point.vo.DaPointPageReqVO;
J 27 import com.iailab.module.data.point.vo.PointImportExcelVO;
28 import com.iailab.module.data.point.vo.PointImportRespVO;
48c57b 29 import org.apache.commons.lang3.ObjectUtils;
0ed8ac 30 import org.springframework.beans.factory.annotation.Autowired;
a6de49 31 import org.springframework.stereotype.Service;
H 32 import org.springframework.util.CollectionUtils;
33
6bf63b 34 import javax.annotation.Resource;
a6de49 35 import java.util.*;
9df837 36 import java.util.concurrent.ConcurrentHashMap;
139c6a 37
D 38 import static com.iailab.framework.common.exception.util.ServiceExceptionUtil.exception;
f21253 39 import static com.iailab.module.data.enums.ErrorCodeConstants.POINT_EXISTS;
J 40 import static com.iailab.module.data.enums.ErrorCodeConstants.POINT_IMPORT_LIST_IS_EMPTY;
a6de49 41
H 42 /**
6bf63b 43  * @author lirm
a6de49 44  * @Description
6bf63b 45  * @createTime 2024年09月2日
a6de49 46  */
H 47 @Service
6bf63b 48 public class DaPointServiceImpl extends ServiceImpl<DaPointDao, DaPointEntity> implements DaPointService {
a6de49 49
0ed8ac 50     @Autowired
a6de49 51     private DaMeasurePointService daMeasurePointService;
H 52
0ed8ac 53     @Autowired
a6de49 54     private DaMathPointService daMathPointService;
H 55
0ed8ac 56     @Autowired
57     private DaCumulatePointService daCumulatePointService;
58
59     @Autowired
a6de49 60     private DaSequenceNumService daSequenceNumService;
6bf63b 61     
L 62     @Resource
63     private DaPointDao daPointDao;
64
139c6a 65     @Resource
01d6f8 66     private ChannelSourceService channelSourceService;
9df837 67
90e342 68     @Resource
69     private DaPointCollectStatusService daPointCollectStatusService;
70
07890e 71     private static Map<String, ApiPointDTO> pointIdMap = new ConcurrentHashMap<>();
a4891a 72
9df837 73     private static Map<String, DaPointDTO> pointNoMap = new ConcurrentHashMap<>();
a6de49 74
H 75     @Override
250190 76     public PageResult<DaPointDTO> queryPage(DaPointPageReqVO reqVO) {
139c6a 77         IPage<DaPointDTO> page = daPointDao.selectPageList(reqVO);
a4891a 78         return new PageResult<>(page.getRecords(), page.getTotal());
79     }
80
81     private void clearCache() {
82         pointIdMap.clear();
83         pointNoMap.clear();
a6de49 84     }
H 85
86     @Override
6bf63b 87     public DaPointDTO info(String id) {
L 88         DaPointEntity entity = daPointDao.selectById(id);
a6de49 89         DaPointDTO result = ConvertUtils.sourceToTarget(entity, DaPointDTO.class);
0ed8ac 90         result.setMeasurePoint(new DaMeasurePointDTO());
91         result.setMathPoint(new DaMathPointDTO());
92         result.setCumulatePoint(new DaCumulatePointDTO());
93         switch (PointTypeEnum.getEumByCode(result.getPointType())) {
94             case MEASURE_POINT:
95                 DaMeasurePointDTO measurePoint = daMeasurePointService.getByPoint(id);
96                 result.setMeasurePoint(measurePoint);
97                 List<String> sourceOption = new ArrayList<>();
98                 sourceOption.add(measurePoint.getSourceType());
99                 sourceOption.add(measurePoint.getSourceId());
100                 sourceOption.add(measurePoint.getTagNo());
101                 result.setSourceOption(sourceOption);
102                 break;
103             case CALCULATE_POINT:
104                 result.setMathPoint(daMathPointService.getByPoint(id));
105                 break;
106             case CUMULATE:
107                 result.setCumulatePoint(daCumulatePointService.getByPoint(id));
108                 break;
109             default:
110                 break;
a6de49 111         }
H 112         return result;
113     }
114
115     @Override
07890e 116     public ApiPointDTO getSimpleInfoById(String id) {
a4891a 117         if (pointIdMap.containsKey(id)) {
118             return pointIdMap.get(id);
119         }
07890e 120         ApiPointDTO dto = ConvertUtils.sourceToTarget(daPointDao.selectById(id), ApiPointDTO.class);
5f7008 121         if (dto == null) {
122             return null;
123         }
a4891a 124         pointIdMap.put(id, dto);
07890e 125         return dto;
b8b8cb 126     }
127
128     @Override
129     public DaPointDTO getSimpleInfoByNo(String no) {
29b971 130         QueryWrapper<DaPointEntity> queryWrapper = new QueryWrapper<>();
7511af 131         queryWrapper.eq("point_no", no);
b8b8cb 132         return ConvertUtils.sourceToTarget(daPointDao.selectOne(queryWrapper), DaPointDTO.class);
133     }
134
135     @Override
a6de49 136     public List<DaPointDTO> list(Map<String, Object> params) {
48c57b 137         Object pointType = params.get("pointType");
a6de49 138         List<String> pointNos = new ArrayList<>();
H 139         if (params.get("pointNos") != null) {
140             pointNos = JSONArray.parseArray(JSONArray.toJSONString(params.get("pointNos")), String.class);
141         }
14cb32 142         List<String> pointTypes = new ArrayList<>();
143         if (params.get("pointTypes") != null) {
144             pointTypes = Arrays.asList(params.get("pointTypes").toString().split(","));
145         }
146
48c57b 147         Object pointNoLike = params.get("pointNoLike");
a6de49 148         QueryWrapper<DaPointEntity> queryWrapper = new QueryWrapper();
48c57b 149         queryWrapper.eq(!ObjectUtils.isEmpty(pointType), "point_type", pointType);
L 150         queryWrapper.in(pointNos.size() != 0,"point_no", pointNos);
151         queryWrapper.like(!ObjectUtils.isEmpty(pointNoLike), "point_no", pointNoLike);
14cb32 152         queryWrapper.in(pointTypes.size() != 0,"point_type", pointTypes);
6bf63b 153         List<DaPointEntity> list = daPointDao.selectList(queryWrapper);
a6de49 154         return ConvertUtils.sourceToTarget(list, DaPointDTO.class);
H 155     }
156
157     @Override
cfbd83 158     @DSTransactional(rollbackFor = Exception.class)
a6de49 159     public void add(DaPointDTO dataPoint) {
H 160         DaPointEntity daPointEntity = ConvertUtils.sourceToTarget(dataPoint, DaPointEntity.class);
161         daPointEntity.setId(UUID.randomUUID().toString());
01d6f8 162         switch (PointTypeEnum.getEumByCode(dataPoint.getPointType())) {
163             case MEASURE_POINT:
164                 DaMeasurePointDTO measurePoint = new DaMeasurePointDTO();
165                 measurePoint.setSourceType(dataPoint.getSourceOption().get(0));
166                 measurePoint.setSourceId(dataPoint.getSourceOption().get(1));
167                 measurePoint.setTagNo(dataPoint.getSourceOption().get(2));
168                 daMeasurePointService.add(measurePoint, daPointEntity.getId());
169                 daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_M.name()));
170                 break;
171             case CALCULATE_POINT:
172                 daMathPointService.add(dataPoint.getMathPoint(), daPointEntity.getId());
173                 daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_C.name()));
174                 break;
175             case CONSTANT:
176                 daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_F.name()));
177                 break;
0ed8ac 178             case CUMULATE:
179                 daCumulatePointService.add(dataPoint.getCumulatePoint(), daPointEntity.getId());
180                 daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_L.name()));
181                 break;
01d6f8 182             default:
183                 break;
a6de49 184         }
H 185         daPointEntity.setIsEnable(CommonConstant.IS_ENABLE);
186         daPointEntity.setCreateTime(new Date());
6bf63b 187         daPointDao.insert(daPointEntity);
9df837 188
90e342 189         daPointCollectStatusService.add(daPointEntity.getPointNo());
9df837 190         // 清空缓存
a4891a 191         clearCache();
a6de49 192     }
H 193
194     @Override
cfbd83 195     @DSTransactional(rollbackFor = Exception.class)
a6de49 196     public void update(DaPointDTO dataPoint) {
H 197         DaPointEntity daPointEntity = ConvertUtils.sourceToTarget(dataPoint, DaPointEntity.class);
198         daPointEntity.setUpdateTime(new Date());
6bf63b 199         daPointDao.updateById(daPointEntity);
01d6f8 200         switch (PointTypeEnum.getEumByCode(dataPoint.getPointType())) {
201             case MEASURE_POINT:
202                 DaMeasurePointDTO measurePoint = dataPoint.getMeasurePoint();
203                 measurePoint.setSourceType(dataPoint.getSourceOption().get(0));
204                 measurePoint.setSourceId(dataPoint.getSourceOption().get(1));
205                 measurePoint.setTagNo(dataPoint.getSourceOption().get(2));
206                 daMeasurePointService.update(measurePoint);
207                 break;
208             case CALCULATE_POINT:
209                 daMathPointService.update(dataPoint.getMathPoint());
210                 break;
0ed8ac 211             case CUMULATE:
212                 daCumulatePointService.update(dataPoint.getCumulatePoint());
213                 break;
01d6f8 214             default:
215                 break;
a6de49 216         }
9df837 217         // 清空缓存
a4891a 218         clearCache();
a6de49 219     }
H 220
221     @Override
cfbd83 222     @DSTransactional(rollbackFor = Exception.class)
eb1c5f 223     public void delete(String[] ids) {
224         daPointDao.deleteBatchIds(Arrays.asList(ids));
225         daMeasurePointService.deleteByPoint(ids);
226         daMathPointService.deleteByPoint(ids);
227         daCumulatePointService.deleteByPoint(ids);
9df837 228         // 清空缓存
a4891a 229         clearCache();
a6de49 230     }
H 231
232     @Override
14cb32 233     public List<DaPointDTO> getConstantPoint(DaPointPageReqVO reqVO) {
234         Map<String, Object> params = new HashMap<>();
235         params.put("pointType", PointTypeEnum.CONSTANT.getCode());
236         params.put("pointNo", reqVO.getPointNo());
237         params.put("pointName", reqVO.getPointName());
238         return daPointDao.getConstantPoint(params);
239     }
240
241     @Override
a6de49 242     public List<DaPointDTO> getConstantPoint(String freq) {
H 243         Map<String, Object> params = new HashMap<>();
244         params.put("pointType", PointTypeEnum.CONSTANT.getCode());
245         params.put("isEnable", CommonConstant.IS_ENABLE);
246         params.put("minfreqid", freq);
6bf63b 247         return daPointDao.getConstantPoint(params);
a6de49 248     }
H 249
250     @Override
251     public List<DaPointDTO> getConstantPoint(List<String> pointNos) {
252         Map<String, Object> params = new HashMap<>();
253         params.put("pointType", PointTypeEnum.CONSTANT.getCode());
254         params.put("isEnable", CommonConstant.IS_ENABLE);
255         params.put("pointNos", pointNos);
6bf63b 256         return daPointDao.getConstantPoint(params);
14cb32 257     }
258
259     @Override
260     public List<DaPointDTO> getMeasurePoint(DaPointPageReqVO reqVO) {
261         Map<String, Object> params = new HashMap<>();
262         params.put("pointType", PointTypeEnum.MEASURE_POINT.getCode());
263         params.put("pointNo", reqVO.getPointNo());
264         params.put("pointName", reqVO.getPointName());
265         params.put("sourceName", reqVO.getSourceName());
266         return daPointDao.getMeasurePoint(params);
a6de49 267     }
H 268
269     @Override
270     public List<DaPointDTO> getMeasurePoint(String freq) {
271         Map<String, Object> params = new HashMap<>();
272         params.put("pointType", PointTypeEnum.MEASURE_POINT.getCode());
273         params.put("isEnable", CommonConstant.IS_ENABLE);
274         params.put("minfreqid", freq);
6bf63b 275         return daPointDao.getMeasurePoint(params);
a6de49 276     }
H 277
278     @Override
279     public List<DaPointDTO> getMeasurePoint(List<String> pointNos) {
280         Map<String, Object> params = new HashMap<>();
281         params.put("pointType", PointTypeEnum.MEASURE_POINT.getCode());
282         params.put("isEnable", CommonConstant.IS_ENABLE);
283         params.put("pointNos", pointNos);
6bf63b 284         return daPointDao.getMeasurePoint(params);
a6de49 285     }
H 286
287     @Override
288     public DaPointDTO getMeasurePointByNo(String pointNo) {
289         Map<String, Object> params = new HashMap<>();
290         params.put("pointType", PointTypeEnum.MEASURE_POINT.getCode());
291         params.put("pointNo", pointNo);
6bf63b 292         List<DaPointDTO> list = daPointDao.getMeasurePoint(params);
a6de49 293         if (CollectionUtils.isEmpty(list)) {
H 294             return null;
295         }
296         return list.get(0);
14cb32 297     }
298
299     @Override
300     public List<DaPointDTO> getMathPoint(DaPointPageReqVO reqVO) {
301         Map<String, Object> params = new HashMap<>();
302         params.put("pointType", PointTypeEnum.CALCULATE_POINT.getCode());
303         params.put("pointNo", reqVO.getPointNo());
304         params.put("pointName", reqVO.getPointName());
305         return daPointDao.getMathPoint(params);
a6de49 306     }
H 307
308     @Override
309     public List<DaPointDTO> getMathPoint(String freq) {
310         Map<String, Object> params = new HashMap<>();
311         params.put("pointType", PointTypeEnum.CALCULATE_POINT.getCode());
312         params.put("isEnable", CommonConstant.IS_ENABLE);
313         params.put("minfreqid", freq);
6bf63b 314         return daPointDao.getMathPoint(params);
a6de49 315     }
H 316
317     @Override
318     public List<DaPointDTO> getMathPoint(List<String> pointNos) {
319         Map<String, Object> params = new HashMap<>();
320         params.put("pointType", PointTypeEnum.CALCULATE_POINT.getCode());
321         params.put("isEnable", CommonConstant.IS_ENABLE);
322         params.put("pointNos", pointNos);
6bf63b 323         return daPointDao.getMathPoint(params);
a6de49 324     }
H 325
326     @Override
56dba6 327     public List<DaPointDTO> getCumulatePoint(String freq) {
eb1c5f 328         Map<String, Object> params = new HashMap<>(3);
56dba6 329         params.put("pointType", PointTypeEnum.CUMULATE.getCode());
330         params.put("isEnable", CommonConstant.IS_ENABLE);
331         params.put("minfreqid", freq);
eb1c5f 332         return daPointDao.getCumulatePoint(params);
333     }
334
335     @Override
336     public List<DaPointDTO> getCumulatePoint(DaPointPageReqVO reqVO) {
337         Map<String, Object> params = new HashMap<>(3);
338         params.put("pointType", PointTypeEnum.CUMULATE.getCode());
339         params.put("pointNo", reqVO.getPointNo());
340         params.put("pointName", reqVO.getPointName());
56dba6 341         return daPointDao.getCumulatePoint(params);
342     }
343
344     @Override
a6de49 345     public DaPointDTO getByNo(String pointNo) {
9df837 346         if (pointNoMap.containsKey(pointNo)) {
347             return pointNoMap.get(pointNo);
348         }
a6de49 349         QueryWrapper<DaPointEntity> wrapper = new QueryWrapper<>();
H 350         wrapper.eq("point_no", pointNo);
6bf63b 351         DaPointEntity entity = daPointDao.selectOne(wrapper);
9df837 352         DaPointDTO dto = ConvertUtils.sourceToTarget(entity, DaPointDTO.class);
353         pointNoMap.put(pointNo, dto);
354         return dto;
a6de49 355     }
H 356
357     @Override
358     public List<DaPointDTO> getByNos(List<String> pointNos) {
359         QueryWrapper<DaPointEntity> wrapper = new QueryWrapper<>();
360         wrapper.in("point_no", pointNos);
6bf63b 361         List<DaPointEntity> list = daPointDao.selectList(wrapper);
a6de49 362         return ConvertUtils.sourceToTarget(list, DaPointDTO.class);
H 363     }
364
365     @Override
366     public void updateDefaultValue(DaPointDTO dto) {
367         QueryWrapper<DaPointEntity> wrapper = new QueryWrapper<>();
368         wrapper.eq("point_no", dto.getPointNo());
369         DaPointEntity entity = new DaPointEntity();
370         entity.setDefaultValue(dto.getDefaultValue());
6bf63b 371         daPointDao.update(entity, wrapper);
a6de49 372     }
H 373
374     @Override
139c6a 375     @DSTransactional(rollbackFor = Exception.class) // 添加事务,异常则回滚所有导入
D 376     public PointImportRespVO importPointList(List<PointImportExcelVO> importPoints, boolean isUpdateSupport) {
377         // 1.1 参数校验
378         if (CollUtil.isEmpty(importPoints)) {
379             throw exception(POINT_IMPORT_LIST_IS_EMPTY);
380         }
01d6f8 381
382         Map<String, Map<String, String>> sourcesIdMap = channelSourceService.getSourcesId();
139c6a 383         // 2. 遍历,逐个创建 or 更新
D 384         PointImportRespVO respVO = PointImportRespVO.builder().createPointnames(new ArrayList<>())
385                 .updatePointnames(new ArrayList<>()).failurePointnames(new LinkedHashMap<>()).build();
386         importPoints.forEach(importPoint -> {
387
388             // 判断如果不存在,再进行插入
389             DaPointEntity existPoint = baseMapper.selectByPointName(importPoint.getPointName());
390             if (existPoint == null) {
391                 DaPointEntity daPointEntity = ConvertUtils.sourceToTarget(importPoint, DaPointEntity.class);
392                 daPointEntity.setId(UUID.randomUUID().toString());
393                 daPointEntity.setIsEnable(CommonConstant.IS_ENABLE);
394                 daPointEntity.setCreateTime(new Date());
01d6f8 395                 switch (PointTypeEnum.getEumByCode(daPointEntity.getPointType())) {
396                     case MEASURE_POINT:
397                         DaMeasurePointDTO measurePoint = new DaMeasurePointDTO();
398                         measurePoint.setSourceType(importPoint.getSourceType());
399                         measurePoint.setSourceId(sourcesIdMap.get(importPoint.getSourceType()).get(importPoint.getSourceName()));
400                         measurePoint.setTagNo(importPoint.getTagNo());
401                         measurePoint.setValueType(importPoint.getValueType());
402                         measurePoint.setDimension(importPoint.getDimension());
403                         daMeasurePointService.add(measurePoint, daPointEntity.getId());
404                         daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_M.name()));
405                         break;
406                     case CALCULATE_POINT:
407                         daMathPointService.add(importPoint.getExpression(), daPointEntity.getId());
408                         daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_C.name()));
409                         break;
410                     case CONSTANT:
411                         daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_F.name()));
412                         break;
eb1c5f 413                     case CUMULATE:
414                         DaCumulatePointDTO cumulatePoint = new DaCumulatePointDTO();
415                         cumulatePoint.setMomentPoint(importPoint.getMomentPoint());
416                         cumulatePoint.setLength(importPoint.getLength());
417                         cumulatePoint.setDivisor(importPoint.getDivisor());
418                         daCumulatePointService.add(cumulatePoint, daPointEntity.getId());
419                         daPointEntity.setPointNo(daSequenceNumService.getAndIncreaseByCode(IncreaseCodeEnum.POINT_L.name()));
01d6f8 420                     default:
421                         break;
422                 }
139c6a 423
D 424                 daPointDao.insert(daPointEntity);
13e045 425                 daPointCollectStatusService.add(daPointEntity.getPointNo());
139c6a 426                 respVO.getCreatePointnames().add(importPoint.getPointName());
D 427                 return;
428             }
429
430             // 如果存在,判断是否允许更新
431             if (!isUpdateSupport) {
432                 respVO.getFailurePointnames().put(importPoint.getPointName(), POINT_EXISTS.getMsg());
433                 return;
434             }
435
436             DaPointEntity updatePoint = BeanUtils.toBean(importPoint, DaPointEntity.class);
437             updatePoint.setId(existPoint.getId());
438             baseMapper.updateById(updatePoint);
439             DaMeasurePointEntity measurePoint = new DaMeasurePointEntity();
440             measurePoint.setSourceType(importPoint.getSourceType());
01d6f8 441             measurePoint.setSourceId(sourcesIdMap.get(importPoint.getSourceType()).get(importPoint.getSourceName()));
139c6a 442             measurePoint.setTagNo(importPoint.getTagNo());
D 443             daMeasurePointService.update(measurePoint, new QueryWrapper<DaMeasurePointEntity>().eq("point_id",updatePoint.getId()));
444             respVO.getUpdatePointnames().add(importPoint.getPointName());
445         });
446         return respVO;
447     }
448
449     @Override
14cb32 450     public List<DaPointDTO> getList(DaPointPageReqVO exportReqVO) {
451         return daPointDao.getList(exportReqVO);
139c6a 452     }
D 453
454     @Override
ee9f60 455     @DSTransactional(rollbackFor = Exception.class)
a6de49 456     public void enableByIds(String[] ids) {
H 457         if (CollectionUtils.isEmpty(Arrays.asList(ids))) {
458             return;
459         }
460         Arrays.asList(ids).forEach(item -> {
461             DaPointEntity entity = new DaPointEntity();
462             entity.setId(item);
f21253 463             entity.setIsEnable(IsEnableEnum.ENABLE.getCode());
ee9f60 464             entity.setUpdateTime(new Date());
6bf63b 465             daPointDao.updateById(entity);
a6de49 466         });
H 467     }
468
469     @Override
ee9f60 470     @DSTransactional(rollbackFor = Exception.class)
a6de49 471     public void disableByIds(String[] ids) {
H 472         if (CollectionUtils.isEmpty(Arrays.asList(ids))) {
473             return;
474         }
475         Arrays.asList(ids).forEach(item -> {
476             DaPointEntity entity = new DaPointEntity();
477             entity.setId(item);
f21253 478             entity.setIsEnable(IsEnableEnum.DISABLE.getCode());
ee9f60 479             entity.setUpdateTime(new Date());
6bf63b 480             daPointDao.updateById(entity);
a6de49 481         });
H 482     }
483 }