Bläddra i källkod

妥妥:合伙人协议修改

panyong 1 år sedan
förälder
incheckning
6cac877abc

+ 31 - 31
htmldev/loan/src/views/loan/apply/index.vue

@@ -11,7 +11,7 @@
           <div class="value-name">
             <input type="text" placeholder="请输入姓名" v-myBlur v-model.trim="postData.orderUserName">
           </div>
-          <div class="value-gender">
+          <div class="value-gender" v-if="false">
             <p v-for="str in ['男', '女']" :key="str" @click="postData.orderUserSex = str">
               <img src="./image/btn_xingbie_sel@2x.png" alt="" v-show="postData.orderUserSex === str">
               <img src="./image/btn_xingbie_nor@2x.png" alt="" v-show="postData.orderUserSex !== str">
@@ -45,9 +45,12 @@
         <div class="value-wrap">
           <input type="tel" placeholder="请输入验证码" v-myBlur v-model.trim="postData.code" @input="funLimitLength">
         </div>
-        <button class="get-code" @click="funGetCode">{{ [0, 60].includes(numCount) ? '获取' : numCount + '秒' }}</button>
+        <button class="get-code" @click="funGetCode">{{
+            [0, 60].includes(numCount) ? '获取' : numCount + '秒'
+          }}
+        </button>
       </li>
-      <li>
+      <li v-if="false">
         <label>
           <span v-for="(str, index) in '所在城市:'" :key="index">{{ str }}</span>
         </label>
@@ -60,7 +63,7 @@
           <img src="./image/btn_next@2x.png" alt="">
         </div>
       </li>
-      <li>
+      <li v-if="false">
         <label>
           <span v-for="(str, index) in '小区名称:'" :key="index">{{ str }}</span>
         </label>
@@ -104,6 +107,7 @@ import { Popup, Picker, Toast } from 'vant'
 import { createOrder } from './api'
 import { getChinaArea, sendSMS, getProductDetail } from '../../../api/common'
 import { funWxShare } from '../../../utils/wxShareConfig'
+import { isMobile, isSmscode } from '../../../utils/validate'
 
 const STRCAPTURE = process.env.API_DOMAIN + '/api/captcha'
 export default {
@@ -132,15 +136,15 @@ export default {
     return {
       postData: {
         orderUserName: '', // 用户名称
-        orderUserSex: '男',
+        // orderUserSex: '男',
         orderUserPhone: '', // 手机号码
         code: '', // 验证码
-        capture: '',
-        orderPrice: '', // 申请金额
-        orderProvince: '', // 省份
-        orderCity: '', // 城市
-        orderDistrict: '', // 区域
-        orderAddress: '' // 详细地址
+        // capture: '',
+        orderPrice: '' // 申请金额
+        // orderProvince: '', // 省份
+        // orderCity: '', // 城市
+        // orderDistrict: '', // 区域
+        // orderAddress: '' // 详细地址
       },
       numCount: 60,
       arrErrorList: [],
@@ -178,15 +182,15 @@ export default {
     if (!this.$route.meta.isUseCache) {
       this.postData = {
         orderUserName: '',
-        orderUserSex: '男',
+        // orderUserSex: '男',
         orderUserPhone: '',
         code: '',
-        capture: '',
-        orderPrice: '',
-        orderProvince: '',
-        orderCity: '',
-        orderDistrict: '',
-        orderAddress: ''
+        // capture: '',
+        orderPrice: ''
+        // orderProvince: '',
+        // orderCity: '',
+        // orderDistrict: '',
+        // orderAddress: ''
       }
       this.numCount = 60
       this.arrErrorList = []
@@ -260,7 +264,7 @@ export default {
         return
       }
       this.numCount = 60
-      if (!(/^1[2|3|4|5|6|7|8|9]\d{9}$/.test(orderUserPhone))) {
+      if (!isMobile(orderUserPhone)) {
         Toast('请输入手机号码')
         return
       }
@@ -287,26 +291,22 @@ export default {
       })
     },
     verifyData () {
-      const { orderUserName, orderUserSex, orderUserPhone, code, orderProvince, orderCity, orderDistrict, orderAddress, orderPrice } = this.postData
+      const {
+        orderUserName,
+        orderUserPhone,
+        code,
+        orderPrice
+      } = this.postData
       this.arrErrorList = []
       if (!orderUserName) {
         this.arrErrorList.push('请输入姓名')
       }
-      if (!orderUserSex) {
-        this.arrErrorList.push('请选择性别')
-      }
-      if (!/^1[2|3|4|5|6|7|8|9]\d{9}$/.test(orderUserPhone)) {
+      if (!isMobile(orderUserPhone)) {
         this.arrErrorList.push('请输入手机号码')
       }
-      if (!(/^\d{4}$/.test(code))) {
+      if (!isSmscode(code)) {
         this.arrErrorList.push('请输入验证码')
       }
-      if (!orderProvince || !orderCity || !orderDistrict) {
-        this.arrErrorList.push('请选择所在城市')
-      }
-      if (!orderAddress) {
-        this.arrErrorList.push('请输入小区名称')
-      }
       if (orderPrice * 1 <= 0) {
         this.arrErrorList.push('请输入需求金额')
       }

+ 11 - 4
htmldev/loan/src/views/loan/explain/index.vue

@@ -121,12 +121,19 @@ export default {
       }
     }
   },
-  created () {
-    this.fetchUserShare()
-  },
   async mounted () {
     await this.$nextTick()
-    this.funGetProductDetail()
+    if (!this.partnerId) {
+      this.fetchUserShare()
+      this.funGetProductDetail()
+    } else {
+      this.$router.replace({
+        path: '/loan/apply/' + this.orderProductId,
+        query: {
+          partnerId: this.partnerId
+        }
+      })
+    }
   },
   methods: {
     // 获取用户分享权限

+ 1 - 0
htmldev/loan/src/views/partner/goods/index.vue

@@ -161,6 +161,7 @@ export default {
       this.posterBg = productShareUrl
       this.$set(this.codeParams, 'link', `${location.origin}/loan/explain/${id}?partnerId=${this.partnerId}`)
       this.$nextTick(() => {
+        console.log(this.codeParams)
         this.$refs.myPoster.createQRCode()
       })
     }