diff --git a/Server/YD_XinWei/Services/Impl/LargeScreenService.cs b/Server/YD_XinWei/Services/Impl/LargeScreenService.cs index b582074..83ec02b 100644 --- a/Server/YD_XinWei/Services/Impl/LargeScreenService.cs +++ b/Server/YD_XinWei/Services/Impl/LargeScreenService.cs @@ -272,15 +272,11 @@ namespace YD_XinWei.Api.Services.Impl s.Rank, s.ScoreTime }) + .Take(50) .ToListAsync(); // 2. 内存分组取每个学生最新一条 - var latestPerStudent = sourceData - .GroupBy(s => s.StudentNo) - .Select(g => g.First()) // 因为前面按 ScoreTime 排过 - .OrderBy(s => s.ScoreTime) - .Take(50) - .ToList(); + var latestPerStudent = sourceData.OrderBy(x=>x.ScoreTime).ToList(); // 3. 映射到 DTO var realTimeResults = latestPerStudent diff --git a/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfo.cs b/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfo.cs index 76774c8..482d2a5 100644 --- a/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfo.cs +++ b/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfo.cs @@ -14,7 +14,7 @@ using System.Reflection; [assembly: System.Reflection.AssemblyCompanyAttribute("YD_XinWei.Api")] [assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] -[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+f5873892e13dd05303d2e1923728ae8145db3bb6")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+bd96de2331a7d666a4d8e2b114e0470a03d1866f")] [assembly: System.Reflection.AssemblyProductAttribute("YD_XinWei.Api")] [assembly: System.Reflection.AssemblyTitleAttribute("YD_XinWei.Api")] [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] diff --git a/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfoInputs.cache b/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfoInputs.cache index 39a7211..6367179 100644 --- a/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfoInputs.cache +++ b/Server/YD_XinWei/obj/Debug/net6.0/YD_XinWei.Api.AssemblyInfoInputs.cache @@ -1 +1 @@ -1b55e451e5df8b5cfbeba624584454d98ac4b71c594cd85758e5968810368ab3 +a7d3edef1797f546d7f154e83ba45b815ed5461c833e6055d7e38cbb05ed0590 diff --git a/Server/YD_XinWei/obj/Debug/net6.0/apphost.exe b/Server/YD_XinWei/obj/Debug/net6.0/apphost.exe index 6b31073..bc1ec66 100644 Binary files a/Server/YD_XinWei/obj/Debug/net6.0/apphost.exe and b/Server/YD_XinWei/obj/Debug/net6.0/apphost.exe differ