Browse Source

✨ feat: 取消对密码的依赖

Pchen. 2 months ago
parent
commit
32ee149d92
1 changed files with 10 additions and 10 deletions
  1. 10 10
      apis/Lepao/Account/AddAccount.js

+ 10 - 10
apis/Lepao/Account/AddAccount.js

@@ -68,9 +68,9 @@ class AddAccount extends API {
 
 
         // 判断是否重复注册
         // 判断是否重复注册
         if (!id) {
         if (!id) {
-            if (!password) {
-                return res.json({ ...BaseStdResponse.ERR, msg: '请输入乐跑账号密码' })
-            }
+            // if (!password) {
+            //     return res.json({ ...BaseStdResponse.ERR, msg: '请输入乐跑账号密码' })
+            // }
 
 
             if (countRows.length !== 0 && countRows[0].create_user != null) {
             if (countRows.length !== 0 && countRows[0].create_user != null) {
                 if (countRows[0].create_user !== uuid)
                 if (countRows[0].create_user !== uuid)
@@ -79,13 +79,13 @@ class AddAccount extends API {
             }
             }
 
 
             // 进行密码校验
             // 进行密码校验
-            try {
-                password = atob(password)
-                await lepaoAuth(student_num, password)
-            } catch (err) {
-                this.logger.info(`乐跑账号验证失败!${err.message}`)
-                return res.json({ ...BaseStdResponse.ERR, msg: err.message ?? '无法验证乐跑账号,请联系客服或稍后再试' })
-            }
+            // try {
+            //     password = atob(password)
+            //     await lepaoAuth(student_num, password)
+            // } catch (err) {
+            //     this.logger.info(`乐跑账号验证失败!${err.message}`)
+            //     return res.json({ ...BaseStdResponse.ERR, msg: err.message ?? '无法验证乐跑账号,请联系客服或稍后再试' })
+            // }
         }
         }
 
 
         if (countRows.length !== 0) {
         if (countRows.length !== 0) {