Ver Fonte

2023-10-7

hwq há 2 anos atrás
pai
commit
7d9d0226e9

+ 6 - 5
manifest.json

@@ -2,8 +2,8 @@
     "name" : "易趣CBB",
     "appid" : "__UNI__9A7699F",
     "description" : "",
-    "versionName" : "1.3.1",
-    "versionCode" : 131,
+    "versionName" : "1.3.7",
+    "versionCode" : 137,
     "transformPx" : false,
     "app-plus" : {
         /* 5+App特有相关 */
@@ -109,17 +109,18 @@
             "mode" : "hash"
         },
         "devServer" : {
+            "port" : 4526, //端口号
             "proxy" : {
                 "/api" : {
                     "target" : "https://www.shangshiyiqu.com", //请求的目标域名
 
                     // "target": "http://qudou.frp.liuniu946.com", //请求的目标域名
-                    "changeOrigin" : true,
-                    // "secure": false,
-                    "pathRewrite" : {}
+                    "changeOrigin" : true
                 }
             }
         },
+        // "secure": false,
+        // "pathRewrite" : {}
         "sdkConfigs" : {
             "maps" : {
                 "qqmap" : {

+ 2 - 2
pages.json

@@ -14,7 +14,7 @@
 					"titleNView": false
 				},
 				// #endif
-				"navigationBarTitleText": "平台首页"
+				"navigationBarTitleText": "尚视易趣"
 			}
 		},
 		{
@@ -367,7 +367,7 @@
 		{
 			"path": "pages/set/phone",
 			"style": {
-				"navigationBarTitleText": "实名认证"
+				"navigationBarTitleText": "绑定手机"
 			}
 		},
 		{

+ 11 - 8
pages/collection/bank.vue

@@ -9,18 +9,18 @@
 				<text>银行卡号</text>
 				<input type="text" v-model="id" value="" placeholder="请输入银行卡账号" />
 			</view>
-			<view class="item">
+			<view class="item top">
 				<text>所属银行</text>
 				<input type="text" v-model="idName" value="" placeholder="请输入银行" />
 			</view>
-			<view class="item">
+			<view class="item top">
 				<text>所属支行</text>
 				<input type="text" v-model="bankname" value="" placeholder="请输入所属支行" />
 			</view>
-			<view class="item">
+			<!-- <view class="item top">
 				<text>手机号</text>
 				<input type="text" v-model="phone" value="" placeholder="请输入手机号" />
-			</view>
+			</view> -->
 			<view class="item">
 				<text>验证码</text>
 				<view class="login_name flex">
@@ -112,9 +112,9 @@ export default {
 			if (!obj.id) {
 				return this.$api.msg('请输入银行卡号');
 			}
-			if (!obj.phone) {
-				return this.$api.msg('请输入手机号码');
-			}
+			// if (!obj.phone) {
+			// 	return this.$api.msg('请输入手机号码');
+			// }
 			if (!obj.bankname) {
 				return this.$api.msg('请输入所属支行');
 			}
@@ -126,11 +126,14 @@ export default {
 				name: obj.name,
 				bank: obj.idName,
 				payment: obj.id,
-				phone: obj.phone,
+				phone:obj.userInfo.phone,
 				bank_name: obj.bankname,
 				captcha:obj.code
 			}).then(e => {
 				obj.$api.msg('修改成功');
+				uni.redirectTo({
+					url: './collection',
+				});
 			});
 		}
 	}

+ 6 - 6
pages/collection/collection.vue

@@ -1,29 +1,29 @@
 <template>
 	<view class="content">
 		<view class="collection-box">
-			<view class="collection-item">
+			<view class="collection-item" @click="nav('/pages/collection/bank')">
 				<view class="left">
 					<view class="img"><image src="../../static/user/mybank.png" mode=""></image></view>
 					<view class="bank">银行卡</view>
 				</view>
-				<view class="gg" @click="nav('/pages/collection/bank')">
+				<view class="gg" >
 					<view class="status" v-if="bankData.name != null">{{ bankData.name}}</view>
 					<view class="status" v-else>未添加</view>
 					<view class="img1"><text class="iconfont iconenter"></text></view>
 				</view>
 			</view>
-			<view class="collection-item">
+			<view class="collection-item" @click="nav('/pages/collection/zfb')">
 				<view class="left">
 					<view class="img"><image src="../../static/user/zfb.png" mode=""></image></view>
 					<view class="bank">支付宝</view>
 				</view>
-				<view class="gg" @click="nav('/pages/collection/zfb')">
+				<view class="gg" >
 					<view class="status" v-if="aliData.name != null">{{aliData.name}}</view>
 					<view class="status" v-else>未添加</view>
 					<view class="img1"><text class="iconfont iconenter"></text></view>
 				</view>
 			</view>
-			<view class="collection-item">
+			<view class="collection-item" @click="nav('/pages/collection/wx')">
 				<view class="left">
 					<view class="img">
 						<image src="../../static/user/wx.png" mode=""></image>
@@ -32,7 +32,7 @@
 						微信
 					</view>
 				</view>
-				<view class="gg" @click="nav('/pages/collection/wx')">
+				<view class="gg" >
 					<view class="status" v-if="wx.name != null">{{wx.name}}</view>
 					<view class="status" v-else>未添加</view>
 					<view class="img1">

+ 3 - 0
pages/collection/wx.vue

@@ -140,6 +140,9 @@
 					})
 					.then(e => {
 						obj.$api.msg('修改成功');
+						uni.redirectTo({
+							url: './collection',
+						});
 					})
 					.catch(e => {
 						console.log(e);

+ 218 - 144
pages/collection/zfb.vue

@@ -5,184 +5,258 @@
 				<text>真实姓名</text>
 				<input type="text" v-model="name" value="" placeholder="请输入真实姓名" />
 			</view>
-			<view class="item">
+			<view class="item top">
 				<text>支付宝账号</text>
 				<input type="text" v-model="id" value="" placeholder="请输入支付宝账号" />
 			</view>
-			<view class="item">
+			<!-- <view class="item top">
 				<text>手机号</text>
 				<input type="text" v-model="phone" value="" placeholder="请输入手机号" />
-			</view>
-			<view class="item">
+			</view> -->
+			<view class="item top">
 				<text>验证码</text>
 				<view class="login_name flex">
 					<input class="uni-input" v-model="code" focus placeholder="请输入验证码" />
 					<view class="code" @click="verification">{{ countDown == 0 ? '验证码' : countDown }}</view>
 				</view>
 			</view>
+			<view class="erweima">
+				<text>收款码</text>
+				<view class="img" @click="uploads()">
+					<image src="../../static/user/erweima.png" mode="" v-if="image == ''"></image>
+					<image :src="image" mode="" v-else></image>
+				</view>
+			</view>
 		</view>
 		<view class="button" @click="confirm()">确认</view>
 	</view>
 </template>
 
 <script>
-import { orderData, getUserInfo } from '@/api/user.js';
-import { mapState, mapMutations } from 'vuex';
-import { auction,pay_list } from '@/api/wallet.js';
-import { verify } from '@/api/login.js';
-export default {
-	computed: {
-		...mapState('user', ['userInfo', 'orderInfo', 'hasLogin'])
-	},
-	data() {
-		return {
-			name: '',
-			id: '',
-			phone:'',
-			countDown:0,//倒计时
-			code:'',//验证码
-			time:''
-		};
-	},
-	watch: {
-		// 监听倒计时
-		countDown(i) {
-			if (i == 0) {
-				clearInterval(this.time);
-			}
-		}
-	},
-	onLoad() {
-		pay_list().then(({data}) =>{
-			if(data.zfb != ''){
-				this.name = data.zfb.name
-				this.id = data.zfb.payment
-				this.phone = data.zfb.phone
-			}
-		})
-	},
-	methods: {
-		...mapMutations('user', ['setUserInfo', 'setOrderInfo']),
-		verification() {
-			let obj = this;
-			if (!this.userInfo.phone) {
-				this.$api.msg('请绑定手机号');
-				return;
+	import {
+		upload
+	} from '@/api/order.js'
+	import {
+		orderData,
+		getUserInfo
+	} from '@/api/user.js';
+	import {
+		mapState,
+		mapMutations
+	} from 'vuex';
+	import {
+		auction,
+		pay_list
+	} from '@/api/wallet.js';
+	import {
+		verify
+	} from '@/api/login.js';
+	export default {
+		computed: {
+			...mapState('user', ['userInfo', 'orderInfo', 'hasLogin'])
+		},
+		data() {
+			return {
+				name: '',
+				id: '',
+				phone: '',
+				countDown: 0, //倒计时
+				code: '', //验证码
+				time: '',
+				image: ''
+			};
+		},
+		watch: {
+			// 监听倒计时
+			countDown(i) {
+				if (i == 0) {
+					clearInterval(this.time);
+				}
 			}
-			// 判断是否在倒计时
-			if (obj.countDown > 0) {
-				return false;
-			} else {
-				obj.countDown = 60;
-				obj.time = setInterval(() => {
-					obj.countDown--;
-				}, 1000);
-				//调用验证码接口
-				verify({
-					phone: obj.userInfo.phone,
-					type: ''
+		},
+		onLoad() {
+			pay_list().then(({
+				data
+			}) => {
+				if (data.zfb != '') {
+					this.name = data.zfb.name
+					this.id = data.zfb.payment
+					this.phone = data.zfb.phone
+					this.image = data.zfb.image
+				}
+			})
+		},
+		methods: {
+			...mapMutations('user', ['setUserInfo', 'setOrderInfo']),
+			uploads() {
+				upload({
+					filename: ''
+				}).then(data => {
+					this.image = data[0].url;
 				})
-					.then(({ data }) => {})
-					.catch(err => {
-						console.log(err);
+			},
+			verification() {
+				let obj = this;
+				if (!this.userInfo.phone) {
+					this.$api.msg('请绑定手机号');
+					return;
+				}
+				// 判断是否在倒计时
+				if (obj.countDown > 0) {
+					return false;
+				} else {
+					obj.countDown = 60;
+					obj.time = setInterval(() => {
+						obj.countDown--;
+					}, 1000);
+					//调用验证码接口
+					verify({
+							phone: obj.userInfo.phone,
+							type: ''
+						})
+						.then(({
+							data
+						}) => {})
+						.catch(err => {
+							console.log(err);
+						});
+				}
+			},
+			confirm() {
+				let obj = this;
+				if (!obj.name) {
+					return this.$api.msg('请输入提款人姓名');
+				}
+				if (!obj.id) {
+					return this.$api.msg('请输入支付宝账号');
+				}
+				// if (!obj.phone) {
+				// 	return this.$api.msg('请输入手机号码');
+				// }
+				if (!obj.code) {
+					return this.$api.msg('请输入验证码');
+				}
+				if (!obj.image) {
+					return this.$api.msg('请上传支付凭证');
+				}
+				auction({
+						type: 2,
+						name: obj.name,
+						payment: obj.id,
+						phone: obj.userInfo.phone,
+						captcha: obj.code,
+						image: obj.image,
+					})
+					.then(e => {
+						obj.$api.msg('修改成功');
+						uni.redirectTo({
+							url: './collection',
+						});
+					})
+					.catch(e => {
+						console.log(e);
 					});
+			},
+		}
+	};
+</script>
+
+<style lang="scss">
+	page,
+	.content {
+		height: 100%;
+		padding: 0;
+		margin: 0;
+	}
+
+	.top {
+		border-bottom: 1rpx solid #f3f3f3;
+	}
+
+	.box {
+		background: #ffffff;
+		margin: 20rpx 0 70rpx 0;
+
+		.item {
+			display: flex;
+			align-items: center;
+
+			text {
+				margin: 0 40rpx 0 25rpx;
+				width: 150rpx;
+				font-size: 30rpx;
+				font-family: PingFang SC;
+				font-weight: 400;
+				color: #333333;
+				line-height: 100rpx;
 			}
-		},
-		confirm() {
-			let obj = this;
-			if (!obj.name) {
-				return this.$api.msg('请输入提款人姓名');
+
+			input {
+				height: 100rpx;
+				display: inline-block;
+				font-size: 28rpx;
+				font-family: PingFang SC;
+				font-weight: 400;
+				color: #999999;
+				line-height: 100rpx;
 			}
-			if (!obj.id) {
-				return this.$api.msg('请输入支付宝账号');
+
+			.uni-input {
+				text-align: left;
+				width: 325rpx;
+				font-size: 28rpx !important;
 			}
-			if (!obj.phone) {
-				return this.$api.msg('请输入手机号码');
+
+			.login_name {
+				color: #333333;
 			}
-			if (!obj.code) {
-				return this.$api.msg('请输入验证码');
+
+			.code {
+				color: #db292b;
+				font-size: 23rpx;
+				border-left: 1px solid #eeeeee;
+				width: 150rpx;
+				flex-shrink: 0;
+				text-align: center;
 			}
-			auction({
-				type:2,
-				name: obj.name,
-				payment: obj.id,
-				phone: obj.phone,
-				captcha:obj.code
-			})
-				.then(e => {
-					obj.$api.msg('修改成功');
-				})
-				.catch(e => {
-					console.log(e);
-				});
-		},
+		}
 	}
-};
-</script>
 
-<style lang="scss">
-page,
-.content {
-	height: 100%;
-	padding: 0;
-	margin: 0;
-}
-.top {
-	border-bottom: 1rpx solid #f3f3f3;
-}
-.box {
-	background: #ffffff;
-	margin: 20rpx 0 70rpx 0;
-	.item {
+	.button {
+		text-align: center;
+		width: 560rpx;
+		height: 80rpx;
+		background: #FD3B39;
+		border-radius: 40rpx;
+		font-size: 30rpx;
+		font-family: PingFangSC;
+		font-weight: 500;
+		color: #ffffff;
+		line-height: 80rpx;
+		margin: 0 auto;
+	}
+	.erweima {
+		padding: 30rpx 0;
 		display: flex;
-		align-items: center;
+	
 		text {
-			margin: 0 40rpx 0 25rpx;
+			margin: 0 30rpx;
 			width: 150rpx;
 			font-size: 30rpx;
 			font-family: PingFang SC;
 			font-weight: 400;
 			color: #333333;
-			line-height: 100rpx;
-		}
-		input {
-			height: 100rpx;
-			display: inline-block;
-			font-size: 28rpx;
-			font-family: PingFang SC;
-			font-weight: 400;
-			color: #999999;
-			line-height: 100rpx;
-		}
-		.uni-input {
-			text-align: left;
-			width: 325rpx;
-			font-size: 28rpx !important;
-		}
-		.login_name {
-			color: #333333;
+	
 		}
-		.code {
-			color: #db292b;
-			font-size: 23rpx;
-			border-left: 1px solid #eeeeee;
-			width: 150rpx;
-			flex-shrink: 0;
-			text-align: center;
+	
+		.img {
+			width: 160rpx;
+			height: 160rpx;
+	
+			image {
+				width: 100%;
+				height: 100%;
+			}
 		}
 	}
-}
-.button {
-	text-align: center;
-	width: 560rpx;
-	height: 80rpx;
-	background: #FD3B39;
-	border-radius: 40rpx;
-	font-size: 30rpx;
-	font-family: PingFangSC;
-	font-weight: 500;
-	color: #ffffff;
-	line-height: 80rpx;
-	margin: 0 auto;
-}
-</style>
+</style>

+ 13 - 6
pages/public/login.vue

@@ -10,14 +10,14 @@
 		<view class="login_text">
 			<view class="login_input flex">
 				<view class="login_img">
-					<image src="/static/icon/img03.png"></image>
+					<image src="/static/icon/login_name.png" mode="heightFix"></image>
 				</view>
 				<view class="login_name"><input class="uni-input" v-model="username" focus placeholder="请输入手机号" />
 				</view>
 			</view>
 			<view class="login_input flex">
 				<view class="login_img">
-					<image src="/static/icon/img04.png"></image>
+					<image src="/static/icon/login_pw.png" mode="heightFix"></image>
 				</view>
 				<view class="login_name"><input class="uni-input" type="password" v-model="passward" focus
 						placeholder="请输入密码" /></view>
@@ -319,9 +319,15 @@
 		border-top-right-radius: 40rpx;
 
 		.login_input {
-			border-bottom: 1px solid #f0f0f0;
-			margin-bottom: 65rpx;
-
+			border: 1px solid #f0f0f0;
+			padding: 20rpx;
+			border-radius: 99rpx;
+			margin-bottom: 40rpx;
+			.login_img{
+				text-align: center;
+				flex-shrink: 0;
+				width: 60rpx;
+			}
 			.login_img image {
 				height: 35rpx;
 				width: 29rpx;
@@ -330,12 +336,13 @@
 
 			.uni-input {
 				text-align: left;
-				width: 470rpx;
+				width: 100%;
 				font-size: 28rpx !important;
 			}
 
 			.login_name {
 				color: #333333;
+				flex-grow: 1;
 			}
 		}
 

+ 269 - 243
pages/public/register.vue

@@ -1,295 +1,321 @@
 <template>
 	<view class="container">
 		<view class="container_text">
-			<image class="banner-img" src="/static/img/img01.png" mode="scaleToFill"></image>
-			<view class="title-img"><image class="title-image" src="../../static/img/login-title.png" mode=""></image></view>
+			<image class="banner-img" src="/static/img/img02.png" mode="scaleToFill"></image>
 		</view>
-		<view class="loginTitle"><text>欢迎注册易趣CBB</text></view>
 		<view class="login_text">
 			<view class="login_input flex">
-				<view class="login_img"><image src="/static/icon/img03.png"></image></view>
+				<view class="login_img">
+					<!-- <image src="/static/icon/img03.png" mode="heightFix"></image> -->
+					+86
+				</view>
 				<view class="login_name"><input class="uni-input" v-model="phone" focus placeholder="请输入手机号" /></view>
 			</view>
 			<view class="login_input flex">
-				<view class="login_img"><image src="/static/icon/img04.png"></image></view>
-				<view class="login_name"><input class="uni-input" type="password" v-model="password" focus placeholder="请输入密码" /></view>
+				<view class="login_img">
+					<image src="/static/icon/login_pw2.png" mode="heightFix"></image>
+				</view>
+				<view class="login_name flex">
+					<input class="uni-input width" v-model="code" focus placeholder="请输入验证码" />
+					<view class="code" @click="verification">{{ countDown == 0 ? '验证码' : countDown }}</view>
+				</view>
 			</view>
 			<view class="login_input flex">
-				<view class="login_img"><image src="/static/icon/img04.png"></image></view>
-				<view class="login_name"><input class="uni-input" type="password" v-model="repassword" focus placeholder="请重复输入密码" /></view>
+				<view class="login_img">
+					<image src="/static/icon/login_pw.png" mode="heightFix"></image>
+				</view>
+				<view class="login_name"><input class="uni-input" type="password" v-model="password" focus
+						placeholder="请输入密码" /></view>
 			</view>
 			<view class="login_input flex">
-				<view class="login_img"><image src="/static/icon/img07.png"></image></view>
-				<view class="login_name"><input class="uni-input" type="text" v-model="invitation" focus placeholder="请输入邀请码" /></view>
+				<view class="login_img">
+					<image src="/static/icon/login_pw.png" mode="heightFix"></image>
+				</view>
+				<view class="login_name"><input class="uni-input" type="password" v-model="repassword" focus
+						placeholder="请重复输入密码" /></view>
 			</view>
+
 			<view class="login_input flex">
-				<view class="login_img"><image src="/static/icon/img06.png"></image></view>
-				<view class="login_name flex">
-					<input class="uni-input width" v-model="code" focus placeholder="请输入验证码" />
-					<view class="code" @click="verification">{{ countDown == 0 ? '验证码' : countDown }}</view>
+				<view class="login_img">
+					<image src="/static/icon/login_name.png" mode="heightFix"></image>
 				</view>
+				<view class="login_name"><input class="uni-input" type="text" v-model="invitation" focus
+						placeholder="请输入邀请码" /></view>
 			</view>
 			<view><button type="green" @click="register" class="uni-button uni-button-green">注册账号</button></view>
-			<view><button class="uni-button uni-button-green uni-button-green-plain" type="green" plain="true" hover-class="none" @click="login">返回登录</button></view>
+			<view><button class="uni-button uni-button-green uni-button-green-plain" type="green" plain="true"
+					hover-class="none" @click="login">返回登录</button></view>
 		</view>
 	</view>
 </template>
 <script>
-import { register, verify } from '@/api/login.js';
-export default {
-	data() {
-		return {
-			phone: '', //用户
-			password: '', //密码
-			repassword: '',
-			invitation: '', //邀请码
-			code: '', //验证码
-			time: '', //保存倒计时对象
-			countDown: 0 //倒计时
-		};
-	},
-	onLoad(options) {
-		// 获取扫码邀请人id
-		this.invitation = uni.getStorageSync('spread') || '';
-		if (options.spread) {
-			this.invitation = options.spread;
-		}
-	},
-	watch: {
-		// 监听倒计时
-		countDown(i) {
-			if (i == 0) {
-				clearInterval(this.time);
-			}
-		}
-	},
-	methods: {
-		// 注册
-		register() {
-			let obj = this;
-			if (obj.phone == '') {
-				obj.$api.msg('请输入电话号码');
-				return;
-			}
-			if (!/(^1[2|3|4|5|6|7|8|9][0-9]{9}$)/.test(this.phone)) {
-				obj.$api.msg('请输入正确的手机号');
-				return;
-			}
-			if (obj.password == '') {
-				obj.$api.msg('请输入密码');
-				return;
-			}
-			if (obj.repassword == '') {
-				obj.$api.msg('请再次输入密码');
-				return;
-			}
-			if (obj.repassword != obj.password) {
-				obj.$api.msg('两次密码不正确');
-				return;
-			}
-			// if ((obj.invitation = '')) {
-			// 	obj.$api.msg('请输入邀请码');
-			// 	return;
-			// }
-			// if (obj.code == '') {
-			// 	obj.$api.msg('请输入验证码');
-			// 	return;
-			// }
-			register({
-				account: obj.phone, //账号
-				captcha: obj.code, //验证码
-				password: obj.password, //密码
-				spread: this.invitation //上级推广人
-			}).then(function(e) {
-				uni.showToast({
-					title: '注册成功',
-					duration: 2000,
-					position: 'top'
-				});
-				setTimeout(function() {
-					uni.navigateTo({
-						url: '/pages/public/login'
-					});
-				}, 1000);
-			});
-			//调用注册接口,成功跳转登录页
+	import {
+		register,
+		verify
+	} from '@/api/login.js';
+	export default {
+		data() {
+			return {
+				phone: '', //用户
+				password: '', //密码
+				repassword: '',
+				invitation: '', //邀请码
+				code: '', //验证码
+				time: '', //保存倒计时对象
+				countDown: 0 //倒计时
+			};
 		},
-		//发送验证码
-		verification() {
-			let obj = this;
-			if (this.phone == '') {
-				this.$api.msg('请输入电话号码');
-				return;
+		onLoad(options) {
+			// 获取扫码邀请人id
+			this.invitation = uni.getStorageSync('spread') || '';
+			if (options.spread) {
+				this.invitation = options.spread;
 			}
-			if (this.phone.length < 11) {
-				this.$api.msg('请输入正确的手机号');
-				return;
+		},
+		watch: {
+			// 监听倒计时
+			countDown(i) {
+				if (i == 0) {
+					clearInterval(this.time);
+				}
 			}
-			// 判断是否在倒计时
-			if (obj.countDown > 0) {
-				return false;
-			} else {
-				obj.countDown = 60;
-				obj.time = setInterval(() => {
-					obj.countDown--;
-				}, 1000);
-				//调用验证码接口
-				verify({
-					phone: obj.phone,
-					type: 'register'
-				})
-					.then(({ data }) => {})
-					.catch(err => {
-						console.log(err);
+		},
+		methods: {
+			// 注册
+			register() {
+				let obj = this;
+				if (obj.phone == '') {
+					obj.$api.msg('请输入电话号码');
+					return;
+				}
+				if (!/(^1[2|3|4|5|6|7|8|9][0-9]{9}$)/.test(this.phone)) {
+					obj.$api.msg('请输入正确的手机号');
+					return;
+				}
+				if (obj.password == '') {
+					obj.$api.msg('请输入密码');
+					return;
+				}
+				if (obj.repassword == '') {
+					obj.$api.msg('请再次输入密码');
+					return;
+				}
+				if (obj.repassword != obj.password) {
+					obj.$api.msg('两次密码不正确');
+					return;
+				}
+				// if ((obj.invitation = '')) {
+				// 	obj.$api.msg('请输入邀请码');
+				// 	return;
+				// }
+				// if (obj.code == '') {
+				// 	obj.$api.msg('请输入验证码');
+				// 	return;
+				// }
+				register({
+					account: obj.phone, //账号
+					captcha: obj.code, //验证码
+					password: obj.password, //密码
+					spread: this.invitation //上级推广人
+				}).then(function(e) {
+					uni.showToast({
+						title: '注册成功',
+						duration: 2000,
+						position: 'top'
 					});
+					setTimeout(function() {
+						uni.navigateTo({
+							url: '/pages/public/login'
+						});
+					}, 1000);
+				});
+				//调用注册接口,成功跳转登录页
+			},
+			//发送验证码
+			verification() {
+				let obj = this;
+				if (this.phone == '') {
+					this.$api.msg('请输入电话号码');
+					return;
+				}
+				if (this.phone.length < 11) {
+					this.$api.msg('请输入正确的手机号');
+					return;
+				}
+				// 判断是否在倒计时
+				if (obj.countDown > 0) {
+					return false;
+				} else {
+					obj.countDown = 60;
+					obj.time = setInterval(() => {
+						obj.countDown--;
+					}, 1000);
+					//调用验证码接口
+					verify({
+							phone: obj.phone,
+							type: 'register'
+						})
+						.then(({
+							data
+						}) => {})
+						.catch(err => {
+							console.log(err);
+						});
+				}
+			},
+			login() {
+				//返回登录
+				uni.navigateTo({
+					url: '/pages/public/login'
+				});
 			}
-		},
-		login() {
-			//返回登录
-			uni.navigateTo({
-				url: '/pages/public/login'
-			});
 		}
-	}
-};
+	};
 </script>
 
 <style lang="scss">
-page {
-	height: 100%;
-}
-.container {
-	width: 100%;
-	height: 100%;
-	background-size: 100%;
-}
-.container_text {
-	position: relative;
-	width: 100%;
-	height: 500rpx;
-	top: 0rpx;
-	.banner-img {
+	page {
+		height: 100%;
+	}
+
+	.container {
 		width: 100%;
 		height: 100%;
+		background-size: 100%;
 	}
-	.title-img {
-		position: absolute;
-		left: 50%;
-		top: 100rpx;
-		margin-left: -130rpx;
-		width: 260rpx;
-		height: 156rpx;
-		.title-image {
-			width: 260rpx;
-			height: 156rpx;
+
+	.container_text {
+		position: relative;
+		width: 100%;
+		height: 500rpx;
+		top: 0rpx;
+
+		.banner-img {
+			width: 100%;
+			height: 100%;
 		}
 	}
-}
-.login_text {
-	margin: -100rpx 0 0;
-	position: relative;
-	padding: 100rpx 102rpx;
-	background-color: #ffffff;
-	border-top-left-radius: 40rpx;
-	border-top-right-radius: 40rpx;
-	.login_input {
-		border-bottom: 1px solid #f0f0f0;
-		margin-bottom: 65rpx;
-		.login_img image {
-			height: 35rpx;
-			width: 29rpx;
-			margin-right: 20rpx;
+
+	.login_text {
+		margin: -100rpx 0 0;
+		position: relative;
+		padding: 100rpx 102rpx;
+		background-color: #ffffff;
+		border-top-left-radius: 40rpx;
+		border-top-right-radius: 40rpx;
+
+		.login_input {
+			border: 1px solid #f0f0f0;
+			padding: 20rpx;
+			border-radius: 99rpx;
+			margin-bottom: 40rpx;
+			.login_img{
+				text-align: center;
+				flex-shrink: 0;
+				width: 60rpx;
+				color:#dc262b ;
+			}
+			.login_img image {
+				height: 35rpx;
+				// width: 29rpx;
+				// margin-right: 20rpx;
+			}
+
+			.uni-input {
+				text-align: left;
+				width: 100%;
+				font-size: 28rpx !important;
+			}
+
+			.login_name {
+				color: #333333;
+				flex-grow: 1;
+			}
 		}
-		.uni-input {
-			text-align: left;
-			width: 470rpx;
-			font-size: 28rpx !important;
+
+		.other {
+			margin-top: 60rpx;
+
+			.fenge {
+				width: 30%;
+				height: 2rpx;
+				background-color: #eeeeee;
+			}
+
+			.qita {
+				font-size: 28rpx;
+				color: #999999;
+			}
 		}
-		.login_name {
-			color: #333333;
+
+		.weixin {
+			width: 75rpx;
+			height: 75rpx;
+			margin: 25rpx auto;
 		}
-	}
 
-	.other {
-		margin-top: 60rpx;
-		.fenge {
-			width: 30%;
-			height: 2rpx;
-			background-color: #eeeeee;
+		.weixin image {
+			width: 100%;
+			height: 100%;
 		}
-		.qita {
+
+		.weixin_text {
+			text-align: center;
 			font-size: 28rpx;
 			color: #999999;
 		}
+
+		.forget {
+			font-size: 28rpx;
+			width: 100%;
+			text-align: right;
+			color: #999999;
+		}
+
+		.uni-button-green {
+			color: #ffffff;
+			background-color: #db292b;
+			margin: 40rpx 10rpx;
+			border-radius: 50rpx;
+		}
+
+		.uni-button-green-plain {
+			border: 1px solid #db292b;
+			margin: 40rpx 10rpx;
+			border-radius: 50rpx;
+			color: #db292b;
+			background-color: #ffffff;
+		}
+
+		.uni-button {
+			height: 85rpx;
+			line-height: 85rpx;
+		}
 	}
-	.weixin {
-		width: 75rpx;
-		height: 75rpx;
-		margin: 25rpx auto;
-	}
-	.weixin image {
-		width: 100%;
-		height: 100%;
-	}
-	.weixin_text {
-		text-align: center;
-		font-size: 28rpx;
-		color: #999999;
-	}
+
 	.forget {
-		font-size: 28rpx;
-		width: 100%;
-		text-align: right;
-		color: #999999;
+		width: 100rpx;
+		font-size: 24rpx;
+		color: #ffffff;
+		margin: 0px auto;
+		border-bottom: 1px solid #ffffff;
 	}
 
-	.uni-button-green {
-		color: #ffffff;
-		background-color: #db292b;
-		margin: 40rpx 10rpx;
-		border-radius: 50rpx;
+	.width {
+		flex-grow: 1;
 	}
-	.uni-button-green-plain {
-		border: 1px solid #db292b;
-		margin: 40rpx 10rpx;
-		border-radius: 50rpx;
+
+	.code {
 		color: #db292b;
-		background-color: #ffffff;
-	}
-	.uni-button {
-		height: 85rpx;
-		line-height: 85rpx;
+		font-size: 23rpx;
+		border-left: 1px solid #eeeeee;
+		width: 150rpx;
+		flex-shrink: 0;
+		text-align: center;
 	}
-}
-.loginTitle {
-	position: absolute;
-	top: 270rpx;
-	width: 100%;
-	text-align: center;
-	color: white;
-	font-size: 40rpx;
-}
 
-.forget {
-	width: 100rpx;
-	font-size: 24rpx;
-	color: #ffffff;
-	margin: 0px auto;
-	border-bottom: 1px solid #ffffff;
-}
-.width {
-	width: 325rpx !important;
-}
-.code {
-	color: #db292b;
-	font-size: 23rpx;
-	border-left: 1px solid #eeeeee;
-	width: 150rpx;
-	flex-shrink: 0;
-	text-align: center;
-}
-uni-button {
-	height: 80rpx !important;
-	line-height: 80rpx !important;
-}
-</style>
+	uni-button {
+		height: 80rpx !important;
+		line-height: 80rpx !important;
+	}
+</style>

+ 54 - 27
pages/user/myfans.vue

@@ -35,12 +35,12 @@
 			我的粉丝列表
 		</view>
 		<view class="fans-list-tit flex">
+			<view class="list-item">
+				姓名
+			</view>
 			<view class="list-item">
 				ID
 			</view>
-			<!-- <view class="list-item">
-				粉丝
-			</view> -->
 			<view class="list-item">
 				当日业绩
 			</view>
@@ -49,13 +49,14 @@
 			</view>
 		</view>
 		<scroll-view scroll-y="true" class="swiper-box" :style="{'height':height}" @scrolltolower="getMyfans()">
-			<view class="fans-list-val flex" v-for="(item,index) in list" :style="{'background':index%2 ==0 ? '#F9F9F9':'#fff'}">
+			<view class="fans-list-val flex" v-for="(item,index) in list"
+				:style="{'background':index%2 ==0 ? '#F9F9F9':'#fff'}">
 				<view class="list-item clamp">
-					{{item.nickname}}
+					{{item.real_name||item.nickname}}
+				</view>
+				<view class="list-item">
+					{{item.uid}}
 				</view>
-				<!-- <view class="list-item">
-					粉丝
-				</view> -->
 				<view class="list-item">
 					{{item.money}}
 				</view>
@@ -65,11 +66,13 @@
 			</view>
 			<uni-load-more :status="loadingType"></uni-load-more>
 		</scroll-view>
-	</view>
-</template>
-
+	</view>
+</template>
+
 <script>
-	import { getMyfans } from '@/api/user.js'
+	import {
+		getMyfans
+	} from '@/api/user.js'
 	export default {
 		data() {
 			return {
@@ -102,42 +105,55 @@
 		methods: {
 			getMyfans() {
 				let obj = this
-				if(obj.loadingType == 'loading' || obj.loadingType == 'noMore') {
+				if (obj.loadingType == 'loading' || obj.loadingType == 'noMore') {
 					return
 				}
-				
+
 				getMyfans({
 					page: obj.page,
 					limit: obj.limit
 				}).then(res => {
 					console.log(res)
-					obj.fans = res.data
+					obj.fans = res.data;
+					let ar = res.data.user.map((item)=>{
+						if(item.real_name.length>2){
+							let str =item.real_name.slice(1,item.real_name.length-1);
+							let str2 = str.replace(/.*/g,'*');
+							item.real_name =item.real_name.slice(0,1)+str2+item.real_name.slice(item.real_name.length-1);
+						}else if(item.real_name.length==2){
+							item.real_name =item.real_name.slice(0,1)+"*";
+						}
+						return item
+					})
 					obj.list = obj.list.concat(res.data.user)
 					obj.page++
-					if(res.data.user.length == obj.limit) {
+					if (res.data.user.length == obj.limit) {
 						obj.loadingType = 'more'
-					}else {
+					} else {
 						obj.loadingType = 'noMore'
 					}
 				})
 			}
 		}
-		
-	}
-</script>
-
+
+	}
+</script>
+
 <style lang="scss" scoped>
 	page {
 		background-color: #f3f5f4;
 		height: 100%;
 	}
+
 	.content {
 		background-color: #f3f5f4;
 	}
+
 	.top-fan {
 		position: relative;
 		width: 750rpx;
 		height: 336rpx;
+
 		image {
 			position: absolute;
 			top: 0;
@@ -147,6 +163,7 @@
 			height: 100%;
 		}
 	}
+
 	.fans-base {
 		position: relative;
 		z-index: 2;
@@ -161,13 +178,16 @@
 		font-family: PingFang SC;
 		font-weight: 500;
 		color: #666666;
+
 		.jg {
 			width: 2rpx;
 			height: 96rpx;
 			background: #DCDCDC;
 		}
+
 		.base-item {
 			flex-grow: 1;
+
 			.base-item-val {
 				font-size: 50rpx;
 				font-family: PingFang SC;
@@ -176,6 +196,7 @@
 			}
 		}
 	}
+
 	.fans-tit {
 		font-size: 32rpx;
 		font-family: PingFang SC;
@@ -183,35 +204,41 @@
 		color: #0C1732;
 		padding: 45rpx 0 29rpx 40rpx;
 	}
+
 	.fans-list-tit {
 		width: 710rpx;
 		height: 100rpx;
 		background: #FFE1E2;
 		border-radius: 20rpx 20rpx 0px 0px;
 		margin: auto;
-		text-align: center;;
+		text-align: center;
+		;
 		font-size: 30rpx;
 		font-family: PingFang SC;
 		font-weight: bold;
 		color: #DC262B;
+
 		.list-item {
-			width: 33%;
+			width: 25%;
 			flex-shrink: 0;
 		}
 	}
+
 	.fans-list-val {
 		width: 710rpx;
 		height: 100rpx;
 		margin: auto;
-		text-align: center;;
+		text-align: center;
+		;
 		font-size: 30rpx;
 		font-family: PingFang SC;
 		font-weight: bold;
 		color: #0C1732;
+
 		.list-item {
 			// flex-grow: 1;
-			width: 33%;
+			width: 25%;
 			flex-shrink: 0;
 		}
-	}
-</style>
+	}
+</style>

+ 25 - 20
pages/user/user.vue

@@ -65,17 +65,17 @@
 			</view>
 		</view>
 		<uni-list class="tool-list">
-			<uni-list-item title="收款信息" @click="navTo('/pages/collection/collection')"
-				thumb="/static/icon/skxx.png"></uni-list-item>
-			<uni-list-item title="实名认证" @click="navTo('/pages/user/approve')"
-				thumb="/static/icon/bdsj.png"></uni-list-item>
-			<uni-list-item title="收货地址" @click="navTo('/pages/set/address')"
-				thumb="/static/icon/shdz.png"></uni-list-item>
-			<uni-list-item title="客服" @click="openKf()" thumb="/static/icon/kf.png"></uni-list-item>
-			<uni-list-item title="设置" @click="navTo('/pages/set/set')" thumb="/static/icon/uset.png"></uni-list-item>
+			<uni-list-item class="item" title="收款信息" @click="navTo('/pages/collection/collection')"
+				thumb="/static/icon/user_page.png"></uni-list-item>
+			<uni-list-item class="item" title="实名认证" @click="navTo('/pages/user/approve')"
+				thumb="/static/icon/user_name.png"></uni-list-item>
+			<uni-list-item class="item" title="收货地址" @click="navTo('/pages/set/address')"
+				thumb="/static/icon/user_address.png"></uni-list-item>
+			<uni-list-item class="item" title="客服" @click="openKf()" thumb="/static/icon/user_serve.png"></uni-list-item>
+			<uni-list-item class="item" title="设置" @click="navTo('/pages/set/set')" thumb="/static/icon/user_set.png"></uni-list-item>
 			<!-- #ifdef H5 -->
-			<uni-list-item title="绑定手机" @click="navTo('/pages/set/phone')"
-				thumb="/static/icon/phone.png"></uni-list-item>
+			<uni-list-item class="item" title="绑定手机" @click="navTo('/pages/set/phone')"
+				thumb="/static/icon/user_bind.png"></uni-list-item>
 			<!-- #endif -->
 			<!-- <uni-list-item title="关于我们" @click="navTo('/pages/user/about')" thumb="/static/icon/img09.png"></uni-list-item> -->
 		</uni-list>
@@ -750,7 +750,7 @@
 	}
 
 	.user-top {
-		height: 660rpx;
+		height:620rpx;
 		position: relative;
 
 		.user-top-bg {
@@ -869,8 +869,6 @@
 			bottom: 105rpx;
 			height: 148rpx;
 			width: 750rpx;
-
-			// background-color: #bfa;
 			.sy-item {
 				flex-grow: 1;
 				text-align: center;
@@ -937,7 +935,8 @@
 	}
 
 	.tool-box {
-		padding: 60rpx 0 0;
+		padding-top: 30rpx;
+		padding-bottom: 46rpx;
 		width: 690rpx;
 		background: #ffffff;
 		box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.06);
@@ -946,12 +945,13 @@
 		flex-wrap: wrap;
 		justify-content: flex-start;
 		align-content: space-around;
-
+		margin-top: -100rpx;
+		z-index: 10;
+		position: relative;
 		.tool-item {
-			width: 25%;
+			width: 20%;
 			height: 120rpx;
 			flex-shrink: 0;
-			margin-bottom: 60rpx;
 			flex-direction: column;
 			align-content: space-between;
 			justify-content: center;
@@ -980,6 +980,7 @@
 
 			.tool-item-name {
 				display: inline-block;
+				font-size: 26rpx;
 			}
 		}
 	}
@@ -987,9 +988,13 @@
 	.tool-list {
 		width: 690rpx;
 		margin: auto;
-		background: #ffffff;
-		box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.06);
-		border-radius: 20rpx;
+		background: transparent;
+		.item{
+			background: #ffffff;
+			border-radius: 20rpx;
+			box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.06);
+			margin-bottom: 10rpx;
+		}
 	}
 
 	.popup-box {

BIN
static/icon/login_name.png


BIN
static/icon/login_pw.png


BIN
static/icon/login_pw2.png


BIN
static/icon/user_address.png


BIN
static/icon/user_bind.png


BIN
static/icon/user_name.png


BIN
static/icon/user_page.png


BIN
static/icon/user_serve.png


BIN
static/icon/user_set.png


BIN
static/img/img02.png