From 83d4de4287b13662e8fafec57b8ac0ab5948bf85 Mon Sep 17 00:00:00 2001 From: luyuan <1162963624@qq.com> Date: Fri, 20 Nov 2020 14:16:14 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E4=B8=BA=E5=88=A4=E6=96=ADdata?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/index.ts | 20 +++++++------------- src/views/login/Reset.vue | 4 ++-- src/views/login/Sign.vue | 2 +- 3 files changed, 10 insertions(+), 16 deletions(-) diff --git a/src/api/index.ts b/src/api/index.ts index 3086222..2c41814 100644 --- a/src/api/index.ts +++ b/src/api/index.ts @@ -608,22 +608,16 @@ export async function checkuser(data?: any){ newdata.number=data.phone const res = await get('checkUser',newdata); // console.log(res) - if(res.code == 1){ - return { - code: res.code, - msg: res.msg, - } - } + // if(res.code == 1){ + // return { + // code: res.code, + // msg: res.msg, + // } + // } return { code: res.code, msg: res.msg, - data: { - memberid: res.data.memberid, - name: res.data.name, - mobile: res.data.mobile, - email: res.data.email, - code: res.data.code - } + data: res.data } } diff --git a/src/views/login/Reset.vue b/src/views/login/Reset.vue index 8e1ad7a..99647b4 100644 --- a/src/views/login/Reset.vue +++ b/src/views/login/Reset.vue @@ -171,8 +171,8 @@ export default defineComponent({ if(e==2){ console.log(uinfo) const res: any = await checkuser(toRaw(uinfo.value)) - console.log(res.data.memberid) - if(res.code==0){ + // console.log(res.data) + if(res.data){ // stepnow.value = e; uinfo.value.quhao = res.data.code.toString() uinfo.value.memberid=res.data.memberid diff --git a/src/views/login/Sign.vue b/src/views/login/Sign.vue index 6d68e00..78d71f0 100644 --- a/src/views/login/Sign.vue +++ b/src/views/login/Sign.vue @@ -293,7 +293,7 @@ export default defineComponent({ return; } const iszc = await checkuser({phone: phone.value.phone}) - if(iszc.code == 0){ + if(iszc.data){ message.error(lan.$t('zhanghaocunzai')) return ; }