Skip to content

Commit

Permalink
[fix] 修复预报通知不正常的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
zxbmmmmmmmmm committed Jul 24, 2024
1 parent 6eb2028 commit 0a5a499
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions FluentWeather.Tasks/NotifyTask.cs
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ private void PushToday(List<WeatherDailyBase> data)
//var group = new AdaptiveGroup();
//TileHelper.GetGroupChildren(group, trimmed);
var largeGroup = new AdaptiveGroup();
foreach (var item in data)
foreach (var item in trimmed)
{
largeGroup.Children.Add(TileHelper.GenerateTileSubgroup(TileHelper.GetWeek(item.Time), $"Assets/Weather/Resized/32/{AssetsHelper.GetWeatherIconName(item.WeatherType)}", item.MaxTemperature, item.MinTemperature));
}
Expand All @@ -141,9 +141,9 @@ private void PushToday(List<WeatherDailyBase> data)
}
private void PushTomorrow(List<WeatherDailyBase> data)
{
var trimmed = (data.Count >= 7) ? data.GetRange(1, 6) : data;;
var trimmed = (data.Count >= 7) ? data.GetRange(1, 6) : data;
var largeGroup = new AdaptiveGroup();
foreach (var item in data)
foreach (var item in trimmed)
{
largeGroup.Children.Add(TileHelper.GenerateSubgroup(TileHelper.GetWeek(item.Time), $"Assets/Weather/Resized/32/{AssetsHelper.GetWeatherIconName(item.WeatherType)}", item.MaxTemperature, item.MinTemperature));
}
Expand Down

0 comments on commit 0a5a499

Please sign in to comment.