mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-21 03:25:12 +08:00
update
This commit is contained in:
@@ -35,30 +35,6 @@ public interface IPileConnectorInfoService {
|
||||
|
||||
List<PileConnectorInfo> selectPileConnectorInfoList(String pileSn);
|
||||
|
||||
/**
|
||||
* 新增充电桩枪口信息
|
||||
*
|
||||
* @param pileConnectorInfo 充电桩枪口信息
|
||||
* @return 结果
|
||||
*/
|
||||
// int insertPileConnectorInfo(PileConnectorInfo pileConnectorInfo);
|
||||
|
||||
/**
|
||||
* 修改充电桩枪口信息
|
||||
*
|
||||
* @param pileConnectorInfo 充电桩枪口信息
|
||||
* @return 结果
|
||||
*/
|
||||
// int updatePileConnectorInfo(PileConnectorInfo pileConnectorInfo);
|
||||
|
||||
/**
|
||||
* 批量删除充电桩枪口信息
|
||||
*
|
||||
* @param ids 需要删除的充电桩枪口信息主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
// int deletePileConnectorInfoByIds(Integer[] ids);
|
||||
|
||||
int deletePileConnectorInfoByPileSnList(List<String> pileSnList);
|
||||
|
||||
int batchInsertConnectorInfo(List<PileConnectorInfo> pileConnectorInfoList);
|
||||
|
||||
@@ -5,6 +5,7 @@ import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.google.common.collect.Lists;
|
||||
import com.google.common.collect.Maps;
|
||||
import com.google.common.collect.Sets;
|
||||
import com.jsowell.common.constant.CacheConstants;
|
||||
import com.jsowell.common.constant.Constants;
|
||||
import com.jsowell.common.core.domain.ykc.RealTimeMonitorData;
|
||||
@@ -531,10 +532,23 @@ public class PileConnectorInfoServiceImpl implements IPileConnectorInfoService {
|
||||
|
||||
// TODO 推送联联平台 设备状态变化推送接口 ConnectorStatusInfo
|
||||
|
||||
// 异步放缓存
|
||||
CompletableFuture.runAsync(() -> statusChange(pileConnectorCode));
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
// 枪口状态变更,站点id放缓存
|
||||
private void statusChange(String pileConnectorCode) {
|
||||
// 查询枪口信息
|
||||
PileConnectorInfoVO connectorInfoVO = getPileConnectorInfoByConnectorCode(pileConnectorCode);
|
||||
if (connectorInfoVO == null) {
|
||||
return;
|
||||
}
|
||||
String redisKey = CacheConstants.PUSH_STATION_CONNECTOR;
|
||||
redisCache.setCacheSet(redisKey, Sets.newHashSet(connectorInfoVO.getStationId()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量获取桩状态
|
||||
* 桩的状态有 在线 离线 故障
|
||||
|
||||
Reference in New Issue
Block a user