测试问题修改
This commit is contained in:
		
							parent
							
								
									d9b828c3a8
								
							
						
					
					
						commit
						b83d72d3cf
					
				| 
						 | 
					@ -111,7 +111,7 @@
 | 
				
			||||||
		data() {
 | 
							data() {
 | 
				
			||||||
			return { 
 | 
								return { 
 | 
				
			||||||
				fontValue:uni.getStorageSync('fontSize') || 8,
 | 
									fontValue:uni.getStorageSync('fontSize') || 8,
 | 
				
			||||||
				userName: uni.getStorageSync('userName')||"",
 | 
									userName: "",
 | 
				
			||||||
				phonenumber: uni.getStorageSync('phonenumber')||"",
 | 
									phonenumber: uni.getStorageSync('phonenumber')||"",
 | 
				
			||||||
				headPortraitUrl:"/static/images/my/face.png",
 | 
									headPortraitUrl:"/static/images/my/face.png",
 | 
				
			||||||
				defaultImg: '/static/images/my/face.png',
 | 
									defaultImg: '/static/images/my/face.png',
 | 
				
			||||||
| 
						 | 
					@ -134,6 +134,7 @@
 | 
				
			||||||
			getUserInfo() {
 | 
								getUserInfo() {
 | 
				
			||||||
				getUserInfo().then(res => {
 | 
									getUserInfo().then(res => {
 | 
				
			||||||
					this.headPortraitUrl= res.user.avatar
 | 
										this.headPortraitUrl= res.user.avatar
 | 
				
			||||||
 | 
										this.userName = res.user.nickName
 | 
				
			||||||
				})
 | 
									})
 | 
				
			||||||
			},
 | 
								},
 | 
				
			||||||
			// 获取钱包余额
 | 
								// 获取钱包余额
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -25,7 +25,7 @@
 | 
				
			||||||
				<view class="info-item">
 | 
									<view class="info-item">
 | 
				
			||||||
					<text class="label">姓名</text>
 | 
										<text class="label">姓名</text>
 | 
				
			||||||
					<view class="value-wrapper">
 | 
										<view class="value-wrapper">
 | 
				
			||||||
						<text class="value">{{userInfo.userName}}</text>
 | 
											<text class="value">{{userInfo.nickName}}</text>
 | 
				
			||||||
						<image class="arrow-icon" :src="require('@/static/images/my/enter.png')" mode="aspectFit"></image>
 | 
											<image class="arrow-icon" :src="require('@/static/images/my/enter.png')" mode="aspectFit"></image>
 | 
				
			||||||
					</view>
 | 
										</view>
 | 
				
			||||||
				</view>
 | 
									</view>
 | 
				
			||||||
| 
						 | 
					@ -34,9 +34,7 @@
 | 
				
			||||||
				<view class="info-item">
 | 
									<view class="info-item">
 | 
				
			||||||
					<text class="label">手机号</text>
 | 
										<text class="label">手机号</text>
 | 
				
			||||||
					<view class="value-wrapper">
 | 
										<view class="value-wrapper">
 | 
				
			||||||
						<!-- <u--input v-model="userInfo.phonenumber" style="font-size: 32rpx;color: #333;"  border="none" maxlength="11"></u--input> -->
 | 
					 | 
				
			||||||
						<uni-easyinput v-model="userInfo.phonenumber" :inputBorder="false" :clearable="false"  placeholder="请输入手机号" maxlength="11" color="#333" class="fs32" style="text-align: right;" />
 | 
											<uni-easyinput v-model="userInfo.phonenumber" :inputBorder="false" :clearable="false"  placeholder="请输入手机号" maxlength="11" color="#333" class="fs32" style="text-align: right;" />
 | 
				
			||||||
						<!-- <text class="value">{{userInfo.phonenumber}}</text> -->
 | 
					 | 
				
			||||||
						<image class="arrow-icon" :src="require('@/static/images/my/enter.png')" mode="aspectFit"></image>
 | 
											<image class="arrow-icon" :src="require('@/static/images/my/enter.png')" mode="aspectFit"></image>
 | 
				
			||||||
					</view>
 | 
										</view>
 | 
				
			||||||
				</view>
 | 
									</view>
 | 
				
			||||||
| 
						 | 
					@ -202,6 +200,13 @@
 | 
				
			||||||
				// 	"pwd":uni.getStorageSync('pwd'),
 | 
									// 	"pwd":uni.getStorageSync('pwd'),
 | 
				
			||||||
				// 	"sourceType":7
 | 
									// 	"sourceType":7
 | 
				
			||||||
				// } 
 | 
									// } 
 | 
				
			||||||
 | 
									if (!/^1[3456789]\d{9}$/.test(this.userInfo.phonenumber)) { 
 | 
				
			||||||
 | 
									   uni.showToast({
 | 
				
			||||||
 | 
										  title: '请输入正确的手机号',
 | 
				
			||||||
 | 
										  icon: 'none'
 | 
				
			||||||
 | 
											});
 | 
				
			||||||
 | 
										 return false;
 | 
				
			||||||
 | 
									} 
 | 
				
			||||||
				updateUserProfile(this.userInfo).then(res => {
 | 
									updateUserProfile(this.userInfo).then(res => {
 | 
				
			||||||
					if(res.code==200){
 | 
										if(res.code==200){
 | 
				
			||||||
						uni.showToast({
 | 
											uni.showToast({
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue