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

弹出的Web页面怎么才可以有【二维码扫码登录】的选项 #63

Open
bliu8710 opened this issue Jun 19, 2024 · 1 comment

Comments

@bliu8710
Copy link

我的这个登录页面正常打开了。如图。

只有手机验证码,以及账号密码登录可选。

我想问这个web页面怎么才可以有【二维码扫码登录】的选项

image

我的代码截取如下,按下Button调用authorize

Button("Authorize") {
                    Task {
                        do {
                            let userInfo = try await client.authorize(credentials: .pkce)
                                .send(AliyunpanScope.User.GetUsersInfo())
                            self.userInfo = userInfo
                        } catch {
                            print("Authorize ERR: ", error)
                        }
                    }
                }
                .font(.largeTitle)
@ohmyharry
Copy link

移动端H5的登录框,是没有二维码登录的,大部分用户不会用A手机扫B手机登录
如果是大屏,有两种方案:

  1. 你可控的容器可以通过改成桌面端UA来实现展示web端授权页面,那个页面有二维码
  2. 如果有服务端也可以参考手机扫码授权模式 https://www.yuque.com/aliyundrive/zpfszx/ttfoy0xt2pza8lof

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

No branches or pull requests

2 participants