From 5ca3dd0ae1974080679da9b4ec10a6720adfe036 Mon Sep 17 00:00:00 2001 From: MayueCif Date: Sun, 14 Dec 2025 20:41:55 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=AE=98=E6=96=B9QQ=E7=BE=A4?= =?UTF-8?q?=E5=85=A5=E5=8F=A3=E5=8F=8A=E7=9B=B8=E5=85=B3=E5=B1=95=E7=A4=BA?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 在AppInfo中添加QQ群号和加入链接常量,About页面增加QQ群功能项及qq.svg图标,支持一键加入官方QQ群;HomePageViewModel类声明调整为partial。提升用户社区互动体验。 --- src/Applications/Settings/AppInfo.cs | 10 ++++++++++ src/Assets/Images/qq.svg | 3 +++ src/ViewModels/AboutPageViewModel.cs | 8 ++++++++ src/ViewModels/HomePageViewModel.cs | 2 +- 4 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 src/Assets/Images/qq.svg diff --git a/src/Applications/Settings/AppInfo.cs b/src/Applications/Settings/AppInfo.cs index 611c9d5..d8d6fe7 100644 --- a/src/Applications/Settings/AppInfo.cs +++ b/src/Applications/Settings/AppInfo.cs @@ -136,5 +136,15 @@ public static string Version /// public static string LicenseUrl => $"https://github.com/{Company}/{AppName}/blob/main/LICENSE"; + /// + /// 官方QQ群号码 + /// + public const string QQGroupNumber = "1012116859"; + + /// + /// 加入QQ群链接 + /// + public const string QQGroupUrl = "https://qm.qq.com/q/lFE1Cc8d5m"; + #endregion } \ No newline at end of file diff --git a/src/Assets/Images/qq.svg b/src/Assets/Images/qq.svg new file mode 100644 index 0000000..ac20b9b --- /dev/null +++ b/src/Assets/Images/qq.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/src/ViewModels/AboutPageViewModel.cs b/src/ViewModels/AboutPageViewModel.cs index 7941062..fb4bd56 100644 --- a/src/ViewModels/AboutPageViewModel.cs +++ b/src/ViewModels/AboutPageViewModel.cs @@ -274,6 +274,14 @@ private void InitializeFeatureItems() ButtonText = "查看", Command = new RelayCommand(() => OpenUrl(AppInfo.LicenseUrl)) }); + + FeatureItems.Add(new FeatureItem + { + IconSource = "/Assets/Images/qq.svg", + Title = $"官方QQ群: {AppInfo.QQGroupNumber}", + ButtonText = "加入", + Command = new RelayCommand(() => OpenUrl(AppInfo.QQGroupUrl)) + }); } } diff --git a/src/ViewModels/HomePageViewModel.cs b/src/ViewModels/HomePageViewModel.cs index 83af366..5f867a4 100644 --- a/src/ViewModels/HomePageViewModel.cs +++ b/src/ViewModels/HomePageViewModel.cs @@ -8,7 +8,7 @@ namespace MarketAssistant.ViewModels; /// /// 首页ViewModel /// -public class HomePageViewModel : ViewModelBase, IDisposable +public partial class HomePageViewModel : ViewModelBase, IDisposable { /// /// 搜索功能ViewModel