28 lines
609 B
Go
28 lines
609 B
Go
package controller
|
|
|
|
import (
|
|
"fmt"
|
|
"github.com/eatmoreapple/openwechat"
|
|
"go-bot/bot/tool"
|
|
)
|
|
|
|
var self = tool.GetCurrentUser()
|
|
|
|
func SignInBegin(msg *openwechat.Message) {
|
|
groups, err := tool.GetGroups()
|
|
name := groups.GetByNickName("叫啥好呢")
|
|
fmt.Printf(name.NickName, err)
|
|
|
|
// 发送到微信
|
|
self.SendTextToGroup(name, "打卡程序启动成功!")
|
|
}
|
|
|
|
func SignInEnd(msg *openwechat.Message) {
|
|
groups, err := tool.GetGroups()
|
|
name := groups.GetByNickName("叫啥好呢")
|
|
fmt.Printf(name.NickName, err)
|
|
|
|
// 发送到微信
|
|
self.SendTextToGroup(name, "打卡程序结束运行成功!")
|
|
}
|