This commit is contained in:
tanglong 2025-07-28 16:01:17 +08:00
parent 180e0fc8aa
commit 3db004ef8d

View File

@ -174,7 +174,7 @@ namespace YD_AllHeartRates.Api.Services.Impl
await _sportsContext.AddAsync(entity);
var res = await _sportsContext.SaveChangesAsync() > 0;
_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
//_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
_caching.Remove($"{AppSettings.StudentListCacheKey}_{schoolCode}");
return res;
}
@ -207,7 +207,7 @@ namespace YD_AllHeartRates.Api.Services.Impl
_sportsContext.Update(device);
var res = await _sportsContext.SaveChangesAsync() > 0;
_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
//_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
_caching.Remove($"{AppSettings.StudentListCacheKey}_{schoolCode}");
return res;
}
@ -227,7 +227,7 @@ namespace YD_AllHeartRates.Api.Services.Impl
_sportsContext.Device.Remove(device);
var res = await _sportsContext.SaveChangesAsync() > 0;
_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
//_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
_caching.Remove($"{AppSettings.StudentListCacheKey}_{schoolCode}");
return res;
}
@ -285,7 +285,7 @@ namespace YD_AllHeartRates.Api.Services.Impl
await _sportsContext.AddRangeAsync(deviceList);
var res = await _sportsContext.SaveChangesAsync() > 0;
_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
//_caching.Remove($"{AppSettings.DeviceListCacheKey}_{schoolCode}");
_caching.Remove($"{AppSettings.StudentListCacheKey}_{schoolCode}");
return res;
}