lsc 1 هفته پیش
والد
کامیت
29502a7722
1فایلهای تغییر یافته به همراه9 افزوده شده و 8 حذف شده
  1. 9 8
      src/App.vue

+ 9 - 8
src/App.vue

@@ -222,14 +222,15 @@ const selectUser2 = (uid) => {
     const requestUser = () => {
     const requestUser = () => {
       axios.get(`https://pbl.cocorobo.cn/api/pbl/selectUser?userid=${uid}`)
       axios.get(`https://pbl.cocorobo.cn/api/pbl/selectUser?userid=${uid}`)
         .then(res => {
         .then(res => {
-            if (res && res.value && res.value.length && res.value[0].length && res.value[0][0].userid) {
-                // 拉取成功,存储用户信息
-                isShow.value = false;
-                topUserInfo.value = res.value[0][0];
-                store.setUserInfo(res.value[0][0]);
-            } else {
-                requestUser();
-            }
+          console.log(res);
+          if (res && res.data && res.data.length && res.data[0].length && res.data[0][0].userid) {
+              // 拉取成功,存储用户信息
+              isShow.value = false;
+              topUserInfo.value = res.data[0][0];
+              store.setUserInfo(res.data[0][0]);
+          } else {
+              requestUser();
+          }
       })
       })
     };
     };