From 0954cb5738af21562612957291111a74b56c4d18 Mon Sep 17 00:00:00 2001 From: yanghongwei Date: Fri, 4 Apr 2025 19:49:50 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=A7=E7=94=9F=E6=96=B0=E7=9A=84=E6=89=B9?= =?UTF-8?q?=E6=AC=A1=E7=9A=84=E6=97=B6=E5=80=99=EF=BC=8C=E9=87=8D=E6=96=B0?= =?UTF-8?q?=E8=AE=A1=E7=AE=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Service/AlarmService.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Service/AlarmService.cs b/Service/AlarmService.cs index 18eaf62..5f990df 100644 --- a/Service/AlarmService.cs +++ b/Service/AlarmService.cs @@ -67,7 +67,7 @@ namespace LY.App.Service await _db.CopyNew().Insertable(entity).SplitTable().ExecuteReturnSnowflakeIdListAsync(); //推送报警信息 await _pushService.SendMessageToAll(new { msgType = "event", data = entity }); - await _redisService.DeleteAsync(RedisKeyList.index_data()); + } return new ApiResult(); } @@ -141,6 +141,7 @@ namespace LY.App.Service if (batchId == 0) { batchId = SnowFlakeSingle.Instance.NextId(); + await _redisService.DeleteAsync(RedisKeyList.index_data()); } await _redisService.SetAsync(key, batchId, TimeSpan.FromSeconds(timeSpan)); return batchId;