Compare commits
No commits in common. "64a812247a2419af2268c194930280f0aeded195" and "8e2663b85db722ed09df3474bb724d0cb799b3f3" have entirely different histories.
64a812247a
...
8e2663b85d
@ -31,7 +31,7 @@ system:
|
|||||||
# 微信HOOK配置
|
# 微信HOOK配置
|
||||||
wechat:
|
wechat:
|
||||||
# 微信HOOK接口地址
|
# 微信HOOK接口地址
|
||||||
host: 10.0.0.79:19098
|
host: 10.0.0.79:19088
|
||||||
# 微信容器映射出来的vnc页面地址,没有就不填
|
# 微信容器映射出来的vnc页面地址,没有就不填
|
||||||
# vncUrl: http://192.168.1.175:19087/vnc_lite.html
|
# vncUrl: http://192.168.1.175:19087/vnc_lite.html
|
||||||
# 是否在启动的时候自动设置hook服务的回调
|
# 是否在启动的时候自动设置hook服务的回调
|
||||||
@ -81,7 +81,7 @@ mq:
|
|||||||
enable: false
|
enable: false
|
||||||
# RabbitMQ配置
|
# RabbitMQ配置
|
||||||
rabbitmq:
|
rabbitmq:
|
||||||
host: 10.0.0.31
|
host: 10.0.0.247
|
||||||
port: 5672
|
port: 5672
|
||||||
user: wechat
|
user: wechat
|
||||||
password: wechat123
|
password: wechat123
|
||||||
|
@ -250,11 +250,7 @@ func (m Message) IsJoinToGroup() (flag bool) {
|
|||||||
if m.Type != types.MsgTypeSys {
|
if m.Type != types.MsgTypeSys {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
flag = strings.Contains(m.Content, "\"邀请你加入了群聊,群聊参与人还有:")
|
return strings.Contains(m.Content, "\"邀请你加入了群聊,群聊参与人还有:")
|
||||||
if flag {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
return strings.Contains(m.Content, "\"邀请你和\"") && strings.Contains(m.Content, "\"加入了群聊")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// IsRemoveFromChatroom
|
// IsRemoveFromChatroom
|
||||||
@ -267,14 +263,3 @@ func (m Message) IsRemoveFromChatroom() (flag bool) {
|
|||||||
}
|
}
|
||||||
return strings.HasPrefix(m.Content, "你被\"") && strings.HasSuffix(m.Content, "\"移出群聊")
|
return strings.HasPrefix(m.Content, "你被\"") && strings.HasSuffix(m.Content, "\"移出群聊")
|
||||||
}
|
}
|
||||||
|
|
||||||
// IsChangeGroupName
|
|
||||||
// @description: 是否是修改群名称消息
|
|
||||||
// @receiver m
|
|
||||||
// @return flag
|
|
||||||
func (m Message) IsChangeGroupName() (flag bool) {
|
|
||||||
if m.Type != types.MsgTypeSys {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
return strings.HasPrefix(m.Content, "\"修改群名为“")
|
|
||||||
}
|
|
||||||
|
@ -4,7 +4,6 @@ import (
|
|||||||
"go-wechat/plugin"
|
"go-wechat/plugin"
|
||||||
"go-wechat/service"
|
"go-wechat/service"
|
||||||
"go-wechat/utils"
|
"go-wechat/utils"
|
||||||
"time"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// ReplyNewFriend
|
// ReplyNewFriend
|
||||||
@ -15,12 +14,10 @@ func ReplyNewFriend(m *plugin.MessageContext) {
|
|||||||
_ = utils.SendMessage(m.FromUser, m.GroupUser, "AI正在初始化,请稍等几分钟,初始化完成之后我将主动告知您。", 0)
|
_ = utils.SendMessage(m.FromUser, m.GroupUser, "AI正在初始化,请稍等几分钟,初始化完成之后我将主动告知您。", 0)
|
||||||
}
|
}
|
||||||
if m.IsOldFriendBack() {
|
if m.IsOldFriendBack() {
|
||||||
_ = utils.SendMessage(m.FromUser, "", "嘿,我的朋友,你为何要离我而去?又为何去而复返?", 0)
|
_ = utils.SendMessage(m.FromUser, m.GroupUser, "嘿,我的朋友,你为何要离我而去?又为何去而复返?", 0)
|
||||||
}
|
}
|
||||||
|
|
||||||
go func() {
|
go func() {
|
||||||
// 等待5秒
|
|
||||||
time.Sleep(5 * time.Second)
|
|
||||||
// 刷新好友列表
|
// 刷新好友列表
|
||||||
service.SyncFriend()
|
service.SyncFriend()
|
||||||
// 如果是加入群,刷新群成员列表
|
// 如果是加入群,刷新群成员列表
|
||||||
|
@ -237,7 +237,7 @@ func SyncGroupMembers(wxId string) {
|
|||||||
// 新增的
|
// 新增的
|
||||||
// 新增
|
// 新增
|
||||||
err = client.MySQL.Create(&entity.GroupUser{
|
err = client.MySQL.Create(&entity.GroupUser{
|
||||||
GroupId: wxId,
|
GroupId: wxid,
|
||||||
Account: cp.Account,
|
Account: cp.Account,
|
||||||
HeadImage: cp.HeadImage,
|
HeadImage: cp.HeadImage,
|
||||||
Nickname: cp.Nickname,
|
Nickname: cp.Nickname,
|
||||||
|
Loading…
Reference in New Issue
Block a user