mirror of
https://github.com/silenceper/wechat.git
synced 2026-02-07 14:12:27 +08:00
补丁
This commit is contained in:
16
work/work.go
16
work/work.go
@@ -9,12 +9,15 @@ import (
|
||||
"github.com/silenceper/wechat/v2/work/context"
|
||||
"github.com/silenceper/wechat/v2/work/externalcontact"
|
||||
"github.com/silenceper/wechat/v2/work/invoice"
|
||||
"github.com/silenceper/wechat/v2/work/js"
|
||||
"github.com/silenceper/wechat/v2/work/kf"
|
||||
"github.com/silenceper/wechat/v2/work/material"
|
||||
"github.com/silenceper/wechat/v2/work/message"
|
||||
"github.com/silenceper/wechat/v2/work/msgaudit"
|
||||
"github.com/silenceper/wechat/v2/work/oauth"
|
||||
"github.com/silenceper/wechat/v2/work/robot"
|
||||
"github.com/silenceper/wechat/v2/work/server"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// Work 企业微信
|
||||
@@ -91,3 +94,16 @@ func (wk *Work) GetInvoice() *invoice.Client {
|
||||
func (wk *Work) GetCheckin() *checkin.Client {
|
||||
return checkin.NewClient(wk.ctx)
|
||||
}
|
||||
|
||||
// GetJs js-sdk配置
|
||||
func (wk *Work) GetJs() *js.Js {
|
||||
return js.NewJs(wk.ctx)
|
||||
}
|
||||
|
||||
// GetServer 消息管理:接收事件,被动回复消息管理
|
||||
func (wk *Work) GetServer(req *http.Request, writer http.ResponseWriter) *server.Server {
|
||||
srv := server.NewServer(wk.ctx)
|
||||
srv.Request = req
|
||||
srv.Writer = writer
|
||||
return srv
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user