Browse Source

fix:修改资产找回页面 绑定手机号提示

xyh8905170 2 years ago
parent
commit
811633e3da
3 changed files with 37 additions and 16 deletions
  1. 2 2
      common/js/env.js
  2. 18 0
      myPages/systemSwitch/index.vue
  3. 17 14
      pages/my/index.vue

+ 2 - 2
common/js/env.js

@@ -1,9 +1,9 @@
 "use strict";
 
 // let baseUrl = `https://jje.admin.xinyuekj.com.cn`
-let baseUrl = `https://jje.xinyuekj.com.cn/prod-api`
+// let baseUrl = `https://jje.xinyuekj.com.cn/prod-api`
 /** 测试环境 */
-// let baseUrl = `https://jje.admin.xinyuekj.com.cn/test-api`
+let baseUrl = `https://jje.admin.xinyuekj.com.cn/test-api`
 /** 开发环境*/
 // let baseUrl = `http://65i1sxopd9qp.ngrok.xiaomiqiu123.top`
 

+ 18 - 0
myPages/systemSwitch/index.vue

@@ -553,6 +553,9 @@ export default {
     },
     nextStep(idx) {
       if (idx == 0) { // 点击确认
+        console.log(this.userInfo.phone)
+
+
         if (this.isSelect === true) {
           this.$refs.popup.close()
           // this.getOldMember();
@@ -574,6 +577,21 @@ export default {
       }
 
       if (idx == 1) { // 点击查询数据
+        const userInfo = uni.getStorageSync('userInfo')
+        // console.log(userInfo,'绑定手机号')
+        if (!userInfo.phone){
+          uni.showModal({
+            title:'温馨提示',
+            content:'资产找回涉及资金安全,需绑定手机号才能进行查询',
+            success:res=>{
+              if (res.confirm){
+                uni.navigateTo({
+                  url: '/myPages/setting/setting-telphone',
+                })
+              }
+            }
+          })
+        }
         this.$refs.form1.validate().then(res => {
           this.getOldMember();
         }).catch(errors => {

+ 17 - 14
pages/my/index.vue

@@ -157,23 +157,26 @@ export default {
   methods: {
     clickListItem(e){
       console.log(e)
-      if (!this.userInfo.phone && e.title==='资产找回'){
-        uni.showModal({
-          title:'温馨提示',
-          content:'资产找回请先绑定手机号',
-          success:res=>{
-            if (res.confirm){
-              uni.navigateTo({
-                url: '/myPages/setting/setting-telphone',
-              })
-            }
-          }
-        })
-      }else {
+      // if (!this.userInfo.phone && e.title==='资产找回'){
+      //   uni.navigateTo({
+      //     url:e.to
+      //   })
+      //   uni.showModal({
+      //     title:'温馨提示',
+      //     content:'资产找回请先绑定手机号',
+      //     success:res=>{
+      //       if (res.confirm){
+      //         uni.navigateTo({
+      //           url: '/myPages/setting/setting-telphone',
+      //         })
+      //       }
+      //     }
+      //   })
+      // }else {
         uni.navigateTo({
           url:e.to
         })
-      }
+      // }
     },
     getUserInfo() {
       this.$api.getUserInfo().then(res => {