longzhicheng 1 год назад
Родитель
Сommit
a4e04bd26f
28 измененных файлов с 748 добавлено и 532 удалено
  1. 1 0
      pages.config.ts
  2. 2 2
      src/apis/user.ts
  3. 1 1
      src/components/CXBPhoneLoginButton/CXBPhoneLoginButton.vue
  4. 0 1
      src/pages/order/components/AllItemList.vue
  5. 16 12
      src/pages/order/components/ObligationOrderList.vue
  6. 1 21
      src/pages/order/components/OrderObligationItem.vue
  7. 5 33
      src/pages/order/index.vue
  8. 2 2
      src/pages/order_addcart/index.vue
  9. 55 10
      src/pages/real-name-authentication/components/authentication-success.vue
  10. 335 301
      src/pages/real-name-authentication/index.vue
  11. 215 45
      src/pages/third_party_binding/index.vue
  12. 4 3
      src/pages/user/index.vue
  13. 1 1
      src/pages/user/login/index.vue
  14. BIN
      src/static/icon/user_xx_icon.png
  15. 13 13
      src/subPages/pages/bankDetail/index.vue
  16. 14 5
      src/subPages/pages/immediate-withdrawal/index.vue
  17. 5 3
      src/subPages/pages/mine-top/brokerage.vue
  18. 1 1
      src/subPages/pages/mine-top/contribute.vue
  19. 1 1
      src/subPages/pages/mine-top/jifen.vue
  20. 1 1
      src/subPages/pages/mine-top/jingdou.vue
  21. 21 25
      src/subPages/pages/mine-top/qianbao.vue
  22. 1 1
      src/subPages/pages/mine-top/repurchase.vue
  23. 8 21
      src/subPages/pages/mine-top/vr.vue
  24. 2 2
      src/subPages/pages/order/logistics.vue
  25. 35 22
      src/subPages/pages/quick-fuc/business.vue
  26. 2 2
      src/subPages/pages/store/product/detail.vue
  27. 2 2
      src/subPages/pages/store/product/other.vue
  28. 4 1
      src/subPages/pages/withdrawal-record/index.vue

+ 1 - 0
pages.config.ts

@@ -51,4 +51,5 @@ export default defineUniPages({
51 51
 		backgroundColorTop: '@bgColorTop',
52 52
 		backgroundColorBottom: '@bgColorBottom',
53 53
 	},
54
+	
54 55
 })

+ 2 - 2
src/apis/user.ts

@@ -296,10 +296,10 @@ export function apigetAccount() {
296 296
     })
297 297
 }
298 298
 
299
-export function apiTransitionVr(num:any) {
299
+export function apiTransitionVr(num:any,type:any) {
300 300
     return defHttp.post({
301 301
         url: API.TRANSITION_VR,
302
-		data:{extract_amount:num}
302
+		data:{extract_amount:num ,type:type}
303 303
     })
304 304
 }
305 305
 

+ 1 - 1
src/components/CXBPhoneLoginButton/CXBPhoneLoginButton.vue

@@ -31,7 +31,7 @@ function getPhoneNumber(e) {
31 31
             encryptedData: e.detail.encryptedData,
32 32
             iv: e.detail.iv,
33 33
           }
34
-		  openId= unionRes.openid
34
+		  openId= unionRes.unionid
35 35
           if (shareId) {
36 36
             params.share_id = shareId
37 37
           }

+ 0 - 1
src/pages/order/components/AllItemList.vue

@@ -143,7 +143,6 @@ onUnmounted(() => {
143 143
   <div class="p-3 flex flex-col">
144 144
     <div v-if="state.list.length > 0" class="flex flex-col gap-3">
145 145
       <div v-for="(orderItem, index) in state.list" :key="index">
146
-		  {{orderItem.source}}
147 146
        <OrderItem :receivegoods="0" :order-item="orderItem" v-if="orderItem.source == 7" />
148 147
 		<OtherOrderItem :item="orderItem" v-else />
149 148
       </div>

+ 16 - 12
src/pages/order/components/ObligationOrderList.vue

@@ -33,30 +33,34 @@ function loadList(action: 'page' | 'reload', callback?: (items) => void) {
33 33
     page: state.currentPage,
34 34
     limit: state.pageSize,
35 35
   }).then((res) => {
36
-    console.log('>>>>>>111', res)
36
+	  
37
+	  console.log("===res",res);
37 38
     if (res.list.length <= 0) {
38 39
       uni.$emit('changeShowLike')
39 40
       console.log('没有数据')
40 41
 	  state.list = res.list
41
-	  if (callback)
42
-	    callback(res.list)
43
-
42
+	  if (callback){
43
+		  callback(res.list)
44
+	  }
44 45
       return
45 46
     }
46 47
     if (res.count < state.pageSize)
47 48
       uni.$emit('changeShowLike')
48 49
 
49
-    if (action === 'page')
50
-      state.list = state.list.concat(res.list)
50
+   if (action === 'page')
51
+     state.list = state.list.concat(res.list)
51 52
 
52
-    if (action == 'reload')
53
-      state.list = res.list
53
+   if (action == 'reload')
54
+     state.list = res.list
54 55
 
55 56
     state.totalPage = Math.ceil(res.total / state.pageSize)
56 57
 
57
-    state.status = 'more'
58
-    if (callback)
59
-      callback(res.list)
58
+   state.status = 'more'
59
+    if (callback){
60
+	 	callback(res.list)
61
+   }
62
+	
63
+	
60 64
   })
61 65
 }
62 66
 watch(() => state.status, (newStatus, oldStatus) => {
@@ -114,7 +118,7 @@ onUnmounted(() => {
114 118
 <template>
115 119
   <div class="p-3 flex flex-col">
116 120
     <div v-if="state.list.length > 0" class="flex flex-col">
117
-      <div v-for="(orderItem, index) in state.list" :key="index">
121
+      <div v-for="(orderItem, index) in state?.list" :key="index">
118 122
         <!--        <OrderItem :order-item="orderItem" /> -->
119 123
         <!--        <OtherOrderItem :item="orderItem" v-else/> -->
120 124
         <OrderObligationItem :order-item="orderItem" :tab-value="props.tabValue" />

+ 1 - 21
src/pages/order/components/OrderObligationItem.vue

@@ -26,28 +26,8 @@ const props = defineProps({
26 26
 
27 27
 
28 28
 
29
-
30
-// function detailOrderList(p) {}
31
-// const dealOrderList =computed(() => {
32
-//   if (props.orderItem) {
33
-//     const orderItem = props.orderItem
34
-//     if (orderItem?.orderList) {
35
-//       return orderItem.orderList
36
-//     }
37
-//     if (orderItem?.orderProduct) {
38
-//       return orderItem.orderProduct
39
-//     }
40
-//   }
41
-// })
42 29
 function getStatusText(orderItem: OrderListModel) {
43
-  // if (props.status === 5) {
44
-  //   return '未支付'
45
-  // }
46
-  // if (props.status === 0) {
47
-  //   return '待发货'
48
-  // }
49
-  // switch (orderItem.status) {
50
-  // }
30
+
51 31
   if (orderItem.status == 0) {
52 32
     return '待发货'
53 33
   }

+ 5 - 33
src/pages/order/index.vue

@@ -76,6 +76,7 @@ function loadList(action: 'page' | 'reload', callback?: (items) => void) {
76 76
   getRecommendList({
77 77
     ...params
78 78
   }).then(res => {
79
+	  
79 80
     if (action === 'page') {
80 81
       state.list = state.list.concat(res.list)
81 82
     }
@@ -85,6 +86,7 @@ function loadList(action: 'page' | 'reload', callback?: (items) => void) {
85 86
     }
86 87
     state.totalPage = Math.ceil(res.count / state.pageSize);
87 88
     state.statusLike = 'more'
89
+	
88 90
     if (callback) {
89 91
       callback(res.list)
90 92
     }
@@ -110,6 +112,7 @@ function handleProductItemClick(
110 112
 
111 113
 onReachBottom(() => {
112 114
   // handleScrollToLower()
115
+  
113 116
   if (state.tabvalue == 0) {
114 117
     uni.$emit('onTab0ReachBottom')
115 118
   }
@@ -149,11 +152,7 @@ onPullDownRefresh(() => {
149 152
   if (nomore.value == 'nomore') {
150 153
     handleScrollToLower()
151 154
   }
152
-  // loadList('reload', items => {
153
-  //   setTimeout(() => {
154
-  //     uni.stopPullDownRefresh()
155
-  //   }, 300)
156
-  // })
155
+
157 156
 })
158 157
 
159 158
 watch(() => state.tabvalue, (newStatus, oldStatus) => {
@@ -235,34 +234,7 @@ function onClickLeft() {
235 234
       <Order3List v-if="state.tabvalue == 3" :status="'1'" />
236 235
       <Order4List v-if="state.tabvalue == 4" :status="'2'" />
237 236
     </div>
238
-    <!-- 商品推荐 -->
239
-    <div v-if="toshow == true">
240
-      <div class="flex flex-row justify-center items-center gap-3 font-bold text-sm p-3">
241
-        <image :src="like_adorn_220628Image" mode="widthFix" class="w-6 h-6"></image>
242
-        <div>
243
-          精品推荐
244
-        </div>
245
-        <image :src="like_adorn_220628Image" mode="widthFix" class="w-6 h-6"></image>
246
-      </div>
247
-      <div class="pb-3 px-3 pb-safe" v-if="state.list">
248
-        <grid-view type="masonry" cross-axis-count="2" cross-axis-gap="10px" main-axis-gap="10px">
249
-          <div v-for="(item, index) in state.list" :key="index" @click="handleProductItemClick(item)">
250
-            <MerchantProductCard :item="item" />
251
-
252
-          </div>
253
-        </grid-view>
254
-
255
-        <div class=" flex justify-center items-center text-[12px] text-gray-500">
256
-          <div v-if="state.statusLike === 'loading'">
257
-            加载中...
258
-          </div>
259
-          <div v-if="state.statusLike === 'noMore'">
260
-            没有更多了~
261
-          </div>
262
-        </div>
263
-      </div>
264
-
265
-    </div>
237
+    
266 238
   </div>
267 239
   <!--  </CXBBasePage>-->
268 240
 </template>

+ 2 - 2
src/pages/order_addcart/index.vue

@@ -786,13 +786,13 @@ function handlePageClick() {
786 786
       </div>
787 787
 
788 788
       <div class="pb-12" >
789
-        <div class="flex flex-row justify-center items-center gap-3 font-bold text-sm p-3 ">
789
+        <!-- <div class="flex flex-row justify-center items-center gap-3 font-bold text-sm p-3 ">
790 790
           <image :src="like_adorn_220628Image" mode="widthFix" class="w-6 h-6"></image>
791 791
           <div>
792 792
             精品推荐
793 793
           </div>
794 794
           <image :src="like_adorn_220628Image" mode="widthFix" class="w-6 h-6"></image>
795
-        </div>
795
+        </div> -->
796 796
 
797 797
         <div class="pb-3 px-3" v-if="state.recommendList">
798 798
           <grid-view type="masonry" cross-axis-count="2" cross-axis-gap="10px" main-axis-gap="10px">

+ 55 - 10
src/pages/real-name-authentication/components/authentication-success.vue

@@ -1,17 +1,62 @@
1 1
 <script setup lang="ts">
2
-import {CDN_URL} from "~/config/app";
2
+	import { CDN_URL } from "~/config/app";
3
+	const props = defineProps({
4
+	  formData: {
5
+	    type: Object,
6
+	    default: {}
7
+	  }
8
+	})
3 9
 
4
-const image = CDN_URL + '/static/assets/authentication_success_220714.png'
10
+	const image = CDN_URL + '/static/assets/authentication_success_220714.png'
5 11
 </script>
6 12
 <template>
7 13
 
8
-  <div>
9
-    <div class="flex flex-col justify-center items-center gap-3 bg-white p-4">
10
-      <image :src="image" mode="widthFix" class="w-12 h-12"></image>
11
-      <div>
12
-        您已通过实名认证
13
-      </div>
14
-    </div>
14
+	<div>
15
+		<div class="flex flex-col justify-center items-center gap-3 bg-white p-4">
16
+			<image :src="image" mode="widthFix" class="w-12 h-12"></image>
17
+			<div class="main-title">
18
+				您已完成实名认证
19
+			</div>
15 20
 
16
-  </div>
21
+		</div>
22
+
23
+	</div>
17 24
 </template>
25
+
26
+<style scoped lang="scss">
27
+	.main-title {
28
+		font-size: 30rpx;
29
+		color: #333;
30
+
31
+	}
32
+
33
+	.user-content {
34
+		display: flex;
35
+		flex-direction: column;
36
+		width: 100%;
37
+		
38
+		.user-item-line{
39
+			width: 100%;
40
+			height: 1rpx;
41
+			background-color: #eeeeee;
42
+		}
43
+	}
44
+
45
+	.user-item {
46
+		display: flex;
47
+		flex-direction: row;
48
+		align-items: center;
49
+		padding: 30rpx 40rpx;
50
+
51
+		.user-item-title {
52
+			font-size: 26rpx;
53
+			color: #333;
54
+			flex: 1;
55
+		}
56
+
57
+		.user-item-des {
58
+			font-size: 26rpx;
59
+			color: #999;
60
+		}
61
+	}
62
+</style>

+ 335 - 301
src/pages/real-name-authentication/index.vue

@@ -1,314 +1,348 @@
1 1
 <script setup lang="ts">
2
-import {CDN_URL} from "~/config/app";
3
-import {UPLOAD_URL} from "~/utils/http";
4
-import {getToken} from "~/utils/auth";
5
-import {uploadImageOne} from "~/utils/upload";
6
-import {backdropFilterBase} from "unocss-preset-weapp/rules";
7
-import {getCertificationInfo, submitCertification} from "~/apis/user";
8
-import AuthenticationSuccess from "~/pages/real-name-authentication/components/authentication-success.vue";
9
-import type {CertificationRequest} from "~/apis/model/certification.model";
10
-
11
-const front_220714Image = CDN_URL + '/static/assets/front_220714.png'
12
-const verso_220714Image = CDN_URL + '/static/assets/verso_220714.png'
13
-
14
-const userStore = useUserStore()
15
-
16
-const formData = reactive({
17
-  user_name: '',
18
-  user_card: '',
19
-  mobile: '',
20
-  card_positive: '',
21
-  card_reverse: '',
22
-})
23
-
24
-const state = reactive({
25
-  isLoading: false,
26
-  isFormValidate: false,
27
-  // 审核中
28
-  isReview: false,
29
-  // 已认证
30
-  isCertified: false,
31
-  isNoCertified: true,
32
-  // 审核失败
33
-  isFail: false
34
-
35
-})
36
-onLoad(async () => {
37
-  await userStore.getUserInfo()
38
-  console.log(userStore.userInfo)
39
-  console.log(userStore.userInfo.is_ertification)
40
-  if (userStore.userInfo.is_ertification === -1) {
41
-    state.isNoCertified = true
42
-  }
43
-
44
-  getCertificationInfo(1).then(res => {
45
-
46
-    // console.log(res)
47
-    if (res.uid && res.status === '1') {
48
-      state.isCertified = true
49
-
50
-      formData.user_card = res.user_card.replace(/^(\d{4})\d+(\d{4})$/, '$1********$2')
51
-      formData.user_name = formatName(res.user_name)
52
-      formData.card_positive = res.card_positive
53
-      formData.card_reverse = res.card_reverse
54
-
55
-    }
56
-  }).catch(error => {
57
-    uni.showToast({
58
-      title: error,
59
-      icon: 'none'
60
-    })
61
-    uni.hideLoading()
62
-
63
-  })
64
-})
65
-
66
-const certificationStatus =  computed(() => {
67
-  let statusMsg = ''
68
-  switch (userStore.userInfo.is_ertification) {
69
-    case 0: {
70
-      statusMsg = '审核中'
71
-      break;
72
-    }
73
-    case 1: {
74
-      statusMsg = '已认证'
75
-      break;
76
-    }
77
-    case 2: {
78
-      statusMsg = '已拒绝,重新提交'
79
-      break;
80
-    }
81
-    default: {
82
-      statusMsg = '立即认证'
83
-      break;
84
-    }
85
-  }
86
-  return statusMsg
87
-})
88
-
89
-const headers = {
90
-  // #ifdef MP
91
-  "Content-Type": "multipart/form-data",
92
-  // #endif
93
-  "X-Token": 'Bearer ' + getToken()
94
-}
95
-
96
-
97
-function handleUploadImg(type: 'positive' | 'reverse') {
98
-  if (state.isCertified) {
99
-    return
100
-  }
101
-  uploadImageOne('upload/image', (res) => {
102
-    if (type === 'positive') {
103
-      formData.card_positive = res.data.path
104
-      console.log(formData.card_positive)
105
-    }
106
-    if (type === 'reverse') {
107
-      formData.card_reverse = res.data.path
108
-      console.log(formData.card_reverse)
109
-    }
110
-  })
111
-}
112
-function validateForm() {
113
-
114
-  if (formData.user_name === '') {
115
-    uni.showToast({
116
-      title: '请填写姓名',
117
-      icon: 'none'
118
-    })
119
-    // return isValidate
120
-    return state.isFormValidate = false
121
-  }
122
-  if (!(/^[\u4e00-\u9fa5]{2,4}$/.test(formData.user_name))) {
123
-    uni.showToast({
124
-      title: '请正确输入您的姓名',
125
-      icon: 'none'
126
-    })
127
-    return state.isFormValidate = false
128
-  }
129
-
130
-  // if (formData.mobile === '') {
131
-  //   uni.showToast({
132
-  //     title: '请填写手机号',
133
-  //     icon: 'none'
134
-  //   })
135
-  //   return state.isFormValidate = false
136
-  // }
137
-
138
-  // if (!/^1(3|4|5|7|8|9|6)\d{9}$/i.test(formData.mobile)) {
139
-  //    uni.showToast({
140
-  //     title: '请填写正确的手机号',
141
-  //     icon: 'none'
142
-  //   })
143
-  //   return state.isFormValidate = false
144
-  //
145
-  // }
146
-
147
-  if (formData.user_card === '') {
148
-     uni.showToast({
149
-      title: '请填写身份证号',
150
-      icon: 'none'
151
-    })
152
-    return state.isFormValidate = false
153
-
154
-  }
155
-
156
-  if (!/^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}([0-9]|X|x)$/.test(formData.user_card)) {
157
-    uni.showToast({
158
-      title: "请填写正确身份证号",
159
-      icon: "none"
160
-    });
161
-    return state.isFormValidate = false
162
-
163
-  }
164
-
165
-  if (formData.card_positive === '') {
166
-    uni.showToast({
167
-      title: '请上传身份证人像面图',
168
-      icon: 'none'
169
-    })
170
-    return state.isFormValidate = false
171
-
172
-  }
173
-  if (formData.card_reverse === '') {
174
-    uni.showToast({
175
-      title: '请上传身份证国徽面图'
176
-    })
177
-    return state.isFormValidate = false
178
-
179
-  }
180
-
181
-  return state.isFormValidate = true
182
-}
183
-function handleSubmit () {
184
-
185
-  if (validateForm()) {
186
-    state.isLoading = true
187
-    uni.showLoading({
188
-      title: '认证提交中'
189
-    })
190
-    const certificationRequest: CertificationRequest = {
191
-      user_name: formData.user_name,
192
-      user_card: formData.user_card,
193
-      mobile: userStore.userInfo.phone,
194
-      card_positive: formData.card_positive,
195
-      card_reverse: formData.card_reverse
196
-    }
197
-	console.log("===certificationRequest",certificationRequest);
198
-    submitCertification(certificationRequest).then(res => {
199
-      // state.isLoading = false
200
-      uni.hideLoading()
201
-      // formData = {}
202
-      if (res && res.user_card && res.user_name) {
203
-        formData.user_card = res.user_card
204
-        formData.user_name = res.user_name
2
+	import { CDN_URL } from "~/config/app";
3
+	import { UPLOAD_URL } from "~/utils/http";
4
+	import { getToken } from "~/utils/auth";
5
+	import { uploadImageOne } from "~/utils/upload";
6
+	import { backdropFilterBase } from "unocss-preset-weapp/rules";
7
+	import { getCertificationInfo, submitCertification } from "~/apis/user";
8
+	import AuthenticationSuccess from "~/pages/real-name-authentication/components/authentication-success.vue";
9
+	import type { CertificationRequest } from "~/apis/model/certification.model";
10
+
11
+	const front_220714Image = CDN_URL + '/static/assets/front_220714.png'
12
+	const verso_220714Image = CDN_URL + '/static/assets/verso_220714.png'
13
+
14
+	const userStore = useUserStore()
15
+	const userInfoX =ref({})
16
+
17
+	const formData = reactive({
18
+		user_name: '',
19
+		user_card: '',
20
+		mobile: '',
21
+		card_positive: '',
22
+		card_reverse: '',
23
+	})
24
+
25
+	const state = reactive({
26
+		isLoading: false,
27
+		isFormValidate: false,
28
+		// 审核中
29
+		isReview: false,
30
+		// 已认证
31
+		isCertified: false,
32
+		isNoCertified: true,
33
+		// 审核失败
34
+		isFail: false
35
+
36
+	})
37
+	onLoad(async () => {
38
+		await userStore.getUserInfo()
39
+		console.log(userStore.userInfo)
40
+		console.log(userStore.userInfo.is_ertification)
41
+		if (userStore.userInfo.is_ertification == -1) {
42
+			state.isNoCertified = true
43
+		}
44
+
45
+		getCertificationInfo(1).then(res => {
46
+
47
+			if (res.uid && res.status == '1') {
48
+				state.isCertified = true
49
+				formData.user_card = res.user_card.replace(/^(\d{4})\d+(\d{4})$/, '$1********$2')
50
+				formData.user_name = formatName(res.user_name)
51
+				formData.card_positive = res.card_positive
52
+				formData.card_reverse = res.card_reverse
53
+				userInfoX.value = res
54
+			}
55
+			userInfoX.value = res
56
+		}).catch(error => {
57
+			uni.showToast({
58
+				title: error,
59
+				icon: 'none'
60
+			})
61
+			uni.hideLoading()
62
+
63
+		})
64
+	})
65
+
66
+	const certificationStatus = computed(() => {
67
+		let statusMsg = ''
68
+		switch (userStore.userInfo.is_ertification) {
69
+			case 0: {
70
+				statusMsg = '审核中'
71
+				break;
72
+			}
73
+			case 1: {
74
+				statusMsg = '已认证'
75
+				break;
76
+			}
77
+			case 2: {
78
+				statusMsg = '已拒绝,重新提交'
79
+				break;
80
+			}
81
+			default: {
82
+				statusMsg = '立即认证'
83
+				break;
84
+			}
85
+		}
86
+		return statusMsg
87
+	})
88
+
89
+	const headers = {
90
+		// #ifdef MP
91
+		"Content-Type": "multipart/form-data",
92
+		// #endif
93
+		"X-Token": 'Bearer ' + getToken()
94
+	}
95
+
96
+
97
+	function handleUploadImg(type : 'positive' | 'reverse') {
98
+		if (state.isCertified) {
99
+			return
100
+		}
101
+		uploadImageOne('upload/image', (res) => {
102
+			if (type === 'positive') {
103
+				formData.card_positive = res.data.path
104
+				console.log(formData.card_positive)
105
+			}
106
+			if (type === 'reverse') {
107
+				formData.card_reverse = res.data.path
108
+				console.log(formData.card_reverse)
109
+			}
110
+		})
111
+	}
112
+	function validateForm() {
113
+
114
+		if (formData.user_name === '') {
115
+			uni.showToast({
116
+				title: '请填写姓名',
117
+				icon: 'none'
118
+			})
119
+			// return isValidate
120
+			return state.isFormValidate = false
121
+		}
122
+		if (!(/^[\u4e00-\u9fa5]{2,4}$/.test(formData.user_name))) {
123
+			uni.showToast({
124
+				title: '请正确输入您的姓名',
125
+				icon: 'none'
126
+			})
127
+			return state.isFormValidate = false
128
+		}
129
+
130
+		
131
+
132
+		if (formData.user_card === '') {
133
+			uni.showToast({
134
+				title: '请填写身份证号',
135
+				icon: 'none'
136
+			})
137
+			return state.isFormValidate = false
138
+
139
+		}
140
+
141
+		if (!/^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}([0-9]|X|x)$/.test(formData.user_card)) {
142
+			uni.showToast({
143
+				title: "请填写正确身份证号",
144
+				icon: "none"
145
+			});
146
+			return state.isFormValidate = false
147
+
148
+		}
149
+
150
+		if (formData.card_positive === '') {
151
+			uni.showToast({
152
+				title: '请上传身份证人像面图',
153
+				icon: 'none'
154
+			})
155
+			return state.isFormValidate = false
156
+
157
+		}
158
+		if (formData.card_reverse === '') {
159
+			uni.showToast({
160
+				title: '请上传身份证国徽面图'
161
+			})
162
+			return state.isFormValidate = false
163
+
164
+		}
165
+
166
+		return state.isFormValidate = true
167
+	}
168
+	function handleSubmit() {
169
+
170
+		if (validateForm()) {
171
+			state.isLoading = true
172
+			uni.showLoading({
173
+				title: '认证提交中'
174
+			})
175
+			const certificationRequest : CertificationRequest = {
176
+				user_name: formData.user_name,
177
+				user_card: formData.user_card,
178
+				mobile: userStore.userInfo.phone,
179
+				card_positive: formData.card_positive,
180
+				card_reverse: formData.card_reverse
181
+			}
182
+			console.log("===certificationRequest", certificationRequest);
183
+			submitCertification(certificationRequest).then(res => {
184
+				// state.isLoading = false
185
+				uni.hideLoading()
186
+				// formData = {}
187
+				if (res && res.user_card && res.user_name) {
188
+					formData.user_card = res.user_card
189
+					formData.user_name = res.user_name
190
+					formData.card_positive = formData.card_positive
191
+					formData.card_reverse = formData.card_reverse
192
+				}
193
+				state.isLoading = false
194
+				state.isCertified = true
195
+
196
+				userStore.getUserInfo()
197
+
198
+
199
+			}).catch(error => {
200
+				uni.showToast({
201
+					title: error,
202
+					icon: 'none'
203
+				})
204
+				state.isLoading = false
205
+			})
206
+		} else {
207
+			return false
208
+		}
209
+	}
210
+	function formatName(str) {
211
+		return new Array(str.length).join('*') + str.substr(-1);
212
+
213
+	}
214
+
215
+	function onBackClick() {
216
+		uni.navigateBack()
217
+	}
218
+
219
+	function onReSetClick() {
220
+		state.isCertified = false
221
+		formData.user_card =userInfoX.value.user_card
222
+		formData.user_name = userInfoX.value.user_name
205 223
 		formData.card_positive = formData.card_positive
206 224
 		formData.card_reverse = formData.card_reverse
207
-      }
208
-      state.isLoading = false
209
-	  state.isCertified = true
210
-	  
211
-	  userStore.getUserInfo()
212
-	  
213
-	  
214
-    }).catch(error => {
215
-      uni.showToast({
216
-        title: error,
217
-        icon: 'none'
218
-      })
219
-      state.isLoading = false
220
-    })
221
-  } else {
222
-    return false
223
-  }
224
-}
225
-function formatName (str) {
226
-  return new Array(str.length).join('*') + str.substr(-1);
227
-
228
-}
225
+	}
229 226
 </script>
230 227
 
231 228
 <template>
232
-  <AuthenticationSuccess v-if="state.isCertified"/>
233
-
234
-  <div  v-if="!state.isCertified" class="flex flex-col pt-3 gap-3 pb-safe text-sm">
235
-    <div class="bg-white flex flex-col  px-3">
236
-      <div class="f-hairline-bottom py-3 flex">
237
-        <div>真实姓名:</div>
238
-        <input v-model="formData.user_name"
239
-               :disabled="state.isCertified"
240
-               placeholder="请输入真实姓名"
241
-               class="text-sm"
242
-               :class="state.isCertified && 'text-gray'"
243
-        />
244
-      </div>
245
-
246
-      <div class="f-hairline-bottom py-3 flex">
247
-        <div>证件号码:</div>
248
-        <input v-model="formData.user_card"
249
-               :disabled="state.isCertified"
250
-               placeholder="请输入证件号码" class="text-sm"
251
-               :class="state.isCertified && 'text-gray'"
252
-        />
253
-      </div>
254
-
255
-    </div>
256
-
257
-    <div class="bg-white flex flex-col  p-3 gap-3">
258
-      <div class="flex flex-col gap-3 ">
259
-        <div>身份证人像面图:</div>
260
-        <div class="flex justify-center items-center">
261
-
262
-          <image  v-if="formData.card_positive && !state.isCertified"
263
-                  :src="formData.card_positive"
264
-                  @tap="handleUploadImg('positive')"
265
-                  mode="scaleToFill" class="w-60 h-40"></image>
266
-          <image v-else
267
-                 :src="front_220714Image"
268
-                 @tap="handleUploadImg('positive')"
269
-                 mode="aspectFit" class="w-60 h-40"></image>
270
-        </div>
271
-      </div>
272
-
273
-      <div class="flex flex-col gap-3 ">
274
-        <div>身份证国徽面图:</div>
275
-        <div class="flex justify-center items-center">
276
-<!--          <image :src="verso_220714Image" mode="widthFix" class="w-60"></image>-->
277
-
278
-          <image  v-if="formData.card_reverse && !state.isCertified"
279
-                  :src="formData.card_reverse"
280
-                  @tap="handleUploadImg('reverse')"
281
-                  mode="scaleToFill" class="w-60 h-40 "></image>
282
-          <image v-else
283
-                 :src="verso_220714Image"
284
-                 @tap="handleUploadImg('reverse')"
285
-                 mode="widthFix" class="w-60"></image>
286
-        </div>
287
-      </div>
288
-    </div>
289
-
290
-  </div>
291
-  <div class="fixed bottom-0 p-safe bg-white w-full" v-if="!state.isCertified">
292
-    <div class=" px-3">
293
-      <nut-button
294
-          @tap="handleSubmit"
295
-          :loading="state.isLoading"
296
-          type="primary" block>确认提交</nut-button>
297
-    </div>
298
-  </div>
229
+	
230
+	<view class="user-info-content">
231
+		<AuthenticationSuccess v-if="state.isCertified" :formData='formData' />
232
+		
233
+		<div class="flex flex-col pt-3 gap-3  text-sm">
234
+			<div class="bg-white flex flex-col  px-3">
235
+				<div class="f-hairline-bottom py-3 flex">
236
+					<div>真实姓名:</div>
237
+					<input v-model="formData.user_name" :disabled="state.isCertified" placeholder="请输入真实姓名" class="text-sm"
238
+						:class="state.isCertified && 'text-gray'" />
239
+				</div>
240
+		
241
+				<div class="f-hairline-bottom py-3 flex">
242
+					<div>证件号码:</div>
243
+					<input v-model="formData.user_card" :disabled="state.isCertified" placeholder="请输入证件号码" class="text-sm"
244
+						:class="state.isCertified && 'text-gray'" />
245
+				</div>
246
+		
247
+			</div>
248
+		
249
+			<div class="bg-white flex flex-col  p-3 gap-3" v-if="!state.isCertified">
250
+				<div class="flex flex-col gap-3 ">
251
+					<div>身份证人像面图:</div>
252
+					<div class="flex justify-center items-center">
253
+		
254
+						<image v-if="formData.card_positive" :src="formData.card_positive"
255
+							@tap="handleUploadImg('positive')" mode="scaleToFill" class="w-60 h-40"></image>
256
+						<image v-else :src="front_220714Image" @tap="handleUploadImg('positive')" mode="aspectFit"
257
+							class="w-60 h-40"></image>
258
+					</div>
259
+				</div>
260
+		
261
+				<div class="flex flex-col gap-3 ">
262
+					<div>身份证国徽面图:</div>
263
+					<div class="flex justify-center items-center">
264
+						<image v-if="formData.card_reverse" :src="formData.card_reverse" @tap="handleUploadImg('reverse')"
265
+							mode="scaleToFill" class="w-60 h-40 "></image>
266
+						<image v-else :src="verso_220714Image" @tap="handleUploadImg('reverse')" mode="widthFix"
267
+							class="w-60"></image>
268
+					</div>
269
+				</div>
270
+			</div>
271
+		
272
+		</div>
273
+		<div class="fixed bottom-0 p-safe bg-white w-full" v-if="!state.isCertified">
274
+			<div class=" px-3">
275
+				<nut-button @tap="handleSubmit" :loading="state.isLoading" type="primary" block>确认提交</nut-button>
276
+			</div>
277
+		</div>
278
+		
279
+		<view v-else class="bottom-btn-content ">
280
+			<view class="left-btn" @click="onReSetClick">修改实名信息</view>
281
+			<view class="right-btn" @click="onBackClick">返回</view>
282
+		</view>
283
+	</view>
284
+	
285
+
286
+
299 287
 </template>
300 288
 
301 289
 <style>
302
-page {
303
-  background: #f8f8f8;
304
-  overflow: hidden;
305
-}
306
-
307
-.wx-radio-input {
308
-  height: 16px !important;
309
-  width: 16px !important;
310
-}
290
+	
291
+	.wx-radio-input {
292
+		height: 16px !important;
293
+		width: 16px !important;
294
+	}
311 295
 </style>
296
+
297
+<style scoped lang="scss">
298
+	.user-info-content{
299
+		display: flex;
300
+		background: #f8f8f8;
301
+		min-height: 100vh;
302
+		flex-direction: column;
303
+	}
304
+	.bottom-btn-content {
305
+		display: flex;
306
+		flex-direction: row;
307
+		align-items: center;
308
+		margin-top: 30rpx;
309
+		padding-left: 20rpx;
310
+		padding-right: 20rpx;
311
+
312
+		.left-btn {
313
+			display: flex;
314
+			flex-direction: row;
315
+			justify-content: center;
316
+			align-items: center;
317
+			background-color: #fff;
318
+			flex: 1;
319
+			border: #333 1rpx solid;
320
+			border-radius: 80rpx;
321
+			height: 80rpx;
322
+			font-size: 28rpx;
323
+			margin-left: 20rpx;
324
+			margin-left: 20rpx;
325
+			color: #333;
326
+		}
327
+
328
+		.right-btn {
329
+			margin-left: 20rpx;
330
+			margin-left: 20rpx;
331
+			display: flex;
332
+			justify-content: center;
333
+			flex-direction: row;
334
+			align-items: center;
335
+			flex: 1;
336
+			border-radius: 80rpx;
337
+			height: 80rpx;
338
+			background-color: #ff0000;
339
+			color: #fff;
340
+			font-size: 28rpx;
341
+
342
+		}
343
+	}
344
+</style>
345
+
312 346
 <route lang="yaml">
313 347
 style:
314 348
   navigationBarTitleText: 实名认证

+ 215 - 45
src/pages/third_party_binding/index.vue

@@ -3,6 +3,9 @@ import {CDN_URL} from "~/config/app";
3 3
 import {getBindingState, getUserUnionId, wechatCheck,apiUnbindAccount} from "~/apis/user";
4 4
 import {findLast, union} from "lodash-es";
5 5
 import {getUpdateAccount} from "~/apis/auth.api";
6
+import {UPLOAD_URL} from "~/utils/http";
7
+import {getToken} from "~/utils/auth";
8
+import { uploadImageOne } from "~/utils/upload";
6 9
 
7 10
 const zfbImage = CDN_URL + '/static/assets/zfb_sf_220908.png'
8 11
 const wxImage = CDN_URL + '/static/assets/wx_sf_220908.png'
@@ -11,6 +14,9 @@ const bindState = ref([])
11 14
 import {useUserStore} from "~/stores/userStore";
12 15
 const userList=ref([])
13 16
 const userStore = useUserStore()
17
+const userNick=ref('点击获取微信昵称')
18
+const userHead=ref('')
19
+const ylj_fh_220914Image = `${CDN_URL}/static/assets/ylj_fh_220914.png`
14 20
 
15 21
 
16 22
 onLoad(() => {
@@ -46,6 +52,7 @@ function updateAccount(type, info: {unionId: string, nickName: string, avatarUrl
46 52
     title: '授权中',
47 53
     icon: 'none'
48 54
   })
55
+  
49 56
   getUpdateAccount({
50 57
     type,
51 58
     openid: info.unionId,
@@ -89,32 +96,129 @@ function unbindAccount(){
89 96
 
90 97
 function getUserInfo() {
91 98
   if (!getBindState('1')) {
92
-    uni.login({
93
-      provider: 'weixin',
94
-      univerifyStyle: {
95
-        fullScreen: true
96
-      },
97
-      success: (result) => {
98
-        getUserUnionId({
99
-          code: result.code,
100
-          source: 'cxb'
101
-        }).then(unionRes => {
102
-          updateAccount(1, {
103
-            unionId: unionRes.unionid,
104
-            nickName: userStore.userInfo.nickname,
105
-            avatarUrl: userStore.userInfo.avatar
106
-          })
107
-        })
108
-      },
109
-      fail: (error) => {
110
-        console.log(error)
111
-      }
112
-    });
99
+	
100
+	  uni.getUserProfile({
101
+	  	desc:'用于完善个人资料',
102
+	  		success: (res) => {
103
+	  		    const { avatarUrl, nickName } = res.userInfo;
104
+	  		    console.log("===avatarUrl",avatarUrl);
105
+	  			console.log("===avatarUrl",nickName);
106
+				
107
+				uni.login({
108
+				  provider: 'weixin',
109
+				  univerifyStyle: {
110
+				    fullScreen: true
111
+				  },
112
+				  success: (result) => {
113
+				    getUserUnionId({
114
+				      code: result.code,
115
+				      source: 'cxb'
116
+				    }).then(unionRes => {
117
+				      updateAccount(1, {
118
+				        unionId: unionRes.unionid,
119
+				        nickName: nickName,
120
+				        avatarUrl: avatarUrl
121
+				      })
122
+				    })
123
+				  },
124
+				  fail: (error) => {
125
+				    console.log(error)
126
+				  }
127
+				});
128
+	  		  }
129
+	  })
130
+	  
113 131
   }else{
114
-	  unbindAccount()
132
+	  uni.showModal({
133
+	  	title:'温馨提示',
134
+		content:'请您确认是否解除授权!',
135
+		complete: (res) => {
136
+			if(res.confirm){
137
+				 unbindAccount()
138
+			}
139
+		}
140
+	  })
141
+	 
115 142
   }
116 143
 }
144
+function getUserProfile({detail}){
145
+  
146
+  const inputName = 'field';
117 147
 
148
+  uni.uploadFile({
149
+    url: UPLOAD_URL,
150
+    name: 'field',
151
+    formData: {
152
+      'filename': inputName
153
+    },
154
+    header: {
155
+      // #ifdef MP
156
+      "Content-Type": "multipart/form-data",
157
+      // #endif
158
+      'X-Token':'Bearer ' + getToken()
159
+      // [TOKENNAME]: 'Bearer ' + store.state.app.token
160
+    },
161
+    filePath: detail.avatarUrl ,
162
+    success: res => {
163
+		
164
+		console.log("===res");
165
+      uni.hideLoading()
166
+      const { data } = res
167
+      const assetData = JSON.parse(data)
168
+      if (assetData && assetData.data) {
169
+        userHead.value = assetData.data.path
170
+      }
171
+    },
172
+	fail: (res) => {
173
+		console.log("---res",res);
174
+	}
175
+  })
176
+}
177
+
178
+function onBindClick(){
179
+	
180
+	if(getBindState('1')){
181
+		unbindAccount()
182
+		return
183
+	}
184
+	if(!userHead.value){
185
+		uni.showToast({
186
+			title:'请点击获取微信头像',
187
+			icon:'none'
188
+		})
189
+		return
190
+	}
191
+	
192
+	if(!userNick.value){
193
+		uni.showToast({
194
+			title:'请点击获取微信昵称',
195
+			icon:'none'
196
+		})
197
+		return
198
+	}
199
+	
200
+	uni.login({
201
+	  provider: 'weixin',
202
+	  univerifyStyle: {
203
+	    fullScreen: true
204
+	  },
205
+	  success: (result) => {
206
+	    getUserUnionId({
207
+	      code: result.code,
208
+	      source: 'cxb'
209
+	    }).then(unionRes => {
210
+	      updateAccount(1, {
211
+	        unionId: unionRes.unionid,
212
+	        nickName: userNick.value,
213
+	        avatarUrl: userHead.value
214
+	      })
215
+	    })
216
+	  },
217
+	  fail: (error) => {
218
+	    console.log(error)
219
+	  }
220
+	});
221
+}
118 222
 
119 223
 </script>
120 224
 <template>
@@ -128,57 +232,123 @@ function getUserInfo() {
128 232
           微信授权
129 233
         </div>
130 234
       </div>
131
-      <div class="border border-solid rounded-full  text-xs px-2 h-4"
132
-           @tap="getUserInfo"
235
+      <button class="border border-solid rounded-full  text-xs px-2 h-6"
133 236
            :class="getBindState('1') ? 'text-red' : 'text-gray border-gray'"
134 237
       >
135
-        {{ getBindState('1') ? '解除授权' : '去授权' }}
136
-      </div>
238
+        {{ getBindState('1') ? '已授权' : '未授权' }}
239
+      </button>
137 240
 	
138 241
     </div>
139 242
 	<view class="item-line"></view>
140 243
 	
141
-	<view class="flex flex-col" v-for="(item,index) in bindState">
142
-		<view class="user-info-content">
244
+	
245
+	<view class="add-item" v-if=" !getBindState('1')">
246
+		 <button class="add-button-item" open-type="chooseAvatar" @chooseavatar="getUserProfile" >点击获取微信头像</button>
247
+		 <image class="user-head" :src="userHead" mode="widthFix"></image>
248
+		  <image class="user-arrow" :src="ylj_fh_220914Image" mode="widthFix"></image>
249
+	</view>
250
+	<view class="item-line" v-if=" !getBindState('1')"></view>
251
+	<view class="add-item" v-if=" !getBindState('1')">
252
+		<input placeholder-class="add-button-item"  class="add-button-item" type="nickname"   v-model="userNick"  placeholder="获取微信昵称" />
253
+		 <image class="user-arrow" :src="ylj_fh_220914Image" mode="widthFix"></image>
254
+	</view>
255
+	
256
+	<view :key="'bind-user-item-'+index" class="flex flex-col " v-for="(item,index) in bindState">
257
+		<view class="user-info-content" v-if="item.type==1">
143 258
 				  <image class="user-icon" :src="item.avater?item.avater:defaultHeadImg" mode="aspectFill"></image>
144 259
 				  <text class="user-nick-name">{{item.nickname}}</text>
145
-				  <!-- <view class="un-bind-btn" @click="unbindAccount">解除绑定</view> -->
146 260
 		</view>
147 261
 		<view v-if="index !=userList.length-1" class="item-line"></view>
148 262
 	</view>
149 263
 	</view>
264
+	<view class="bottom-btn" @click="onBindClick">  {{ getBindState('1') ? '解除绑定' : '授权绑定' }}</view>
150 265
   </div>
151
-  <!--
152
-  <div class="flex flex-row  justify-between bg-white p-4">
153
-    <div class="flex-1 flex text-sm items-center gap-2">
154
-      <image :src="zfbImage" mode="widthFix" class="w-4 h-4"></image>
155
-      <div>
156
-        支付宝授权
157
-      </div>
158
-    </div>
159
-    <div class="border border-solid rounded-full  text-xs px-2 h-4"
160
-         :class="getBindState('2') ? 'text-red' : 'text-gray border-gray'"
161
-    >
162
-      {{ getBindState('2') ? '已授权' : '未授权' }}
163
-
164
-    </div>
165
-  </div>
166
-  -->
266
+ 
167 267
 </template>
168 268
 
169 269
 <style>
170 270
 page {
171 271
   background: #f8f8f8;
172 272
 }
273
+button{
274
+		margin: 0;
275
+		padding: 0;
276
+		outline: none;
277
+		border-radius: 0;
278
+		background-color: transparent;
279
+		line-height: inherit;
280
+	}
281
+	button::after{
282
+		border: none;
283
+	}
284
+
173 285
 </style>
174 286
 
175 287
 
176 288
 <style scoped lang="scss">
177 289
 	
290
+	.bottom-btn{
291
+		display: flex;
292
+		flex-direction: row;
293
+		align-items: center;
294
+		height: 80rpx;
295
+		align-items: center;
296
+		color: #fff;
297
+		font-size: 28rpx;
298
+		justify-content: center;
299
+		background-color: #ff0000;
300
+		margin-top: 30rpx;
301
+		margin-left: 40rpx;
302
+		margin-right: 40rpx;
303
+		border-radius: 80rpx;
304
+	}
305
+	
306
+	
178 307
 	.user-info-out-content{
179 308
 		display: flex;
180 309
 		flex-direction: column;
181 310
 		background-color: #fff;
311
+		box-sizing: border-box;
312
+		
313
+		
314
+		.add-item{
315
+			border-radius: 20rpx;
316
+			height: 80rpx;
317
+			margin-bottom: 20rpx;
318
+			margin-top: 20rpx;
319
+			margin-left: 40rpx;
320
+			display: flex;
321
+			flex-direction: row;
322
+			align-items: center;
323
+			margin-right: 40rpx;
324
+			font-size: 28rpx;
325
+			color: #333;
326
+		}
327
+		
328
+		
329
+		.add-button-item{
330
+			height: 80rpx;
331
+			display: flex;
332
+			border:none;
333
+			flex-direction: row;
334
+			flex: 1;
335
+			align-items: center;
336
+			font-size: 28rpx;
337
+			color: #333;
338
+			background-color: #fff;
339
+		}
340
+		.user-head{
341
+			width: 70rpx;
342
+			border-radius: 50%;
343
+			height: 70rpx;
344
+			background-color: #eeeeee;
345
+		}
346
+		
347
+		.user-arrow{
348
+			width: 20rpx;
349
+			margin-left: 10rpx;
350
+			height: 30rpx;
351
+		}
182 352
 		
183 353
 		.item-line{
184 354
 			margin-left: 40rpx;

+ 4 - 3
src/pages/user/index.vue

@@ -548,16 +548,17 @@
548 548
 						<view class=" sign-content">
549 549
 
550 550
 							<!-- 用户 -->
551
+							<image v-if="userInfo?.originator_id_old" mode="widthFix" lazy-load class="sign-icon" src="/static/icon/user_xx_icon.png" />
551 552
 							<image v-if="userType" mode="widthFix" lazy-load class="sign-icon" :src="userType" />
552 553
 
553 554
 							<!-- 市区县代理 -->
554 555
 							<!-- <view v-if="areaType" class="flex rounded-full  text-[12px] text-white w-12 h-5  w-fit "
555 556
 							@click="openPopup">
556 557
 							<image mode="heightFix" lazy-load class="sign-icon" :src="areaType" />
557
-						</view>
558
-						 -->
558
+						</view> -->
559
+						
559 560
 							<!-- 股东 -->
560
-							<!-- 	<view v-if="AlholderType"
561
+								<!-- <view v-if="AlholderType"
561 562
 							class="flex rounded-full  text-[12px] text-white w-12 h-5   w-fit">
562 563
 							<image mode="heightFix" lazy-load class="sign-icon" :src="AlholderType" />
563 564
 						</view> -->

+ 1 - 1
src/pages/user/login/index.vue

@@ -73,7 +73,7 @@ async function handleWexinLogin() {
73 73
         let redirectPageObj: { page: string; type: 'page' | 'tab' }
74 74
         if (Cache.get('SHARE_REDIRECT_PAGE'))
75 75
           redirectPageObj = JSON.parse(Cache.get('SHARE_REDIRECT_PAGE'))
76
-        wechatCheck(unionRes.openid).then((checkRes) => {
76
+        wechatCheck(unionRes.unionid).then((checkRes) => {
77 77
           userStore.login(checkRes.token, checkRes.exp)
78 78
           userStore.setUID(checkRes.user.uid)
79 79
           userStore.setUserInfo(checkRes.user)

BIN
src/static/icon/user_xx_icon.png


+ 13 - 13
src/subPages/pages/bankDetail/index.vue

@@ -34,8 +34,8 @@
34 34
 
35 35
 <script setup>
36 36
 	import {
37
-		apiGetTrVrInfo,
38
-		apiBankCreate
37
+		apiBankCreate,
38
+		getCertificationInfo
39 39
 	} from '~/apis/user'
40 40
 	import {formatDate} from '~/utils/util'
41 41
 	
@@ -53,11 +53,20 @@
53 53
 	})
54 54
 	onLoad((option) => {
55 55
 		if(option.item!= 'null'){
56
-			console.log("===option.item",option.item);
57 56
 			cardInfo.value =JSON.parse(option.item)
57
+			getCertificationInfoX()
58
+		}else {
59
+			getCertificationInfoX()
58 60
 		}
59 61
 	})
60 62
 	
63
+	function getCertificationInfoX(){
64
+		getCertificationInfo(1).then(res=>{
65
+			cardInfo.value.user_name =res.user_name
66
+			cardInfo.value.user_card =res.user_card
67
+		})
68
+	}
69
+	
61 70
 	function onSubmitClick(){
62 71
 		if(!cardInfo.value.user_name){
63 72
 			uni.showToast({
@@ -113,16 +122,7 @@
113 122
 	}
114 123
 	
115 124
 
116
-	function getList(){
117
-		uni.showLoading({
118
-			title:'加载中...'
119
-		})
120
-	    apiGetTrVrInfo({page:state.page}).then(res => {
121
-			count.value = res.count
122
-	    	dataList.value= res.list
123
-			uni.hideLoading()
124
-	    })
125
-	}
125
+	
126 126
 	
127 127
 </script>
128 128
 <route lang="yaml">

+ 14 - 5
src/subPages/pages/immediate-withdrawal/index.vue

@@ -42,6 +42,7 @@ const bankIndex=ref(0)
42 42
 const showPhonePop=ref(false)
43 43
 const userHBInfo=ref({})
44 44
 const bankList=ref([])
45
+const initType =ref(0)
45 46
 
46 47
 const userQbPrice=ref(0)
47 48
 // userSpreadInfo.value.brokerage_price
@@ -54,6 +55,7 @@ onLoad((options) => {
54 55
     } else if (options.type == 3) {
55 56
       isshow.value = 3
56 57
     }
58
+	
57 59
 	console.log("===options.type",options.type);
58 60
   }
59 61
 })
@@ -204,6 +206,8 @@ function handleImmediateWithdrawal() {
204 206
   if (isDisabled.value) {
205 207
     return
206 208
   }
209
+  
210
+
207 211
   if(bankList.value && bankList.value.length==0){
208 212
 	  uni.showToast({
209 213
 	    title: '请绑定提现银行卡',
@@ -313,6 +317,7 @@ function handleImmediateredWithdrawal() {
313 317
   if (isDisabled.value) {
314 318
     return
315 319
   }
320
+
316 321
   if (widthdrawalConfig.value.withdrawal_status == '0') {
317 322
     isDisabled.value = true
318 323
     return uni.showToast({
@@ -372,7 +377,7 @@ function handleImmediateredWithdrawal() {
372 377
 
373 378
 function handleWithdrawalRecord() {
374 379
   uni.navigateTo({
375
-    url: '/subPages/pages/withdrawal-record/index'
380
+    url: `/subPages/pages/withdrawal-record/index?type=${isshow.value}`
376 381
   })
377 382
 }
378 383
 
@@ -391,7 +396,7 @@ function onBankItemClick(item:any){
391 396
 		url:`/subPages/pages/bankDetail/index?item=${JSON.stringify(item)}`
392 397
 	})
393 398
 }
394
-const userCode =ref()
399
+const userCode =ref('')
395 400
 const btnName=ref('重新获取')
396 401
 
397 402
 function onBtnClick(){
@@ -425,11 +430,14 @@ function sendCode(){
425 430
 function onCancelClick(){
426 431
 	clearInterval(time.value)
427 432
 	showPhonePop.value=false
433
+	userCode.value=''
428 434
 }
429 435
 
436
+
437
+
430 438
 function onSubmitClick(){
431 439
 	clearInterval(time.value)
432
-	onCancelClick()
440
+	showPhonePop.value=false
433 441
 	uni.showLoading({
434 442
 		title:'请求中'
435 443
 	})
@@ -437,12 +445,13 @@ function onSubmitClick(){
437 445
 		sms_code:userCode.value.replace(/\s/g, ""),
438 446
 		extract_price:cashWithdrawalAmount.value,
439 447
 		bank_id:bankList.value[bankIndex.value].id,
440
-		extract_type:3
448
+		extract_type:3,
449
+		type: isshow.value
441 450
 	}
442 451
 	apiExtractCreate(params).then(res=>{
443 452
 		uni.hideLoading()
444 453
 		uni.navigateTo({
445
-		   url: '/subPages/pages/withdrawal-record/index'
454
+		   url:`/subPages/pages/withdrawal-record/index?type=${isshow.value}`
446 455
 		})
447 456
 	})
448 457
 }

+ 5 - 3
src/subPages/pages/mine-top/brokerage.vue

@@ -137,9 +137,11 @@
137 137
 			return
138 138
 		}
139 139
 		apiTransitionVr(num).then(res=>{
140
-			if(res==200){
141
-				getInfo()
142
-			}
140
+			uni.showToast({
141
+				title:'转VR成功',
142
+				icon:'none'
143
+			})
144
+			getInfo()
143 145
 		}).catch(res=>{
144 146
 			uni.showToast({
145 147
 				title:res,

+ 1 - 1
src/subPages/pages/mine-top/contribute.vue

@@ -43,7 +43,7 @@
43 43
 						<text class="top-title">{{item.mark}}</text>
44 44
 						<text class="top-right">{{item.number}}</text>
45 45
 					</view>
46
-					<text class="date">{{formatDate(item.addtime,8,'-')}}</text>
46
+					<text class="date">{{formatDate(item.addtime,4,'-')}}</text>
47 47
 				</view>
48 48
 			</view>
49 49
 		</view>

+ 1 - 1
src/subPages/pages/mine-top/jifen.vue

@@ -32,7 +32,7 @@
32 32
 						<text
33 33
 							class="top-right">{{item.reward_socre}}</text>
34 34
 					</view>
35
-					<text class="date">{{formatDate(item.addtime,8,'-')}}</text>
35
+					<text class="date">{{formatDate(item.addtime,4,'-')}}</text>
36 36
 				</view>
37 37
 			</view>
38 38
 		</view>

+ 1 - 1
src/subPages/pages/mine-top/jingdou.vue

@@ -30,7 +30,7 @@
30 30
 						<text class="top-title">{{item.mark}}</text>
31 31
 						<text class="top-right">{{item.number}}</text>
32 32
 					</view>
33
-					<text class="date">{{formatDate(item.addtime,8,'-')}}</text>
33
+					<text class="date">{{formatDate(item.addtime,4,'-')}}</text>
34 34
 				</view>
35 35
 			</view>
36 36
 		</view>

+ 21 - 25
src/subPages/pages/mine-top/qianbao.vue

@@ -30,7 +30,7 @@
30 30
 						<text class="top-title">{{item.mark}}</text>
31 31
 						<text class="top-right">{{item.number}}</text>
32 32
 					</view>
33
-					<text class="date">{{formatDate(item.addtime,8,'-')}}</text>
33
+					<text class="date">{{formatDate(item.addtime,4,'-')}}</text>
34 34
 				</view>
35 35
 			</view>
36 36
 		</view>
@@ -66,6 +66,8 @@
66 66
 		name: '入账红包'
67 67
 	}, {
68 68
 		name: '出账红包'
69
+	}, {
70
+		name: '未生效红包'
69 71
 	}])
70 72
 	const userStore = useUserStore()
71 73
 	const dataInfo = ref({})
@@ -86,6 +88,12 @@
86 88
 		getInfo()
87 89
 		getList()
88 90
 	})
91
+	
92
+	onShow(()=>{
93
+		state.page = 1
94
+		getInfo()
95
+		getList()
96
+	})
89 97
 
90 98
 	function onItemClick(index) {
91 99
 		if (index == 0) {
@@ -93,8 +101,8 @@
93 101
 		} else if (index == 1) {
94 102
 			uni.showModal({
95 103
 				editable: true,
96
-				title: '请输入佣金转VR数量',
97
-				placeholderText: '请输入佣金转VR数量',
104
+				title: '请输入红包转VR数量',
105
+				placeholderText: '请输入红包转VR数量',
98 106
 				complete: (e) => {
99 107
 					if (e.confirm) { //去转换
100 108
 						transitionVr(e.content)
@@ -112,10 +120,14 @@
112 120
 			})
113 121
 			return
114 122
 		}
115
-		apiTransitionVr(num).then(res => {
116
-			if (res == 200) {
117
-				getInfo()
118
-			}
123
+		apiTransitionVr(num,'hongbao').then(res => {
124
+			uni.showToast({
125
+				title:"转VR成功",
126
+				icon:'none'
127
+			})
128
+			getInfo()
129
+			state.page = 1
130
+			getList()
119 131
 		}).catch(res => {
120 132
 			uni.showToast({
121 133
 				title: res,
@@ -180,23 +192,7 @@
180 192
 		})
181 193
 	}
182 194
 
183
-	// onShareAppMessage(() => {
184
-	// 	const shareId = Cache.get('SHARE_ID')
185
-	// 	return {
186
-	// 		title: SHARE_TITLE,
187
-	// 		path: `/pages/vip/index?shareId=${shareId}`,
188
-	// 		imageUrl: SHARE_BANNER
189
-	// 	}
190
-	// })
191
-
192
-	// onShareTimeline(() => {
193
-	// 	const shareId = Cache.get('SHARE_ID')
194
-	// 	return {
195
-	// 		title: SHARE_TITLE,
196
-	// 		query: `from=share&shareId=${shareId}`,
197
-	// 		imageUrl: SHARE_ICON
198
-	// 	}
199
-	// })
195
+
200 196
 
201 197
 	onReachBottom(() => {
202 198
 		console.log('到底了。。。')
@@ -206,8 +202,8 @@
206 202
 
207 203
 	onPullDownRefresh(() => {
208 204
 		state.page = 1
209
-		getList()
210 205
 		uni.stopPullDownRefresh()
206
+		getList()
211 207
 	})
212 208
 
213 209
 	function onTabClick(position, id) {

+ 1 - 1
src/subPages/pages/mine-top/repurchase.vue

@@ -29,7 +29,7 @@
29 29
 						<text class="top-title">{{item.mark}}</text>
30 30
 						<text class="top-right">{{item.number}}</text>
31 31
 					</view>
32
-					<text class="date">{{formatDate(item.addtime,8,'-')}}</text>
32
+					<text class="date">{{formatDate(item.addtime,4,'-')}}</text>
33 33
 				</view>
34 34
 			</view>
35 35
 		</view>

+ 8 - 21
src/subPages/pages/mine-top/vr.vue

@@ -28,7 +28,7 @@
28 28
 						<text class="top-title">{{item.mark}}</text>
29 29
 						<text class="top-right">{{item.number}}</text>
30 30
 					</view>
31
-					<text class="date">{{formatDate(item.addtime,8,'-')}}</text>
31
+					<text class="date">{{formatDate(item.addtime,4,'-')}}</text>
32 32
 				</view>
33 33
 			</view>
34 34
 		</view>
@@ -74,14 +74,17 @@
74 74
 		getProductShare().then(res => {
75 75
 		  if (res) userStore.setShareId(res.share_id)
76 76
 		})
77
+	})
78
+	
79
+	
80
+	onShow(()=>{
81
+		state.page = 1
77 82
 		getInfo()
78 83
 		getList()
79 84
 		getInfoName()
80 85
 	})
81 86
 	
82
-	
83 87
 	function onItemClick(){
84
-		console.log("===dataNameInfo",dataNameInfo.value);
85 88
 		let info ={
86 89
 			url:dataNameInfo.value.url,
87 90
 			name:dataNameInfo.value.name
@@ -108,7 +111,7 @@
108 111
 			title: '加载中...',
109 112
 			mask: true
110 113
 		})
111
-			apiGetVRList({page:state.page,pm:state.pm}).then(res => {
114
+			apiGetVRList({page:state.page,pm:state.pm==1?2:0}).then(res => {
112 115
 				if (state.page === 1) {
113 116
 					listInfo.value = res
114 117
 				} else {
@@ -119,23 +122,7 @@
119 122
 		})
120 123
 	}
121 124
 
122
-	// onShareAppMessage(() => {
123
-	// 	const shareId = Cache.get('SHARE_ID')
124
-	// 	return {
125
-	// 		title: SHARE_TITLE,
126
-	// 		path: `/pages/vip/index?shareId=${shareId}`,
127
-	// 		imageUrl: SHARE_BANNER
128
-	// 	}
129
-	// })
130
-
131
-	// onShareTimeline(() => {
132
-	// 	const shareId = Cache.get('SHARE_ID')
133
-	// 	return {
134
-	// 		title: SHARE_TITLE,
135
-	// 		query: `from=share&shareId=${shareId}`,
136
-	// 		imageUrl: SHARE_ICON
137
-	// 	}
138
-	// })
125
+	
139 126
 
140 127
 	onReachBottom(() => {
141 128
 		console.log('到底了。。。')

+ 2 - 2
src/subPages/pages/order/logistics.vue

@@ -234,7 +234,7 @@ function transformStatus() {
234 234
       </div>
235 235
     </div>
236 236
     <!-- 商品推荐 -->
237
-    <div>
237
+   <!-- <div>
238 238
       <div class="flex flex-row justify-center items-center gap-3 font-bold text-sm p-3">
239 239
         <image :src="like_adorn_220628Image" mode="widthFix" class="w-6 h-6"></image>
240 240
         <div>
@@ -260,7 +260,7 @@ function transformStatus() {
260 260
         </div>
261 261
       </div>
262 262
 
263
-    </div>
263
+    </div> -->
264 264
 
265 265
   </div>
266 266
 </template>

+ 35 - 22
src/subPages/pages/quick-fuc/business.vue

@@ -149,10 +149,10 @@
149 149
 	
150 150
 
151 151
 	function onFucClick(position) {
152
-
153
-		if (position == 0 || position == 3) {
154
-
155
-			if (uni.getStorageSync('UID')) {
152
+		
153
+		if (uni.getStorageSync('UID')) {
154
+			
155
+			if(position == 0 || position == 3){
156 156
 				let _token = userTokenInfo.value
157 157
 				let params = {
158 158
 					x_token: _token.mweb_info.x_token,
@@ -167,7 +167,7 @@
167 167
 						mer_id: _token.mweb_info.user.mer_id,
168 168
 					}
169 169
 				}
170
-
170
+				
171 171
 				let url = `${BASE_URL}/mweb/#/?data=${encodeURIComponent(JSON.stringify(params))}`
172 172
 				let info = {
173 173
 					url: url,
@@ -176,29 +176,42 @@
176 176
 				uni.navigateTo({
177 177
 					url: `/subPages/pages/mine-top/common-webView?info=${encodeURIComponent(JSON.stringify(info))}`
178 178
 				})
179
+			}else if(position == 2){
180
+				uni.openCustomerServiceChat({
181
+					extInfo: {
182
+						url: 'https://work.weixin.qq.com/kfid/kfcb5641d3744471601',
183
+					},
184
+					corpId: 'wwaeb55681929a37ae',
185
+					success: (res) => {
186
+						console.log(res)
187
+					},
188
+					fail: (res) => {
189
+						console.log(res)
190
+					},
191
+				})
179 192
 			}else {
180 193
 				uni.showToast({
181
-					title:'请登录!',
182
-					icon:'none'
194
+					title: '升级中',
195
+					icon: 'none'
183 196
 				})
184
-				setTimeout(()=>{
185
-					pageStore.setPageConfig({
186
-						currentPage: {
187
-							type: 'tab',
188
-							url: '/pages/home/index'
189
-						}
190
-					})
191
-					return uni.redirectTo({
192
-						url: '/pages/user/login/index'
193
-					})
194
-				},300)
195
-			
196 197
 			}
197
-		} else {
198
+			
199
+		}else {
198 200
 			uni.showToast({
199
-				title: '升级中',
200
-				icon: 'none'
201
+				title:'请登录!',
202
+				icon:'none'
201 203
 			})
204
+			setTimeout(()=>{
205
+				pageStore.setPageConfig({
206
+					currentPage: {
207
+						type: 'tab',
208
+						url: '/pages/home/index'
209
+					}
210
+				})
211
+				return uni.redirectTo({
212
+					url: '/pages/user/login/index'
213
+				})
214
+			},300)
202 215
 		}
203 216
 
204 217
 	}

+ 2 - 2
src/subPages/pages/store/product/detail.vue

@@ -982,7 +982,7 @@
982 982
 			</div>
983 983
 
984 984
 		</div>
985
-
985
+<!-- 
986 986
 		<div class="flex flex-col pb-safe gap-3">
987 987
 			<div class="p-3 bg-white">
988 988
 				<div class="flex flex-1 justify-start items-center ">
@@ -1011,7 +1011,7 @@
1011 1011
 				</div>
1012 1012
 			</div>
1013 1013
 
1014
-		</div>
1014
+		</div> -->
1015 1015
 
1016 1016
 	</div>
1017 1017
 	<!-- 商品下架 -->

+ 2 - 2
src/subPages/pages/store/product/other.vue

@@ -747,7 +747,7 @@ onReachBottom(() => {
747 747
           </div>
748 748
         </div>
749 749
       </div>
750
-      <div class="flex flex-col pb-safe gap-3">
750
+     <!-- <div class="flex flex-col pb-safe gap-3">
751 751
         <div class="p-3 bg-white">
752 752
           <div
753 753
             class="before:content-[''] before:block before:absolute before:w-1 before:h-full before:bg-gradient-to-b from-red-500 to-red-600 before:rounded relative inline-block"
@@ -772,7 +772,7 @@ onReachBottom(() => {
772 772
             </div>
773 773
           </div>
774 774
         </div>
775
-      </div>
775
+      </div> -->
776 776
     </div>
777 777
   </CXBBasePage>
778 778
 </template>

+ 4 - 1
src/subPages/pages/withdrawal-record/index.vue

@@ -6,8 +6,11 @@ import CXBBasePage from "~/components/CXBBasePage/CXBBasePage.vue";
6 6
 import { IMG_CDN_NEW_URL } from "~/config/app";
7 7
 const list = ref([])
8 8
 onLoad((option) => {
9
+	
10
+	let type =option.type
11
+	
9 12
   getWithdrawal({
10
-    type: 1
13
+    type: type
11 14
   }).then(res => {
12 15
     console.log('提现记录')
13 16
     console.log(res)