-
Notifications
You must be signed in to change notification settings - Fork 1
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
一码通与自动重登逻辑 #23
一码通与自动重登逻辑 #23
Conversation
…le enhancements - Added error handling for login and getPayCode functions. - Enhanced styles for input fields and QR code container. - Ensured proper handling of empty objects to avoid null reference errors.
…efresh, and improved UI elements
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
能否将登录逻辑拆到 @/lib/ymt-login.ts
内?拆分方式类似 #22 中的 @/lib/user-login.ts
,拆分后的页面逻辑类似 @/app/login.tsx
。
…sh, and improved UI elements
…nd error handling.
这里标记哦个一下还需要做的事情,以免遗忘:
|
我在 #25 中对 |
出现了一堆冲突,这个 pr 要不要考虑先合入?然后后面样式再慢慢改?@renbaoshuo,还是说要改的不是 UI 之类的 |
目前已经完成主分支代码的合入和调整,我这边完善了一码通的身份认证页面设计,以及调整了登录逻辑,现在的逻辑是点击【一码通】就会自动检查是否存在 token,如果不存在则跳入统一身份认证登录页面 这套设计实际上并不合理,因为用户可能并不想登录,我们没有提供选择权。同时这个判断方式有点粗暴,另外,这个 accessToken 在 asyncStorage 中会和我们 jwch 接口的 access_token 存在歧义,需要解决,@klxiaoniu @renbaoshuo |
色值尽量不用固定颜色,用global.css中定义的颜色,避免不同主题下的问题 |
throw { | ||
type: RejectEnum.NativeLoginFailed, | ||
data: '自动验证码识别失败', | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里建议 throw 一个 Error 出来,可以在 @/lib/error
里面定义一个 NativeLoginFailedError
,在外面用 err instanceof NativeLoginFailedError
即可判断。
No description provided.