build: 10.12.16

fix: 系统总内存在特定情况下单位错误
feat: 网关定时任务性能优化
This commit is contained in:
2248356998 qq.com
2025-10-27 17:12:13 +08:00
parent a464594885
commit 313b0e54d3
3 changed files with 11 additions and 8 deletions

View File

@@ -412,7 +412,7 @@ public class MachineInfo
#if NETFRAMEWORK || WINDOWS
{
var ci = new Microsoft.VisualBasic.Devices.ComputerInfo();
Memory = (ulong)(ci.TotalPhysicalMemory / 1024.0);
Memory = (ulong)(ci.TotalPhysicalMemory / 1024.0 / 1024.0);
}
#endif
@@ -632,7 +632,7 @@ public class MachineInfo
//if (dic2.TryGetValue("Model Name", out str)) Product = str;
if (dic.TryGetValue("Model Identifier", out var str)) Product = str;
if (dic.TryGetValue("Processor Name", out str)) Processor = str;
if (dic.TryGetValue("Memory", out str)) Memory = (UInt64)str.TrimEnd("GB").Trim().ToLong() * 1024 * 1024;
if (dic.TryGetValue("Memory", out str)) Memory = (UInt64)str.TrimEnd("GB").Trim().ToLong() * 1024;
if (dic.TryGetValue("Serial Number (system)", out str)) Serial = str;
if (dic.TryGetValue("Hardware UUID", out str)) UUID = str;
if (dic.TryGetValue("Processor Name", out str)) Processor = str;
@@ -868,7 +868,7 @@ public class MachineInfo
if (dic != null)
{
if (dic.TryGetValue("MemTotal", out var str) && !str.IsNullOrEmpty())
Memory = (UInt64)str.TrimEnd(" kB").ToLong();
Memory = (UInt64)(str.TrimEnd(" kB").ToLong() / 1024.0);
ulong ma = 0;
if (dic.TryGetValue("MemAvailable", out str) && !str.IsNullOrEmpty())

View File

@@ -1,9 +1,9 @@
<Project>
<PropertyGroup>
<PluginVersion>10.12.13</PluginVersion>
<ProPluginVersion>10.12.13</ProPluginVersion>
<DefaultVersion>10.12.13</DefaultVersion>
<PluginVersion>10.12.16</PluginVersion>
<ProPluginVersion>10.12.16</ProPluginVersion>
<DefaultVersion>10.12.16</DefaultVersion>
<AuthenticationVersion>10.11.7</AuthenticationVersion>
<SourceGeneratorVersion>10.11.7</SourceGeneratorVersion>
<NET8Version>8.0.21</NET8Version>

View File

@@ -262,9 +262,12 @@ public partial class MainLayout : IDisposable
protected override async Task OnAfterRenderAsync(bool firstRender)
{
if (WebsiteOption.Value.Demo)
if (firstRender)
{
await ShowGitee();
if (WebsiteOption.Value.Demo)
{
await ShowGitee();
}
}
await base.OnAfterRenderAsync(firstRender);
}