This commit is contained in:
苏尹岚
2021-04-07 16:48:23 +08:00
parent bf35e6a26d
commit bac4c55835
7 changed files with 9 additions and 11 deletions

View File

@@ -0,0 +1,26 @@
package partner
import (
"git.rosy.net.cn/jx-callback/business/jxutils/jxcontext"
)
var (
HandlerMap map[int]UnionInterface
)
const (
LinkTypeWeiXinMini = 1 //微信小程序
LinkTypeH5 = 2 //H5
)
func init() {
HandlerMap = make(map[int]UnionInterface)
}
type UnionInterface interface {
ShareUnionLink(ctx *jxcontext.Context, linkType int) (link string, err error)
}
func GetHandler(vendorID int) UnionInterface {
return HandlerMap[vendorID]
}