gjy 2 anni fa
parent
commit
052ccb25a4
4 ha cambiato i file con 56 aggiunte e 11 eliminazioni
  1. 3 1
      main.js
  2. 19 9
      pageD/identity/companyIdentityThree.vue
  3. 34 0
      pages/user/user.vue
  4. 0 1
      util/util.js

+ 3 - 1
main.js

@@ -224,9 +224,11 @@ const doRequest = (method, url, data, header) => {
 				'content-type': contentheader //'application/x-www-form-urlencoded; charset=UTF-8',
 			},
 			success: function(result) {
+				// console.log(result,111111111111)
 				uni.hideLoading()
+					resolve(result)
 				// resolve调用后,即可传递到调用方使用then或者async+await同步方式进行处理逻辑
-				resolve(result)
+				
 			},
 			fail: function(e) {
 				uni.hideLoading()

+ 19 - 9
pageD/identity/companyIdentityThree.vue

@@ -394,6 +394,10 @@
 														content: '该手机号已认证过个人粮商,再次认证将覆盖之前的认证信息,是否确定认证?',
 														success: function(res) {
 															if (res.confirm) {
+																console.log(that
+																	.identityAuthenticationInfo,that
+																	.identityAuthenticationInfo
+																	.id)
 																if (that
 																	.identityAuthenticationInfo
 																	.id) {
@@ -404,18 +408,17 @@
 																			.identityAuthenticationInfo,
 																			'application/json;charset=UTF-8'
 																		).then(res => {
-																			console
-																				.log(
-																					"成功连接"
-																				)
+																			
+																			if(res.data.code=='22004'){
+																				that.$api.msg(res1.message)
+																				return
+																			}
+																			console.log("成功连接")
 																			if (!that
 																				.identityAuthenticationInfo
 																				.goodsName
 																			) {
-																				that.$api
-																					.msg(
-																						'修改成功!'
-																					)
+																				that.$api.msg('修改成功!')
 																				uni.navigateTo({
 																					url: `/pages/attestation/index`
 																				})
@@ -425,6 +428,7 @@
 
 																		})
 																		.catch(res => {
+																			console.log(res)
 																			if (res
 																				.errmsg
 																			) {
@@ -492,9 +496,15 @@
 																						2000
 																					);
 																				
+																			}else if (res.data&&res.data.message!=''){
+																				uni.showToast({
+																					title: res.data.message,
+																					icon: 'none',
+																					duration: 2000
+																				})
 																			}
 																		})
-																}
+																	}
 															}
 														}
 													});

+ 34 - 0
pages/user/user.vue

@@ -396,6 +396,40 @@
 			this.scrollTop = e.scrollTop;
 		},
 		onShow() {
+			this.$api.doRequest(
+					'post',
+					'/identityAuthenticationInfo/api/editIdentityAuthenticationInfo',
+					{
+									"customerName": "张鞍伟",
+									"customerNumberCard": "232325197404063236",
+									"compAddress": "黑龙江省肇东市民益路8号锦秀江南小区12号楼4单元402室",
+									"cardAddressUrl": "https://taohaoliang.oss-cn-beijing.aliyuncs.com/appData/167030514127919.png,https://taohaoliang.oss-cn-beijing.aliyuncs.com/appData/1670305148665112.png",
+									"customerTypeFlag": "1",
+									"customerType": "个人",
+									"invitation": "黑龙江中天昊元贸易有限公司",
+									"inviteCompany": "2710b21efc1e4393930c5dc800010dc4",
+									"payeeName": "张鞍伟",
+									"payeeNumberCard": "232325197404063236",
+									"bankCard": "6222030709001990104",
+									"bankDeposit": "工商银行",
+									"bankDepositBranch": "中国工商银行股份有限公司大石桥支行",
+									"customerPhone": "18641734419",
+									"supplier": "高敬炎",
+									"supplierPhone": "18513069273",
+									"commonId": "0897dca698674abb95a4376c1439c22a",
+									"payeeAddressUrl": "https://taohaoliang.oss-cn-beijing.aliyuncs.com/appData/167030515522011.png,https://taohaoliang.oss-cn-beijing.aliyuncs.com/appData/1670305162119141.png"
+								},
+					'application/json;charset=UTF-8'
+				).then(res1 => {
+					console.log(res1)
+					
+			
+				})
+				.catch(res => {
+					console.log(res)
+					
+				});
+			
 			// uni.showLoading({
 			// 	title: '加载中',
 			// 	mask: true

+ 0 - 1
util/util.js

@@ -108,7 +108,6 @@ const utils = {
 				method: method, //'GET','POST'
 				dataType: 'json',
 				success: (res) => {
-					uni.hideLoading()
 					if (loadding && !hideLoading) {
 						uni.hideLoading()
 					}