|
@@ -82,6 +82,20 @@ graph TB
|
|
|
- initLoginModal 初始化登录模块
|
|
|
- app-login 登录页
|
|
|
- new ParseAuthing实例化authing登录服务,通过login成功后回调调用AuthServr服务类,profileVerify处理登录成功后函数
|
|
|
+ ```let parseAuthing = new ParseAuthing({
|
|
|
+ // 监听事件:登陆成功后,返回用户信息
|
|
|
+ login:(user,authClient)=>{
|
|
|
+ console.log(user)
|
|
|
+ console.log(Parse.User.current());
|
|
|
+ Parse.User.current()?.id && this.authServr.profileVerify(this.modal)
|
|
|
+ },
|
|
|
+ beforeChangeModule:(data:any)=>{
|
|
|
+ if(data=='register'){
|
|
|
+ this.router.navigate(['/user/account_info'])
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
+ parseAuthing.initLoginModal();```
|
|
|
##### 作者/教师/主编
|
|
|
- 路由模块:`NavAuthorRoutingModule`
|
|
|
- 个人空间:app-space
|