|
|
|
@ -4,7 +4,7 @@ namespace NapCatRobotClient.Service.Group.Service
|
|
|
|
{
|
|
|
|
{
|
|
|
|
public class GroupService : IGroupService, IScoped
|
|
|
|
public class GroupService : IGroupService, IScoped
|
|
|
|
{
|
|
|
|
{
|
|
|
|
private static string GroupQQ = App.Configuration["QQConfig:XiuXianGroupId"];
|
|
|
|
private static List<string> GroupQQ = App.GetConfig<List<string>>("QQConfig:XiuXianGroupId");
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// <summary>
|
|
|
|
/// 处理群消息
|
|
|
|
/// 处理群消息
|
|
|
|
@ -16,7 +16,7 @@ namespace NapCatRobotClient.Service.Group.Service
|
|
|
|
JObject json = JObject.Parse(message);
|
|
|
|
JObject json = JObject.Parse(message);
|
|
|
|
string groupId = json["group_id"]?.ToString() ?? string.Empty;
|
|
|
|
string groupId = json["group_id"]?.ToString() ?? string.Empty;
|
|
|
|
string groupMsg = json["message"]?.ToString() ?? string.Empty;
|
|
|
|
string groupMsg = json["message"]?.ToString() ?? string.Empty;
|
|
|
|
if (GroupQQ == groupId && string.IsNullOrWhiteSpace(groupMsg) is false)
|
|
|
|
if (GroupQQ.Contains(groupId) && string.IsNullOrWhiteSpace(groupMsg) is false)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
_ = WantedPriceProcess.ProcessGroupRequest(groupId, message);
|
|
|
|
_ = WantedPriceProcess.ProcessGroupRequest(groupId, message);
|
|
|
|
|
|
|
|
|
|
|
|
|