Compare commits
No commits in common. "697f5560a48215b6ebaf28d9ca887b2c63171d65" and "a6e935e233e145609e0b2033947dd7aeb29b13b8" have entirely different histories.
697f5560a4
...
a6e935e233
@ -3,7 +3,7 @@ wechat:
|
||||
# 微信HOOK接口地址
|
||||
host: 10.0.0.73:19088
|
||||
# 是否在启动的时候自动设置hook服务的回调
|
||||
autoSetCallback: false
|
||||
autoSetCallback: true
|
||||
# 回调IP,如果是Docker运行,本参数必填,如果Docker修改了映射,格式为 ip:port
|
||||
callback: 10.0.0.51
|
||||
|
||||
@ -16,12 +16,12 @@ mysql:
|
||||
db: wechat
|
||||
|
||||
task:
|
||||
enable: true
|
||||
enable: false
|
||||
syncFriends:
|
||||
enable: true
|
||||
cron: '*/5 * * * *' # 五分钟一次
|
||||
cron: '0 * * * *'
|
||||
waterGroup:
|
||||
enable: false
|
||||
enable: true
|
||||
cron: '30 9 * * *'
|
||||
# 需要发送水群排行榜的群Id
|
||||
groups:
|
||||
|
@ -25,7 +25,7 @@ type GroupUser struct {
|
||||
Nickname string `json:"nickname"` // 昵称
|
||||
Wxid string `json:"wxid"` // 微信Id
|
||||
IsMember bool `json:"isMember" gorm:"type:tinyint(1)"` // 是否群成员
|
||||
LeaveTime *time.Time `json:"leaveTime"` // 离开时间
|
||||
LeaveTime time.Time `json:"leaveTime"` // 离开时间
|
||||
}
|
||||
|
||||
func (GroupUser) TableName() string {
|
||||
|
@ -26,13 +26,8 @@ func Parse(remoteAddr net.Addr, msg []byte) {
|
||||
groupUser := ""
|
||||
msgStr := m.Content
|
||||
if strings.Contains(m.FromUser, "@") {
|
||||
switch m.Type {
|
||||
case types.MsgTypeRecalled:
|
||||
// 消息撤回
|
||||
case types.MsgTypeSys:
|
||||
// 系统消息
|
||||
default:
|
||||
// 默认消息处理
|
||||
// 系统消息不单独处理
|
||||
if m.Type != types.MsgTypeRecalled && m.Type != types.MsgTypeSys {
|
||||
groupUser = strings.Split(m.Content, "\n")[0]
|
||||
groupUser = strings.ReplaceAll(groupUser, ":", "")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user