Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

增加开放平台授权方小程序登录 #634

Open
wants to merge 1 commit into
base: v2
Choose a base branch
from

Conversation

baiyishaoxia
Copy link

No description provided.

@silenceper
Copy link
Owner

silenceper commented Dec 14, 2022

这部分可用使用这里的https://github.com/silenceper/wechat/blob/v2/miniprogram/auth/auth.go 中的方法吗,有没有必要重复写这部分逻辑?

GitHub
WeChat SDK for Go (微信SDK:简单、易用). Contribute to silenceper/wechat development by creating an account on GitHub.

@baiyishaoxia
Copy link
Author

这部分可用使用这里的https://github.com/silenceper/wechat/blob/v2/miniprogram/auth/auth.go 中的方法吗,有没有必要重复写这部分逻辑?

GitHub**wechat/auth.go at v2 · silenceper/wechat**WeChat SDK for Go (微信SDK:简单、易用). Contribute to silenceper/wechat development by creating an account on GitHub.

这部分可用使用这里的https://github.com/silenceper/wechat/blob/v2/miniprogram/auth/auth.go 中的方法吗,有没有必要重复写这部分逻辑?

GitHub**wechat/auth.go at v2 · silenceper/wechat**WeChat SDK for Go (微信SDK:简单、易用). Contribute to silenceper/wechat development by creating an account on GitHub.

小程序服务商模式,即第三方平台代替小程序实现登录功能登录接口是变动的,参考:https://open.weixin.qq.com/cgi-bin/showdocument?action=dir_list&t=resource/res_list&verify=1&id=open1492585163_FtTNA&token=&lang=zh_CN

@baiyishaoxia
Copy link
Author

baiyishaoxia commented Dec 14, 2022

@@ -72,6 +73,11 @@ func (miniProgram *MiniProgram) GetURLLink() *urllink.URLLink {
})
}

// GetAuth 登录/用户信息相关接口
func (miniProgram *MiniProgram) GetAuth() *auth.Auth {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里是不是需要使用单例呢?

Suggested change
func (miniProgram *MiniProgram) GetAuth() *auth.Auth {
func (miniProgram *MiniProgram) GetAuth() *auth.Auth {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants