| | |
| | | public class DaPointCollectStatusServiceImpl extends BaseServiceImpl<DaPointCollectStatusDao, DaPointCollectStatusEntity> |
| | | implements DaPointCollectStatusService { |
| | | |
| | | public void recordStatus(String pointId, String collectValue, Date collectTime) { |
| | | public void recordStatus(String pointNo, String collectValue, Date collectTime) { |
| | | QueryWrapper<DaPointCollectStatusEntity> queryWrapper = new QueryWrapper<>(); |
| | | queryWrapper.eq("point_id", pointId); |
| | | queryWrapper.eq("point_no", pointNo); |
| | | DaPointCollectStatusEntity entity = baseDao.selectOne(queryWrapper); |
| | | if (entity == null) { |
| | | entity = new DaPointCollectStatusEntity(); |
| | | entity.setId(UUID.randomUUID().toString()); |
| | | entity.setPointId(pointId); |
| | | entity.setPointNo(pointNo); |
| | | entity.setCollectValue(collectValue); |
| | | entity.setCollectQuality(DataQualityEnum.getEumByValue(collectValue).getCode()); |
| | | entity.setCollectTime(collectTime); |