Merge pull request #1140 from shuxiaoyuan/fix-update-time

bugfix:目录订阅收到更新事件时,sql字段update_time为空导致的报错
This commit is contained in:
648540858
2023-12-11 10:05:57 +08:00
committed by GitHub

View File

@@ -243,6 +243,10 @@ public class DeviceChannelServiceImpl implements IDeviceChannelService {
@Override
public void batchUpdateChannel(List<DeviceChannel> channels) {
String now = DateUtil.getNow();
for (DeviceChannel channel : channels) {
channel.setUpdateTime(now);
}
channelMapper.batchUpdate(channels);
for (DeviceChannel channel : channels) {
if (channel.getParentId() != null) {