Browse Source

Merge branch 'master' of http://47.92.161.104:10080/zkx/jp-xqjy

zxz 3 years ago
parent
commit
7955bd9869

+ 4 - 4
.env.dev.js

@@ -1,14 +1,14 @@
 const UNI_APP = {  
 const UNI_APP = {  
-	
-    BASE_URL: 'http://192.168.33.162:8086/making-friends-server/' ,
+	BASE_URL: 'https://charging.xiaoxinda.com/making-friends-server/',
+    //BASE_URL: 'http://192.168.33.162:8086/making-friends-server/' ,
 	NODE_ENV :"dev",
 	NODE_ENV :"dev",
-	SIMPLE_RUN:true,// 无视权限控制跳转页面   , 用于样式人员快速访问各种功能 ,快速测试等
+	SIMPLE_RUN:false,// 无视权限控制跳转页面   , 用于样式人员快速访问各种功能 ,快速测试等
 	//openId:"oHjCawsxTJkxixR74OVp7aCKahj8",//测试用openId  
 	//openId:"oHjCawsxTJkxixR74OVp7aCKahj8",//测试用openId  
 	//openId:"oHjCawgwCGen5k1-hAsimdEX5lZo",
 	//openId:"oHjCawgwCGen5k1-hAsimdEX5lZo",
 	//openId:"oHjCawgwCGen5k1-hAsimdEX5lZo",
 	//openId:"oHjCawgwCGen5k1-hAsimdEX5lZo",
 	openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",
 	openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",
 	//小鹏管家appid
 	//小鹏管家appid
-	VUE_APP_WXAPPID:"wx7e70eb62a8459869"
+	VUE_APP_WXAPPID:"wxa8954f417fa7c32f"
 }  
 }  
 
 
 module.exports = UNI_APP;
 module.exports = UNI_APP;

+ 1 - 1
.env.prod.js

@@ -4,7 +4,7 @@ const UNI_APP = {
 	SIMPLE_RUN:false,
 	SIMPLE_RUN:false,
 	openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",//测试用openId
 	openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",//测试用openId
 	//小鹏管家appid
 	//小鹏管家appid
-	VUE_APP_WXAPPID:"wx7e70eb62a8459869"
+	VUE_APP_WXAPPID:"wxa8954f417fa7c32f"
 }  
 }  
 
 
 module.exports = UNI_APP;
 module.exports = UNI_APP;

+ 1 - 1
.env.test.js

@@ -9,7 +9,7 @@ const UNI_APP = {
 	//openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",//测试用openId
 	//openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",//测试用openId
 	//openId:"oHjCawmHqG44pqUW54iBlenaHYB8",
 	//openId:"oHjCawmHqG44pqUW54iBlenaHYB8",
 	//小鹏管家appid
 	//小鹏管家appid
-	VUE_APP_WXAPPID:"wx7e70eb62a8459869",
+	VUE_APP_WXAPPID:"wxa8954f417fa7c32f",
 	//zkx的测试openId
 	//zkx的测试openId
 	openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",
 	openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",
 	//zq的测试openId oHjCawsxTJkxixR74OVp7aCKahj8
 	//zq的测试openId oHjCawsxTJkxixR74OVp7aCKahj8

+ 11 - 0
apis/friend.js

@@ -0,0 +1,11 @@
+import request from '../utils/request.js';
+import Qs from 'qs';
+
+
+export function findFriendsList(data) {
+	return request({
+		method: 'post',
+		data: data,
+		url: '/mobile/friends/friendsList'
+	})
+}

+ 1 - 0
apis/login.js

@@ -5,6 +5,7 @@ import requestSon from '../utils/requestSon.js';
 
 
 export function getBaseDictionary(data ){
 export function getBaseDictionary(data ){
 	var url = '/mobile/member/baseDictionary'; 
 	var url = '/mobile/member/baseDictionary'; 
+	
 	return requestSon({
 	return requestSon({
 		method: 'post', 
 		method: 'post', 
 		header:{'Content-Type': 'application/json',
 		header:{'Content-Type': 'application/json',

+ 3 - 3
components/mpvue-citypicker/mpvueCityPicker.vue

@@ -39,7 +39,7 @@ export default {
     };
     };
   },
   },
   created() {
   created() {
-	console.log('mpvueCityPicker created')
+	//console.log('mpvueCityPicker created')
     this.init()
     this.init()
   },
   },
   props: {
   props: {
@@ -60,7 +60,7 @@ export default {
 	},
 	},
   methods: {
   methods: {
 		init() {
 		init() {
-			console.log('mpvueCityPicker init')
+			//console.log('mpvueCityPicker init')
 			if(this.pickerValueDefault.length == 0)
 			if(this.pickerValueDefault.length == 0)
 				this.pickerValueDefault  = [0,0,0];
 				this.pickerValueDefault  = [0,0,0];
 			this.handPickValueDefault(); // 对 pickerValueDefault 做兼容处理
 			this.handPickValueDefault(); // 对 pickerValueDefault 做兼容处理
@@ -95,7 +95,7 @@ export default {
     handPickValueDefault() {
     handPickValueDefault() {
 	
 	
       //console.log('mpvueCityPicker handPickValueDefault')
       //console.log('mpvueCityPicker handPickValueDefault')
-	  console.log('默认树'+JSON.stringify(this.pickerValueDefault))
+	  //console.log('默认树'+JSON.stringify(this.pickerValueDefault))
 	  //console.log('省'+JSON.stringify(this.pickerValueDefault))
 	  //console.log('省'+JSON.stringify(this.pickerValueDefault))
 	  	  
 	  	  
       if (this.pickerValueDefault !== [0, 0, 0]) {
       if (this.pickerValueDefault !== [0, 0, 0]) {

+ 2 - 2
components/mpvue-datepicker/mpvue-datepicker.vue

@@ -82,7 +82,7 @@ export default {
     };
     };
   },
   },
   created() {
   created() {
-	console.log('mpvueCityPicker created')
+//	console.log('mpvueCityPicker created')
 	 
 	 
     this.init()
     this.init()
   },
   },
@@ -104,7 +104,7 @@ export default {
 	},
 	},
   methods: {
   methods: {
 		init() {
 		init() {
-			console.log('mpvueCityPicker init')
+//			console.log('mpvueCityPicker init')
 			if(this.pickerValueDefault.length == 0)
 			if(this.pickerValueDefault.length == 0)
 				this.pickerValueDefault  = [0,0, 0];
 				this.pickerValueDefault  = [0,0, 0];
 			 
 			 

+ 8 - 0
pages.json

@@ -5,6 +5,14 @@
 	"pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages	
 	"pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages	
 		
 		
 		
 		
+		{
+			"name":"欢迎页",
+			"path": "pages/index/main-zkx",
+			"style": {
+			
+				//"navigationStyle": "custom" // 隐藏系统导航栏
+			}
+		},
 		{
 		{
 			"name":"首页",
 			"name":"首页",
 			"path": "pages/index/index",
 			"path": "pages/index/index",

+ 36 - 42
pages/friend/index.vue

@@ -12,39 +12,13 @@
 			</view>
 			</view>
 			<view class="homeAdd" v-if="current == '1'">
 			<view class="homeAdd" v-if="current == '1'">
 				<u-icon custom-prefix="custom-icon" name="refresh-line"></u-icon>
 				<u-icon custom-prefix="custom-icon" name="refresh-line"></u-icon>
-				<span @click=refreshClick>刷新</span>
+				<span @click="refreshClick">刷新</span>
 			</view>
 			</view>
 		</view>
 		</view>
 
 
 		<view class="friendList">
 		<view class="friendList">
-			<view class="friendList-item">
-				<u-image class="friendList-img" src="/static/img/user1.jpg" height="160" width="160" border-radius="10">
-				</u-image>
-				<view class="friendList-text">
-					<view class="friendList-name">
-						<span>刘子琪</span>
-						<u-icon custom-prefix="custom-icon" name="men-line" color="#1677FF"></u-icon>
-					</view>
-					<view class="friendList-info">
-						24岁 · 160cm · 51kg
-					</view>
-					<view class="friendList-label">
-						<view class="friendList-label-item">
-							<u-icon custom-prefix="custom-icon" name="map-pin-2-fill"></u-icon>
-							<span>沙市</span>
-						</view>
-						<view class="friendList-label-item">
-							<span>本科</span>
-						</view>
-						<view class="friendList-label-item">
-							<span>互联网/IT</span>
-						</view>
-					</view>
-				</view>
-			</view>
-			
 			<view class="friendList-item" v-for="(item ,index) in friendList" :key="item.id" @click="gotoUrl('pages/user/index?id='+item.id)">
 			<view class="friendList-item" v-for="(item ,index) in friendList" :key="item.id" @click="gotoUrl('pages/user/index?id='+item.id)">
-				<u-image class="friendList-img" src="item.faceImage" height="160" width="160" border-radius="10">
+				<u-image class="friendList-img" :src="item.faceImage" height="160" width="160" border-radius="10">
 				</u-image>
 				</u-image>
 				<view class="friendList-text">
 				<view class="friendList-text">
 					<view class="friendList-name">
 					<view class="friendList-name">
@@ -52,23 +26,23 @@
 						<u-icon custom-prefix="custom-icon" name="men-line" color="#1677FF"></u-icon>
 						<u-icon custom-prefix="custom-icon" name="men-line" color="#1677FF"></u-icon>
 					</view>
 					</view>
 					<view class="friendList-info">
 					<view class="friendList-info">
-						{{item.age}}岁 · {{item.height}}cm · {{item.weight}}kg
+						<span>{{item.age}}岁 · {{item.height}}cm</span>&nbsp;<span v-if="item.weight != null">· {{item.weight}}kg</span>
 					</view>
 					</view>
 					<view class="friendList-label">
 					<view class="friendList-label">
 						<view class="friendList-label-item">
 						<view class="friendList-label-item">
 							<u-icon custom-prefix="custom-icon" name="map-pin-2-fill"></u-icon>
 							<u-icon custom-prefix="custom-icon" name="map-pin-2-fill"></u-icon>
-							<span>{{item.workplace}}</span>
+							<span>{{item.orgAreaName}}</span>
 						</view>
 						</view>
 						<view class="friendList-label-item">
 						<view class="friendList-label-item">
 							<span>{{item.educationN}}</span>
 							<span>{{item.educationN}}</span>
 						</view>
 						</view>
 						<view class="friendList-label-item">
 						<view class="friendList-label-item">
-							<span>{{item.industryN}}/IT</span>
+							<span>{{item.industryN}}</span>
 						</view>
 						</view>
 					</view>
 					</view>
 				</view>
 				</view>
 			</view>
 			</view>
-			<u-divider color="#B6BDC3" style="margin-top:20px;" bg-color="#f4f0f0">已经到底了</u-divider>
+			<u-divider v-if="friendList.length == recordsTotal" color="#B6BDC3" style="margin-top:20px;" bg-color="#f4f0f0">已经到底了</u-divider>
 		</view>
 		</view>
 	</view>
 	</view>
 </template>
 </template>
@@ -92,6 +66,8 @@
 				znqk: '', //子女情况
 				znqk: '', //子女情况
 				pageIndex: 1,
 				pageIndex: 1,
 				pageSize: 20,
 				pageSize: 20,
+				recordsTotal: 0,
+				list: [],
 				friendList: [],
 				friendList: [],
 				tabList: [{
 				tabList: [{
 					name: '全部'
 					name: '全部'
@@ -108,6 +84,11 @@
 			}
 			}
 			this.getFriendList();
 			this.getFriendList();
 		},
 		},
+		onReachBottom() {
+			if (this.friendList.length < this.recordsTotal) {	
+				this.myLoadmore();
+			}
+		},
 		methods: {
 		methods: {
 			change(index) {
 			change(index) {
 				this.current = index;
 				this.current = index;
@@ -116,7 +97,7 @@
 			},
 			},
 			refreshClick() {
 			refreshClick() {
 				var data = {
 				var data = {
-					type: 'type',
+					type: 'typedssdf',
 					memberId: 'memberId',
 					memberId: 'memberId',
 					oppositeSex: 'oppositeSex',
 					oppositeSex: 'oppositeSex',
 					ageStart: 'ageStart',
 					ageStart: 'ageStart',
@@ -128,11 +109,17 @@
 					hyqk: 'hyqk',
 					hyqk: 'hyqk',
 					znqk: 'znqk'
 					znqk: 'znqk'
 				};
 				};
-				var list = [];
-				console.log(data.type)
+				let list = [];
+				for(var item in data) {
+					var sgd = {};
+					sgd[item] = data[item]
+					list.push(sgd);
+				}
+				console.log(list)
 				
 				
 				for(var i = 0; i < 3; i++) {
 				for(var i = 0; i < 3; i++) {
-					var num=Math.floor(Math.random()*11+1);
+					var num=Math.floor(Math.random()*10+0);
+					console.log(list[num])
 				}
 				}
 			},
 			},
 			getFriendList() {
 			getFriendList() {
@@ -156,15 +143,22 @@
 					pageSize: this.pageSize
 					pageSize: this.pageSize
 				};
 				};
 				friendApi.findFriendsList(data).then((res) => {
 				friendApi.findFriendsList(data).then((res) => {
-					var jsonData = res.data.data;
-					this.friendList = jsonData;
+					this.friendList = [
+						...this.friendList,
+						...res.data.data
+					];
+					this.recordsTotal = res.data.recordsTotal;
 					uni.hideLoading();
 					uni.hideLoading();
 				}).catch(error => {
 				}).catch(error => {
 					uni.showToast({
 					uni.showToast({
 						title: error
 						title: error
 					})
 					})
 				})
 				})
-			}
+			},
+			myLoadmore() {			
+				this.pageIndex += 1;
+				this.getFriendList()
+			},
 		}
 		}
 	}
 	}
 </script>
 </script>
@@ -174,12 +168,12 @@
 	}
 	}
 </style>
 </style>
 <style lang="scss" scoped>
 <style lang="scss" scoped>
-
-	.home-head {
-		.navbar-tit{
+.navbar-tit{
 			padding-left:15px;
 			padding-left:15px;
 			font-size: 24px;
 			font-size: 24px;
 		}
 		}
+	.home-head {
+		
 		display: flex;
 		display: flex;
 		justify-content: space-between;
 		justify-content: space-between;
 		align-items: center;
 		align-items: center;

+ 84 - 0
pages/index/main-zkx.vue

@@ -0,0 +1,84 @@
+<template>
+		<view>
+				<u-navbar></u-navbar>
+				首页图
+				<view v-if="bottonShow"> 
+					<u-button @click="gotoMain(true)" >加入我们</u-button>
+					<u-button @click="gotoMain(false)">我先逛逛</u-button>
+				</view>
+			
+		</view>
+</template>
+
+<script>
+	import * as loginApi from '@/apis/login.js'
+	
+	export default {
+		data() {
+			return {
+				bottonShow:false
+			}
+		},
+		methods: {
+			gotoMain(k){
+				if(k){
+					uni.navigateTo({
+						url:"/pages/login/index"
+					})
+				}else{
+					uni.switchTab({
+						url: '/pages/index/index'
+					});
+				}
+			},
+			findByOpenId(){
+				var openId=this.carhelp.getOpenId()
+				if(openId==""){
+					console.log("------------------")
+					setTimeout(()=>{
+						this.findByOpenId()
+					},1000)
+					return
+				}
+				uni.request({
+					method:'get',
+					url: process.car.BASE_URL + "/mobile/regUser/findByOpenId",
+					data: {
+						openId:openId,			
+					},
+					header: {
+						'Content-Type': 'application/x-www-form-urlencoded',
+						'X-Requested-With': 'XMLHttpRequest',
+					}
+				}).then((response) => {
+					let [error, res] = response;
+				  
+					if (res.data.code == 200&&res.data.result) {			
+						var token = res ? res.data.data.token : '';					
+						this.carhelp.setPersonInfo(res.data.data.memberInfo );
+						this.carhelp.setToken(token);
+						
+						setTimeout(()=>{
+							uni.switchTab({
+								url: '/pages/index/index'
+							});
+						},1000)
+					
+					} else{
+						this.bottonShow=true
+					}
+				}).catch(error => {
+					
+					this.bottonShow=true
+				})
+			}
+		},
+		onReady() {
+			
+			this.findByOpenId()
+		}
+	}
+</script>
+
+<style>
+</style>

File diff suppressed because it is too large
+ 8 - 6
pages/login/index.vue


+ 27 - 23
pages/login/register.vue

@@ -1,7 +1,8 @@
 <template>
 <template>
 	<view>
 	<view>
-		<u-navbar :background="background" :border-bottom="false"></u-navbar>
 		<view class="jpLogin">
 		<view class="jpLogin">
+			<u-navbar :background="background" :border-bottom="false"></u-navbar>
+			
 			<view class="jpLogin-title">
 			<view class="jpLogin-title">
 				<h2>新用户注册</h2>
 				<h2>新用户注册</h2>
 				<p>请填写您的真实信息</p>
 				<p>请填写您的真实信息</p>
@@ -56,9 +57,10 @@
 				<u-radio-group v-model="value">
 				<u-radio-group v-model="value">
 					<u-radio activeColor="#ff5e5e" @change="radioChange">
 					<u-radio activeColor="#ff5e5e" @change="radioChange">
 						<view class="u-flex">
 						<view class="u-flex">
-							<p>已阅读并同意</p><span @click="getAgreement">《会员服务协议》</span>
+							<p>已阅读并同意</p>
 						</view>
 						</view>
 					</u-radio>
 					</u-radio>
+					<span @click="getAgreement">《会员服务协议》</span>
 				</u-radio-group>
 				</u-radio-group>
 			</view>
 			</view>
 			<u-verification-code :seconds="sendMsgSecond" ref="uCode" @change="codeChange" @end="end" @start="start">
 			<u-verification-code :seconds="sendMsgSecond" ref="uCode" @change="codeChange" @end="end" @start="start">
@@ -84,7 +86,7 @@
 					orgName: '',
 					orgName: '',
 					telephone: '',
 					telephone: '',
 				},
 				},
-				value: '0',
+				value: "0",
 				customStyle: {
 				customStyle: {
 					background: '#FF5E5E'
 					background: '#FF5E5E'
 				},
 				},
@@ -98,7 +100,7 @@
 			}
 			}
 		},
 		},
 		onShow() {
 		onShow() {
-			var item=	this.carhelp.get("selectitem")
+			var item=	this.carhelp.get("searchOrgItem")
 			if(item){
 			if(item){
 				console.log(item)
 				console.log(item)
 				this.form.orgName = item.name;
 				this.form.orgName = item.name;
@@ -118,12 +120,12 @@
 				})
 				})
 			},
 			},
 			getLogin() {
 			getLogin() {
-				uni.redirectTo({
+				uni.navigateBack({
 					url: '/pages/login/index'
 					url: '/pages/login/index'
 				});
 				});
 			},
 			},
-			goAgreement() {
-				uni.redirectTo({
+			getAgreement() {
+				uni.navigateTo({
 					url: '/pages/login/agreement'
 					url: '/pages/login/agreement'
 				});
 				});
 			},
 			},
@@ -192,37 +194,43 @@
 				}
 				}
 				if (!this.form.realName) {
 				if (!this.form.realName) {
 					uni.showToast({
 					uni.showToast({
-						title: "请输入姓名"
+						title: "请输入姓名",
+						icon: "none"
 					})
 					})
 					return
 					return
 				}
 				}
 				if (!this.form.idCard) {
 				if (!this.form.idCard) {
 					uni.showToast({
 					uni.showToast({
-						title: "请输入身份证"
+						title: "请输入身份证",
+						icon: "none"
 					})
 					})
 					return
 					return
 				}
 				}
 				if (!this.form.orgName) {
 				if (!this.form.orgName) {
 					uni.showToast({
 					uni.showToast({
-						title: "请选择工会"
+						title: "请选择工会",
+						icon: "none"
 					})
 					})
 					return
 					return
 				}
 				}
 				if (!this.form.telephone) {
 				if (!this.form.telephone) {
 					uni.showToast({
 					uni.showToast({
-						title: "请输入手机号"
+						title: "请输入手机号",
+						icon: "none"
 					})
 					})
 					return
 					return
 				}
 				}
 				if (!this.form.verifyCode) {
 				if (!this.form.verifyCode) {
 					uni.showToast({
 					uni.showToast({
-						title: "请输入验证码"
+						title: "请输入验证码",
+						icon: "none"
 					})
 					})
 					return
 					return
 				}
 				}
 				if (this.value == '0') {
 				if (this.value == '0') {
 					uni.showToast({
 					uni.showToast({
-						title: "请勾选协议"
+						title: "请勾选协议",
+						icon: "none"
 					})
 					})
 					return
 					return
 				}
 				}
@@ -231,11 +239,7 @@
 					title: "加载中",
 					title: "加载中",
 					mask: true,
 					mask: true,
 				})
 				})
-				var headImg = "";
-				var userInfo = this.carhelp.get("xpgj_wx_user_info")
-				if (userInfo) {
-					headImg = userInfo.headimgurl;
-				}
+			
 
 
 				loginApi.register({
 				loginApi.register({
 					realName: this.form.realName,
 					realName: this.form.realName,
@@ -244,15 +248,15 @@
 					verifyCode: this.form.verifyCode,
 					verifyCode: this.form.verifyCode,
 					telephone: this.form.telephone,
 					telephone: this.form.telephone,
 					openId: this.carhelp.getOpenId(),
 					openId: this.carhelp.getOpenId(),
-					headImg: headImg
+				
 				}).then((response) => {
 				}).then((response) => {
 					var token = response ? response.data.token : '';
 					var token = response ? response.data.token : '';
 					this.carhelp.setToken(token);
 					this.carhelp.setToken(token);
 					this.carhelp.setPersonInfo(response.data.memberInfo);
 					this.carhelp.setPersonInfo(response.data.memberInfo);
-					//this.gotoUrl("pages/user/index")
-					uni.switchTab({
-						url: '/pages/index/index'
-					})
+					this.gotoUrl("pages/login/step1")
+					// uni.switchTab({
+					// 	url: '/pages/index/index'
+					// })
 				}).catch(error => {
 				}).catch(error => {
 					uni.showToast({
 					uni.showToast({
 						title: error,
 						title: error,

+ 3 - 3
pages/login/search.vue

@@ -7,8 +7,8 @@
 		<view class="searchList" v-if="orgResult.length > 0">		
 		<view class="searchList" v-if="orgResult.length > 0">		
 			<list>
 			<list>
 				<cell v-for="(item, index) in orgResult" :key="item.id">
 				<cell v-for="(item, index) in orgResult" :key="item.id">
-					<view class="searchList-item">
-						<text @click="getRegister(item)">{{item.name}}</text>
+					<view class="searchList-item"  @click="getRegister(item)">
+						<text>{{item.name}}</text>
 					</view>
 					</view>
 				</cell>
 				</cell>
 			</list>		
 			</list>		
@@ -42,7 +42,7 @@
 		},
 		},
 		methods: {
 		methods: {
 			getRegister(item) {
 			getRegister(item) {
-				this.carhelp.set("selectitem",item)
+				this.carhelp.set("searchOrgItem",item)
 				uni.navigateBack({
 				uni.navigateBack({
 					url: '/pages/login/register'
 					url: '/pages/login/register'
 				})
 				})

+ 13 - 9
pages/login/step1.vue

@@ -30,7 +30,8 @@
 				</view>
 				</view>
 				<u-form :model="form" ref="uForm">
 				<u-form :model="form" ref="uForm">
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
-						<u-form-item required="true"><u-input v-model="form.birthday" type="select" placeholder="请选择生日" @click="birthdayChange"/>
+						<u-form-item required="true">
+							<u-input v-model="form.birthday" type="select" placeholder="请选择生日" @click="birthdayChange"/>
  						</u-form-item>
  						</u-form-item>
 					</view>
 					</view>
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
@@ -52,7 +53,8 @@
 				<view class="step-btn" @click="goHome">跳过</view>
 				<view class="step-btn" @click="goHome">跳过</view>
 			</view>
 			</view>
 		</view>
 		</view>
- 		<mpvue-date-picker  themeColor="#007AFF" ref="mpvueDatePicker" :pickerValueDefault="agePickerValueDefault" @onConfirm="onDateConfirm"></mpvue-date-picker>
+		<!--:pickerValueDefault="agePickerValueDefault"-->
+ 		<mpvue-date-picker  themeColor="#007AFF" ref="mpvueDatePicker"  @onConfirm="onDateConfirm"></mpvue-date-picker>
 		 
 		 
 	</view>
 	</view>
 </template>
 </template>
@@ -85,7 +87,7 @@
 		}
 		}
 	}
 	}
 	import mpvueDatePicker from "../../components/mpvue-datepicker/mpvue-datepicker.vue"
 	import mpvueDatePicker from "../../components/mpvue-datepicker/mpvue-datepicker.vue"
-	import * as loginApi from '@/apis/login.js'
+	
 	export default {
 	export default {
 		components:{ 
 		components:{ 
 			mpvueDatePicker
 			mpvueDatePicker
@@ -136,13 +138,15 @@
 			}, 2000)
 			}, 2000)
 		},
 		},
 		onLoad(){
 		onLoad(){
+			
 			_self = this;
 			_self = this;
-			let subject = {subject:'zfqkList'}
-			loginApi.getBaseDictionary(subject).then(function(data){
-				console.log('基础字典'+JSON.stringify(data));
-			},function(err){
-				console.log('获取基础字典错误'+JSON.stringify(err))
-			})
+			//#ifdef H5
+			_self.form.height = 150;
+			_self.form.weight = 66;
+			_self.form.birthday = '1990-10-11';
+			_self.form.sex = 'male'
+			//#endif
+			
 			for(let i = 130;i<=220;i++)
 			for(let i = 130;i<=220;i++)
 			{
 			{
 				this.height_ranges.push(i.toString());
 				this.height_ranges.push(i.toString());

+ 160 - 12
pages/login/step2.vue

@@ -9,14 +9,19 @@
 			<view class="jpLogin-main">
 			<view class="jpLogin-main">
 				<u-form :model="form" ref="uForm">
 				<u-form :model="form" ref="uForm">
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
-						<u-form-item required="true"><u-input v-model="form.address" type="select" placeholder="我的出生地" @click="birthdayAddressChange" />
+						<u-form-item required="true">
+							<u-input v-model="form.address" type="select" placeholder="我的出生地" @click="show_birthday_address = true" />
+							<u-select v-model="show_birthday_address" mode="single-column" :list="area_ranges_by_names" @confirm="birthdayAddressConfirm"></u-select>						
 						</u-form-item>
 						</u-form-item>
-					</view>
+					</view> 
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
-						<u-form-item required="true"><u-input v-model="form.registered_residence" type="select" placeholder="我的的户口所在地" @click="registeredResidenceAddressChange"  /></u-form-item>
+						<u-form-item required="true"><u-input v-model="form.registered_residence" type="select" placeholder="我的的户口所在地" @click="show_registered_residence = true"  /></u-form-item>
+						<u-select v-model="show_registered_residence" mode="single-column" :list="area_ranges_by_names" @confirm="registeredResidenceConfirm"></u-select>						
 					</view>
 					</view>
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
-						<u-form-item required="true"><u-input v-model="form.work_address" type="select" placeholder="我的工作所在地" @click="workAddressChange" /></u-form-item>
+						<u-form-item required="true"><u-input v-model="form.work_address" type="select" placeholder="我的工作所在地" @click="show_work_address = true" /></u-form-item>
+						<u-select v-model="show_work_address" mode="single-column" :list="area_ranges_by_names" @confirm="workAddressConfirm"></u-select>
+					
 					</view>
 					</view>
 					
 					
 					<view class="jpLogin-input" style="margin-top: 38px;">
 					<view class="jpLogin-input" style="margin-top: 38px;">
@@ -66,6 +71,10 @@
 						选中我的兴趣爱好(可多选)
 						选中我的兴趣爱好(可多选)
 					</view>
 					</view>
 					<view class="jpLogin-interest">
 					<view class="jpLogin-interest">
+						<view class="interest-item" v-for="(item,index) in interests" :class="item.checked?'active':''" @click="selectInterest(item)">
+							{{item.name}}
+						</view>
+						<!--
 						<view class="interest-item active">摄影</view>
 						<view class="interest-item active">摄影</view>
 						<view class="interest-item">烹饪</view>
 						<view class="interest-item">烹饪</view>
 						<view class="interest-item">健身</view>
 						<view class="interest-item">健身</view>
@@ -79,7 +88,7 @@
 						<view class="interest-item">看电影</view>
 						<view class="interest-item">看电影</view>
 						<view class="interest-item">旅行</view>
 						<view class="interest-item">旅行</view>
 						<view class="interest-item">打游戏</view>
 						<view class="interest-item">打游戏</view>
-						<view class="interest-item">修身养性</view>
+						<view class="interest-item">修身养性</view>-->
 					</view>
 					</view>
 				</u-form>
 				</u-form>
 			</view>
 			</view>
@@ -95,6 +104,7 @@
 </template>
 </template>
 
 
 <script>
 <script>
+	import * as loginApi from '@/apis/login.js'
 	import mpvueCityPicker from "../../components/mpvue-citypicker/mpvueCityPicker.vue";
 	import mpvueCityPicker from "../../components/mpvue-citypicker/mpvueCityPicker.vue";
 	let _self;
 	let _self;
 	export default {
 	export default {
@@ -118,17 +128,19 @@
 					children_status:'',
 					children_status:'',
 					self_assess:'',
 					self_assess:'',
 				},
 				},
-				salary_ranges:['2000元以下','2000-5000元','5000-10000元','10000-20000元','20000-50000元','50000元以上'],
+				area_ranges:[],
+				salary_ranges:[],//['2000元以下','2000-5000元','5000-10000元','10000-20000元','20000-50000元','50000元以上'],
 				education_ranges:['高中中专及以下','大专','本科','双学士','硕士','博士'],
 				education_ranges:['高中中专及以下','大专','本科','双学士','硕士','博士'],
 				profession_ragnes:['在校学生','人力资源/行政/后勤','高级管理','生产/加工/制造','质控/安检','工程机械','技工','财会/审计/统计','金融/证券/投资/保险','房地产/装修/物业','仓储/物流','计算机/互联网/IT','普通劳动力/家政服务','普通服务行业','航空服务业','教育/培训','咨询/顾问','学术/科研','法律','设计/创意','文学/传媒/影视','餐饮/旅游','电子/半导体/仪表仪器','化工','能源/地质勘察','医疗/护理','保健/美容','生物/制药/医疗器械','体育工作者','翻译','公务员/国家干部','私营业主','农/林/牧/渔业','通信技术','自由职业者','其他'],
 				profession_ragnes:['在校学生','人力资源/行政/后勤','高级管理','生产/加工/制造','质控/安检','工程机械','技工','财会/审计/统计','金融/证券/投资/保险','房地产/装修/物业','仓储/物流','计算机/互联网/IT','普通劳动力/家政服务','普通服务行业','航空服务业','教育/培训','咨询/顾问','学术/科研','法律','设计/创意','文学/传媒/影视','餐饮/旅游','电子/半导体/仪表仪器','化工','能源/地质勘察','医疗/护理','保健/美容','生物/制药/医疗器械','体育工作者','翻译','公务员/国家干部','私营业主','农/林/牧/渔业','通信技术','自由职业者','其他'],
 				marriage_statuses:['未婚','离异','丧偶'],
 				marriage_statuses:['未婚','离异','丧偶'],
-				house_statuses:['已购住房','与人合租','独自租房','与父母同住','住亲朋家','住单位房','需要时购房'],
+				house_statuses:[],//['已购住房','与人合租','独自租房','与父母同住','住亲朋家','住单位房','需要时购房'],
 				corportation_types:['世界500强','上市公司','国有企业','私营企业','自有公司'],
 				corportation_types:['世界500强','上市公司','国有企业','私营企业','自有公司'],
-				children_statuses:['没有孩子','有孩子跟着自己','有孩子跟着对方','有孩子但已独立'],
+				children_statuses:[],//['没有孩子','有孩子跟着自己','有孩子跟着对方','有孩子但已独立'],
 				value:'0',
 				value:'0',
 				customStyle: {
 				customStyle: {
 					background: '#FF5E5E'
 					background: '#FF5E5E'
 				}, 
 				}, 
+				area_ranges_by_names:[],
 				salary_ranges_by_names:[],
 				salary_ranges_by_names:[],
 				education_ranges_by_names:[],
 				education_ranges_by_names:[],
 				profession_ranges_by_names:[],
 				profession_ranges_by_names:[],
@@ -136,6 +148,9 @@
 				house_statuses_by_names:[],
 				house_statuses_by_names:[],
 				corportation_types_by_names:[],
 				corportation_types_by_names:[],
 				children_statuses_by_names:[],
 				children_statuses_by_names:[],
+				show_birthday_address:false,
+				show_registered_residence:false,
+				show_work_address:false,
 				show_salary:false,
 				show_salary:false,
 				show_profession:false,
 				show_profession:false,
 				show_education:false,
 				show_education:false,
@@ -145,11 +160,113 @@
 				
 				
 				background:{
 				background:{
 					background: 'none'
 					background: 'none'
-				} 
+				},
+				interests:[{name:'摄影',checked:true},
+				{name:'烹饪',checked:false},
+				{name:'健身',checked:false},
+				{name:'看电影',checked:true},
+				{name:'旅行',checked:false},
+				{name:'打游戏',checked:false},
+				{name:'修身养性',checked:false},
+				]
 			}
 			}
 		},
 		},
 		onLoad(){
 		onLoad(){
 			_self = this;
 			_self = this;
+			let subject = {subject:''}			
+			loginApi.getBaseDictionary(subject).then(function(data){
+				//console.log('基础字典'+JSON.stringify(data));
+				if(data.data)
+				{
+					let zfqkList = data.data.zfqkList;
+					if(zfqkList){
+						//console.log('住房情况'+JSON.stringify(zfqkList));
+						_self.house_statuses = zfqkList;
+						for(let i = 0;i< _self.house_statuses.length;i++)
+						{
+							let house_range = {value:_self.house_statuses[i].value, label: _self.house_statuses[i].name};
+							_self.house_statuses_by_names.push(house_range);
+						}
+					}
+					let yxList = data.data.yxList;
+					if(yxList){
+						//console.log('月薪'+JSON.stringify(yxList));
+						_self.salary_ranges = yxList;
+						for(let i = 0;i< _self.salary_ranges.length;i++)
+						{
+							let salary_range = {value:_self.salary_ranges[i].value, label: _self.salary_ranges[i].name};
+							_self.salary_ranges_by_names.push(salary_range);
+						}
+					}
+					
+					let znqkList = data.data.znqkList;
+					if(znqkList){
+						//console.log('子女情况'+JSON.stringify(znqkList));
+						_self.children_statuses = znqkList;
+						for(let i = 0;i< _self.children_statuses.length;i++)
+						{
+							let children_status = {value:_self.children_statuses[i].value, label: _self.children_statuses[i].name};							
+							_self.children_statuses_by_names.push(children_status);
+						}
+					}
+					
+					
+					let qyList = data.data.qyList;
+					if(qyList){
+						console.log('区域'+JSON.stringify(qyList));
+						_self.area_ranges = qyList;
+						for(let i = 0;i< _self.area_ranges.length;i++)
+						{
+							let house_range = {value:_self.area_ranges[i].value, label: _self.area_ranges[i].name};							
+							_self.area_ranges_by_names.push(house_range);
+						}
+					} 
+					let xlList = data.data.xlList;
+					if(xlList){
+						console.log('学历'+JSON.stringify(xlList));
+						_self.education_ranges = xlList;
+						for(let i = 0;i< _self.education_ranges.length;i++)
+						{
+							let education ={value:_self.education_ranges[i].value, label: _self.education_ranges[i].name};							
+							_self.education_ranges_by_names.push(education);
+						}
+					}
+					let hyList = data.data.hyList;
+					if(hyList){
+						console.log('行业'+JSON.stringify(hyList));
+						_self.profession_ragnes = hyList;
+						for(let i = 0;i< _self.profession_ragnes.length;i++)
+						{
+							let profession = {value:_self.profession_ragnes[i].value, label: _self.profession_ragnes[i].name};							
+							_self.profession_ranges_by_names.push(profession);
+						}
+					} 
+					/*
+					let nlfwList = data.data.nlfwList;
+					if(nlfwList){
+						console.log('年龄范围'+JSON.stringify(nlfwList));
+						
+						for(let i = 0;i< _self.house_statuses.length;i++)
+						{
+							let house_range = {value:i, label: _self.house_statuses[i]};
+							_self.house_statuses_by_names.push(house_range);
+						}
+					}*/
+					let hyqkList = data.data.hyqkList;
+					if(hyqkList){
+						console.log('婚姻'+JSON.stringify(hyqkList));
+						_self.marriage_statuses = hyqkList;
+						for(let i = 0;i< _self.marriage_statuses.length;i++)
+						{
+							let marriage_status = {value:_self.marriage_statuses[i].value, label: _self.marriage_statuses[i].name};							
+							_self.marriage_statuses_by_names.push(marriage_status);
+						}
+					}
+				} 
+			},function(err){
+				console.log('获取基础字典错误'+JSON.stringify(err))
+			})
+			/*
 			for(let i = 0;i< _self.salary_ranges.length;i++)
 			for(let i = 0;i< _self.salary_ranges.length;i++)
 			{
 			{
 				let salary_range = {value:i, label: _self.salary_ranges[i]};
 				let salary_range = {value:i, label: _self.salary_ranges[i]};
@@ -184,13 +301,18 @@
 			{
 			{
 				let children_range = {value:i, label: _self.children_statuses[i]};
 				let children_range = {value:i, label: _self.children_statuses[i]};
 				_self.children_statuses_by_names.push(children_range);
 				_self.children_statuses_by_names.push(children_range);
-			}
+			}*/
 			_self.get_options();
 			_self.get_options();
 		},
 		},
 		onReady(){
 		onReady(){
 			_self.get_options();
 			_self.get_options();
 		},
 		},
 		methods:{
 		methods:{
+			selectInterest(item){
+				if(item){
+					item.checked = !item.checked
+				}
+			},
 			get_options(){
 			get_options(){
 				console.log('get options')
 				console.log('get options')
 				// #ifdef APP-NVUE
 				// #ifdef APP-NVUE
@@ -230,8 +352,34 @@
 					let result = val.label
 					let result = val.label
 					this.form.house_status  += result;
 					this.form.house_status  += result;
 				}) 
 				}) 
+			},			
+			registeredResidenceConfirm(e){
+				console.log('e'+JSON.stringify(e))
+				this.form.registered_residence = '';
+				e.map((val, index) => {
+					// this.result += this.result == '' ? val.label : '-' + val.label;
+					let result = val.label
+					this.form.registered_residence  += result;
+				}) 
+			},
+			workAddressConfirm(e){
+				console.log('e'+JSON.stringify(e))
+				this.form.work_address = '';
+				e.map((val, index) => {
+					// this.result += this.result == '' ? val.label : '-' + val.label;
+					let result = val.label
+					this.form.work_address  += result;
+				}) 
+			},
+			birthdayAddressConfirm(e){
+				console.log('e'+JSON.stringify(e))
+				this.form.address = '';
+				e.map((val, index) => {
+					// this.result += this.result == '' ? val.label : '-' + val.label;
+					let result = val.label
+					this.form.address  += result;
+				}) 
 			},
 			},
-			
 			educationConfirm(e){
 			educationConfirm(e){
 				console.log('e'+JSON.stringify(e))
 				console.log('e'+JSON.stringify(e))
 				this.form.education = '';
 				this.form.education = '';
@@ -264,7 +412,7 @@
 					deta:1
 					deta:1
 				})
 				})
 			},
 			},
-			next(){
+			next(){ 
 				_self.personal_info.step2= _self.form;
 				_self.personal_info.step2= _self.form;
 				uni.navigateTo({
 				uni.navigateTo({
 					url:'./step3',
 					url:'./step3',

+ 118 - 9
pages/login/step3.vue

@@ -10,7 +10,8 @@
 				<u-form :model="form" ref="uForm">
 				<u-form :model="form" ref="uForm">
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
 						<u-form-item required="true">
 						<u-form-item required="true">
-							<u-input v-model="form.age_range" type="select" placeholder="Ta的年龄段范围" @click="ageChange"/>
+							<u-input v-model="form.age_range" type="select" placeholder="Ta的年龄段范围" @click="show_age_ranges = true"/>
+							<u-select v-model="show_age_ranges" mode="single-column" :list="age_ranges_by_names" @confirm="ageRangeConfirm"></u-select>						
 						</u-form-item>
 						</u-form-item>
 					</view>
 					</view>
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
@@ -33,7 +34,8 @@
 					</view>
 					</view>
 					<view class="jpLogin-input">
 					<view class="jpLogin-input">
 						<u-form-item>
 						<u-form-item>
-							<u-input v-model="form.work_address" type="select" placeholder="Ta的工作所在地" @click="workAddressChange"/>
+							<u-input v-model="form.work_address" type="select" placeholder="Ta的工作所在地" @click="show_work_address = true"/>
+							<u-select v-model="show_work_address" mode="single-column" :list="area_ranges_by_names" @confirm="workAddressConfirm"></u-select>						
 						</u-form-item>
 						</u-form-item>
 					</view>
 					</view>
 					<view class="form-tit">
 					<view class="form-tit">
@@ -52,19 +54,20 @@
 				<view class="step-btn" @click="previous">返回上一步</view>
 				<view class="step-btn" @click="previous">返回上一步</view>
 			</view>
 			</view>
 		</view>
 		</view>
-		<mpvue-city-picker themeColor="#007AFF" ref="mpvueWorkCityPicker" :pickerValueDefault="cityPickerValueDefault" @onConfirm="onWorkCityConfirm"></mpvue-city-picker>
-		<mpvue-age-picker themeColor="#007AFF" ref="mpvueAgePicker" :pickerValueDefault="agePickerValueDefault" @onConfirm="onAgeConfirm"></mpvue-age-picker>
+<!--		<mpvue-city-picker themeColor="#007AFF" ref="mpvueWorkCityPicker" :pickerValueDefault="cityPickerValueDefault" @onConfirm="onWorkCityConfirm"></mpvue-city-picker>
+		<mpvue-age-picker themeColor="#007AFF" ref="mpvueAgePicker" :pickerValueDefault="agePickerValueDefault" @onConfirm="onAgeConfirm"></mpvue-age-picker>-->
 	</view>
 	</view>
 </template>
 </template>
 
 
 <script>
 <script>
-	import mpvueCityPicker from "../../components/mpvue-citypicker/mpvueCityPicker.vue";
-	import mpvueAgePicker from "../../components/mpvue-agepicker/mpvueAgePicker.vue"
+	import * as loginApi from '@/apis/login.js'	
+//	import mpvueCityPicker from "../../components/mpvue-citypicker/mpvueCityPicker.vue";
+//	import mpvueAgePicker from "../../components/mpvue-agepicker/mpvueAgePicker.vue"
 	let _self;
 	let _self;
 	export default {
 	export default {
 		components:{
 		components:{
-			mpvueCityPicker,
-			mpvueAgePicker
+//			mpvueCityPicker,
+//			mpvueAgePicker
 		},
 		},
 		data() {
 		data() {
 			return {
 			return {
@@ -83,7 +86,10 @@
 					work_address:'',
 					work_address:'',
 					other:'',
 					other:'',
 				},
 				},
+				area_ranges:[],
+				area_ranges_by_names:[],
 				age_ranges:[],
 				age_ranges:[],
+				age_ranges_by_names:[],
 				height_ranges:[],
 				height_ranges:[],
 				education_ranges_by_names:[],
 				education_ranges_by_names:[],
 				education_ranges:['不限','高中中专及以下','大专','本科','双学士','硕士','博士'],
 				education_ranges:['不限','高中中专及以下','大专','本科','双学士','硕士','博士'],
@@ -100,6 +106,15 @@
 
 
 		},
 		},
 		methods:{
 		methods:{
+			workAddressConfirm(e){
+				console.log('e'+JSON.stringify(e))
+				this.form.work_address = '';
+				e.map((val, index) => {
+					// this.result += this.result == '' ? val.label : '-' + val.label;
+					let result = val.label
+					this.form.work_address  += result;
+				}) 
+			},
 			get_options(){
 			get_options(){
 				console.log('get options')
 				console.log('get options')
 				// #ifdef APP-NVUE
 				// #ifdef APP-NVUE
@@ -141,6 +156,15 @@
 					this.form.salary_range  += result;
 					this.form.salary_range  += result;
 				}) 
 				}) 
 			},
 			},
+			ageRangeConfirm(e){
+				console.log('e'+JSON.stringify(e))
+				this.form.age_range = '';
+				e.map((val, index) => {
+					// this.result += this.result == '' ? val.label : '-' + val.label;
+					let result = val.label
+					this.form.age_range  += result;
+				}) 
+			},
 			educationConfirm(e){
 			educationConfirm(e){
 				console.log('e'+JSON.stringify(e))
 				console.log('e'+JSON.stringify(e))
 				this.form.education = '';
 				this.form.education = '';
@@ -170,6 +194,91 @@
 		},
 		},
 		onLoad(){
 		onLoad(){
 			_self = this;
 			_self = this;
+			let subject = {subject:''}
+			loginApi.getBaseDictionary(subject).then(function(data){
+				//console.log('基础字典'+JSON.stringify(data));
+				if(data.data)
+				{
+					/*
+					let zfqkList = data.data.zfqkList;
+					if(zfqkList){
+						//console.log('住房情况'+JSON.stringify(zfqkList));
+						_self.house_statuses = zfqkList;
+						for(let i = 0;i< _self.house_statuses.length;i++)
+						{
+							let house_range = {value:_self.house_statuses[i].value, label: _self.house_statuses[i].name};
+							_self.house_statuses_by_names.push(house_range);
+						}
+					}*/
+					let yxList = data.data.yxList;
+					if(yxList){
+						//console.log('月薪'+JSON.stringify(yxList));
+						_self.salary_ranges = yxList;
+						for(let i = 0;i< _self.salary_ranges.length;i++)
+						{
+							let salary_range = {value:_self.salary_ranges[i].value, label: _self.salary_ranges[i].name};
+							_self.salary_ranges_by_names.push(salary_range);
+						}
+					}
+					/*
+					let znqkList = data.data.znqkList;
+					if(znqkList){
+						//console.log('子女情况'+JSON.stringify(znqkList));
+						_self.children_statuses = znqkList;
+						for(let i = 0;i< _self.children_statuses.length;i++)
+						{
+							let children_status = {value:_self.children_statuses[i].value, label: _self.children_statuses[i].name};							
+							_self.children_statuses_by_names.push(children_status);
+						}
+					}*/
+					
+					
+					let qyList = data.data.qyList;
+					if(qyList){
+						console.log('区域'+JSON.stringify(qyList));
+						_self.area_ranges = qyList;
+						for(let i = 0;i< _self.area_ranges.length;i++)
+						{
+							let house_range = {value:_self.area_ranges[i].value, label: _self.area_ranges[i].name};							
+							_self.area_ranges_by_names.push(house_range);
+						}
+					} 
+					let xlList = data.data.xlList;
+					if(xlList){
+						console.log('学历'+JSON.stringify(xlList));
+						_self.education_ranges = xlList;
+						for(let i = 0;i< _self.education_ranges.length;i++)
+						{
+							let education ={value:_self.education_ranges[i].value, label: _self.education_ranges[i].name};							
+							_self.education_ranges_by_names.push(education);
+						}
+					}
+					/*
+					let hyList = data.data.hyList;
+					if(hyList){
+						console.log('行业'+JSON.stringify(hyList));
+						_self.profession_ragnes = hyList;
+						for(let i = 0;i< _self.profession_ragnes.length;i++)
+						{
+							let profession = {value:_self.profession_ragnes[i].value, label: _self.profession_ragnes[i].name};							
+							_self.profession_ranges_by_names.push(profession);
+						}
+					}*/
+					let nlfwList = data.data.nlfwList;
+					if(nlfwList){
+						console.log('年龄范围'+JSON.stringify(nlfwList));
+						_self.age_ranges = nlfwList;
+						for(let i = 0;i< _self.age_ranges.length;i++)
+						{
+							let house_range =  {value:_self.age_ranges[i].value, label: _self.age_ranges[i].name};							
+							_self.age_ranges_by_names.push(house_range);
+						}
+					}  
+				} 
+			},function(err){
+				console.log('获取基础字典错误'+JSON.stringify(err))
+			})
+			/*
 			for(let i = 18;i<=99;i++)
 			for(let i = 18;i<=99;i++)
 			{
 			{
 				this.age_ranges.push(i);
 				this.age_ranges.push(i);
@@ -188,7 +297,7 @@
 				let salary_range = {value:i, label:_self.salary_ranges[i]};
 				let salary_range = {value:i, label:_self.salary_ranges[i]};
 				_self.salary_ranges_by_names.push(salary_range);
 				_self.salary_ranges_by_names.push(salary_range);
 			}
 			}
-			console.log('salary ranges'+JSON.stringify(_self.salary_ranges_by_names))
+			console.log('salary ranges'+JSON.stringify(_self.salary_ranges_by_names))*/
 			_self.get_options();
 			_self.get_options();
 		},
 		},
 		onReady(){
 		onReady(){

+ 0 - 75
range-slider_1.0.11/README.md

@@ -1,75 +0,0 @@
-# uni-app-range-slider   
-uni-app 区间选择滑块   
-   
-说明:目前支持平台有APP、微信小程序、H5,其他平台理论上支持。   
-   
-
-## 效果图:   
-![效果图](https://zhangdaren.github.io/uni-app-range-slider/static/preview.png)   
-   
-## range-slider属性   
-   
-| 属性名 | 类型 | 默认值 | 说明 |
-|---|---|---|---|
-| width | Number | 750 | 组件宽度(rpx)|
-| height |Number |100 | 组件高度(rpx) |
-| block-size | Number | 50 | 滑块大小(rpx) |
-| bar-height | Number | 10 | 进度条高度(rpx) |
-| background-color | String | #e9e9e9 | 进度条背景色 |
-| active-color | String | #1aad19 | 已选择的颜色 |
-| min | Number | 0 | 最小值 |
-| max |Number | 100 | 最大值 |
-| values |Array| [0,100] | 当前区间值 |
-| step |Number| 1 | 步长值 |
-| liveMode |Boolean| true | 是否即时刷新数值,默认true |
-| @rangechange | EventHandle | |完成一次拖动后触发的事件,event.detail = {minValue: value1,maxValue:value2, originalValue:value3} |
-   
----
-## tips:   
-修改自:https://github.com/Money888/wechat-rangeslider   
-   
----
-## 更新历史说明:   
-## v1.0.11(20200110)   
-* [修复] step为10或更大时,数值计算出问题的bug   
-* 
-## v1.0.10(20200102)   
-* [优化] 增加拖动时圆点变大的效果   
-* [优化] 将所有upx替换为rpx   
-* [修复] 因为设置step,导致拖动会有偏移的bug   
-* 
-## v1.0.9(20190823)   
-* [修复] 修复使用step时,可能会遇到精度问题,达不到max值   
-* [修复] 修复使用min大于0时,会跳动的bug   
-
-## v1.0.8(20190719)   
-* [新增] liveMode模式,默认为true,即拖动就会刷新数值;设为false时,每次拖动只在touchEnd派发一次change事件   
-* [建议] 示例里之前step参数直接写为数值,在h5上会报错,现修改为data下面的变量   
-   
-### v1.0.7(20190604)   
-* [新增] 支持设置步长,如显示值为0.5, 1, 1.5……这类的值   
-* [新增] 增加一个选择时间区间的示例   
-* 回调函数里默认输出的是格式化后的值,为了取值方便,也并原始值一并给出,方便操作   
-   
-### v1.0.6(20190521)   
-* 适配最新自定义组件编译模式,如遇小程序/app不能正常使用时,请下载最新版   
-   
-### v1.0.5(20190417)   
-* 解决某种微信环境内,touchstart回调的e参数不完整的问题   
-   
-### v1.0.4(20190326)   
-* 解决手动赋值不生效的问题   
-   
-### v1.0.3(20190322)   
-* 解决h5平台上,无法设置初始值的问题   
-   
-### v1.0.2(20190306)   
-* 兼容H5,支持发布到浏览器   
-   
-### v1.0.1   
-* 增加拖动过程中,自动更新滑块值功能。   
-   
-### v1.0.0   
-* 初次提交   
-
-

+ 0 - 391
range-slider_1.0.11/components/range-slider/range-slider.vue

@@ -1,391 +0,0 @@
-<template>
-	<view class="range-slider" :style="'width:' + width + 'rpx;height:' + height + 'rpx'">
-		<view class="range-bar" :style="'width:100%;height:' + barHeight + 'rpx'">
-			<view class="range-bar-bg" :style="'background-color:' + backgroundColor + ''"></view>
-			<view class="range-bar-progress" :style="'margin-left:' + progressBarLeft + 'rpx;width:' + progressBarWidth + 'rpx;background-color:' + activeColor + ''"></view>
-		</view>
-
-		<view
-			class="block"
-			:class="{ active: isMinActive }"
-			:style="'width:' + blockSize + 'rpx;height:' + blockSize + 'rpx;margin-left:' + minBlockLeft + 'rpx;'"
-			@touchstart="_onBlockTouchStart"
-			@touchmove.stop="_onBlockTouchMove"
-			@touchend="_onBlockTouchEnd"
-			:data-left="minBlockLeft"
-			data-tag="minBlock"
-		>
-			<slot name="minBlock"></slot>
-		</view>
-		<view
-			class="block"
-			:class="{ active: isMaxActive }"
-			:style="'width:' + blockSize + 'rpx;height:' + blockSize + 'rpx;margin-left:' + maxBlockLeft + 'rpx;'"
-			@touchstart="_onBlockTouchStart"
-			@touchmove.stop="_onBlockTouchMove"
-			@touchend="_onBlockTouchEnd"
-			:data-left="maxBlockLeft"
-			data-tag="maxBlock"
-		>
-			<slot name="maxBlock"></slot>
-		</view>
-	</view>
-</template>
-<script>
-/**
- * range-slider v1.0.6
- */
-const _windowWidth = uni.getSystemInfoSync().windowWidth;
-
-export default {
-	data() {
-		return {
-			isMinActive: false,
-			isMaxActive: false,
-
-			//#ifdef H5
-			MAX_LENGTH: 294,
-			maxBlockLeft: 300,
-			//#endif
-
-			// #ifndef H5
-			MAX_LENGTH: 700,
-			maxBlockLeft: 350,
-			// #endif
-
-			minBlockLeft: 0,
-			progressBarLeft: 0,
-			progressBarWidth: 350,
-
-			originalMinValue: 0,
-			originalMaxValue: 0
-		};
-	},
-	components: {},
-	props: {
-		//组件宽度
-		width: {
-			type: Number,
-			default: 750
-		},
-		//组件高度
-		height: {
-			type: Number,
-			default: 100
-		},
-		//滑块大小
-		blockSize: {
-			type: Number,
-			default: 50
-		},
-		//区间进度条高度
-		barHeight: {
-			type: Number,
-			default: 5
-		},
-		//背景条颜色
-		backgroundColor: {
-			type: String,
-			default: '#e9e9e9'
-		},
-		//已选择的颜色
-		activeColor: {
-			type: String,
-			default: '#1aad19'
-		},
-		//最小值
-		min: {
-			type: Number,
-			default: 0
-		},
-		//最大值
-		max: {
-			type: Number,
-			default: 100
-		},
-		//设置初始值
-		values: {
-			type: Array,
-			default: function() {
-				return [0, 100];
-			}
-		},
-		//步长值
-		step: {
-			type: Number,
-			default: 1
-		},
-		//live模式,是否动态更新
-		liveMode: {
-			type: Boolean,
-			default: true
-		}
-	},
-	created: function() {
-		//使用自定义组件编译模式时,支持生命周期为:created
-		this._refresh();
-	},
-	onLoad: function(option) {
-		//不使用自定义组件编译模式时,支持生命周期为:onload
-		this._refresh();
-	},
-	onUnload: function() {},
-	watch: {
-		//组件宽度
-		width: function(newVal, oldVal, changedPath) {
-			var that = this;
-			if (newVal != that.width) {
-				this._refresh();
-			}
-		},
-		//滑块大小
-		blockSize: function(newVal, oldVal, changedPath) {
-			var that = this;
-			if (newVal != that.blockSize) {
-				this._refresh();
-			}
-		},
-		//最小值
-		min: function(newVal, oldVal, changedPath) {
-			var that = this;
-			if (newVal != that.min) {
-				that._refresh();
-			}
-		},
-		//最大值
-		max: function(newVal, oldVal, changedPath) {
-			var that = this;
-			if (newVal != that.max) {
-				that._refresh();
-			}
-		},
-		//设置初始值
-		values: function(newVal, oldVal, changedPath) {
-			var that = this;
-			var values = that.values;
-			console.log('refresh', newVal, oldVal);
-			if (that._isValuesValid(newVal) && that._isValuesValid(values)) {
-				if (values[0] != oldVal[0] || values[1] != oldVal[1]) that._refresh();
-			}
-		}
-	},
-	methods: {
-		//补0
-		_pad: function(num, n) {
-			return Array(n - ('' + num).length + 1).join(0) + num;
-		},
-		_pxToRpx: function(px) {
-			return (750 * px) / _windowWidth;
-		},
-		_onBlockTouchStart: function(e) {
-			let tag = e.target.dataset.tag;
-			if (tag == 'minBlock' || tag == 'maxBlock') {
-				this.isMinActive = tag == 'minBlock';
-				this.isMaxActive = tag == 'maxBlock';
-
-				//兼容h5平台及某版本微信
-				if (e.hasOwnProperty('changedTouches')) {
-					this._blockDownX = e.changedTouches[0].pageX;
-				} else {
-					this._blockDownX = e.pageX;
-				}
-
-				//#ifdef H5
-				this._blockLeft = parseFloat(e.target.dataset.left);
-				//#endif
-				// #ifndef H5
-				this._blockLeft = e.target.dataset.left;
-				// #endif
-
-				this._curBlock = e.target.dataset.tag;
-			}
-		},
-		_onBlockTouchMove: function(e) {
-			let tag = e.target.dataset.tag;
-			if (tag == 'minBlock' || tag == 'maxBlock') {
-				var that = this;
-				var values = that._calculateValues(e);
-				that._refreshProgressBar(values[2], values[3]);
-				that._refreshBlock(values[2], values[3]);
-				//拖动时也触发事件
-				var eventDetail = {
-					minValue: this.formatNumber(values[0], this.step),
-					maxValue: this.formatNumber(values[1], this.step),
-					fromUser: true,
-					originalValue: {
-						minValue: values[0],
-						maxValue: values[1]
-					}
-				};
-
-				this.originalMinValue = values[0];
-				this.originalMaxValue = values[1];
-				var eventOption = {};
-				//
-				if (this.liveMode) that.$emit('rangechange', eventDetail, eventOption);
-			}
-		},
-		_onBlockTouchEnd: function(e) {
-			let tag = e.target.dataset.tag;
-			this.isMinActive = false;
-			this.isMaxActive = false;
-			if (tag == 'minBlock' || tag == 'maxBlock') {
-				var that = this;
-				var values = that._calculateValues(e.mp.changedTouches[0]);
-				that._refreshProgressBar(values[2], values[3]);
-				that._refreshBlock(values[2], values[3]);
-				var eventDetail = {
-					minValue: this.formatNumber(values[0], this.step),
-					maxValue: this.formatNumber(values[1], this.step),
-					fromUser: true,
-					originalValue: {
-						minValue: values[0],
-						maxValue: values[1]
-					}
-				};
-				this.originalMinValue = values[0];
-				this.originalMaxValue = values[1];
-				var eventOption = {};
-				that.$emit('rangechange', eventDetail, eventOption);
-			}
-		},
-		_isValuesValid: function(values) {
-			return values != null && values != undefined && values.length == 2;
-		},
-		/**
-		 * 根据手势计算相关数据
-		 */
-		_calculateValues: function(e) {
-			var pageX = e.pageX;
-			//兼容h5平台
-			if (e.hasOwnProperty('changedTouches')) {
-				pageX = e.changedTouches[0].pageX;
-			}
-
-			var that = this;
-			var moveLength = pageX - that._blockDownX;
-			var left = that._blockLeft + that._pxToRpx(moveLength);
-			left = Math.max(0, left);
-			left = Math.min(left, that.MAX_LENGTH);
-			var minBlockLeft = that.minBlockLeft;
-			var maxBlockLeft = that.maxBlockLeft;
-			if (that._curBlock == 'minBlock') {
-				minBlockLeft = left;
-			} else {
-				maxBlockLeft = left;
-			}
-			var range = that.max - that.min;
-			var minLeft = Math.min(minBlockLeft, maxBlockLeft);
-			var maxLeft = Math.max(minBlockLeft, maxBlockLeft);
-			var minValue = (minLeft / that.MAX_LENGTH) * range + that.min;
-			var maxValue = (maxLeft / that.MAX_LENGTH) * range + that.min;
-			return [minValue, maxValue, minLeft, maxLeft];
-		},
-		/**
-		 * 计算滑块坐标
-		 */
-		_calculateBlockLeft: function(minValue, maxValue) {
-			var that = this;
-			var blockSize = that.blockSize;
-			var range = that.max - that.min;
-			var minLeft = ((minValue - that.min) / range) * that.MAX_LENGTH;
-			var maxLeft = ((maxValue - that.min) / range) * that.MAX_LENGTH;
-			return [minLeft, maxLeft];
-		},
-		/**
-		 * 刷新进度条视图
-		 */
-		_refreshProgressBar: function(minBlockLeft, maxBlockLeft) {
-			var that = this;
-			var blockSize = that.blockSize;
-			that.progressBarLeft = minBlockLeft + blockSize / 2;
-			that.progressBarWidth = Math.abs(maxBlockLeft - minBlockLeft);
-		},
-		/**
-		 * 刷新滑块视图
-		 */
-		_refreshBlock: function(minBlockLeft, maxBlockLeft) {
-			var that = this;
-			that.minBlockLeft = minBlockLeft;
-			that.maxBlockLeft = maxBlockLeft;
-		},
-		/**
-		 * 刷新整个视图
-		 */
-		_refresh: function() {
-			var that = this;
-			var MAX_LENGTH = that.width - that.blockSize;
-			that.MAX_LENGTH = MAX_LENGTH;
-			that.maxBlockLeft = MAX_LENGTH;
-			that.progressBarWidth = MAX_LENGTH;
-			var values = that.values;
-			if (this.originalMinValue && this.originalMinValue) {
-				values = [this.originalMinValue || values[0], this.originalMaxValue || values[1]];
-			}
-
-			if (that._isValuesValid(values)) {
-				values[0] = Math.max(that.min, values[0]);
-				values[0] = Math.min(values[0], that.max);
-				values[1] = Math.max(that.min, values[1]);
-				values[1] = Math.min(values[1], that.max);
-				var leftValues = that._calculateBlockLeft(values[0], values[1]);
-				that._refreshProgressBar(leftValues[0], leftValues[1]);
-				that._refreshBlock(leftValues[0], leftValues[1]);
-			}
-		},
-		formatNumber(num, step) {
-			//格式化数字,保留几位小数
-			let stepStr = '' + step;
-			let index = stepStr.indexOf('.');
-			let len = index > -1 ? stepStr.length - index - 1 : 0;
-			let offestNum = parseInt(1 + Array(('' + len).length + 1).join(0)) * 0.1;
-			let tmpNum = num * offestNum;
-			return ((parseInt(tmpNum / step + (step > 1 ? 1 : step) * 0.5) * step) / offestNum).toFixed(len);
-		}
-	}
-};
-</script>
-
-<style>
-.range-slider {
-	position: relative;
-}
-
-.range-bar {
-	position: absolute;
-}
-
-.range-bar {
-	position: absolute;
-	top: 50%;
-	transform: translate(0, -50%);
-	border-radius: 10000rpx;
-}
-
-.range-bar-bg {
-	position: absolute;
-	width: 100%;
-	height: 100%;
-	border-radius: 10000rpx;
-}
-
-.range-bar-progress {
-	position: absolute;
-	width: 100%;
-	height: 100%;
-	background-color: blueviolet;
-}
-
-.block {
-	position: absolute;
-	top: 50%;
-	transform: translate(0, -50%);
-	background: #fff;
-	border-radius: 50%;
-	box-shadow: 0rpx 0rpx 6rpx #ccc;
-}
-
-.block.active {
-	transform: translate(0, -50%) scale(1.5);
-}
-</style>

+ 0 - 219
range-slider_1.0.11/pages/index/index.vue

@@ -1,219 +0,0 @@
-<template>
-	<view class="content">
-		<view class="text-center mrg50T"><text class="title">区间选择滑块/范围选择滑块</text></view>
-
-		<view class="part part1 mrg50T">
-			<view class="title">1. 默认示例:</view>
-			<view class="text-center mrg10T">
-				<text>区间:</text>
-				<text>{{ rangeValues[0] }}</text>
-				<text>~</text>
-				<text>{{ rangeValues[1] }}</text>
-			</view>
-			<view class="rowBox mrg50T">
-				<view class="sliderBox">
-					<RangeSlider
-						:width="slideWidth"
-						:height="slideHeight"
-						:blockSize="slideBlockSize"
-						:min="slideMin"
-						:max="slideMax"
-						:values="rangeValues"
-						:step="step"
-						:liveMode="isLiveMode"
-						@rangechange="onRangeChange"
-					>
-						<view slot="minBlock" class="range-slider-block"></view>
-						<!-- 左边滑块的内容 -->
-						<view slot="maxBlock" class="range-slider-block"></view>
-						<!-- 右边滑块的内容 -->
-					</RangeSlider>
-				</view>
-			</view>
-
-			<button @tap="test" class="testBtn">手动设置为10~60</button>
-		</view>
-
-		<view class="part part2 mrg50T">
-			<view class="title">2. 示例:将原始数据格式化为时间显示</view>
-			<view class="text-center mrg50T">
-				<RangeSlider
-					:width="slideWidth"
-					:height="slideHeight"
-					:blockSize="slideBlockSize"
-					:min="timeMinValue"
-					:max="timeMaxValue"
-					:activeColor="'#E68B28'"
-					:values="rangeValues2"
-					@rangechange="onRangeChange2"
-				>
-					<view slot="minBlock" class="range-slider-block"></view>
-					<!-- 左边滑块的内容 -->
-					<view slot="maxBlock" class="range-slider-block"></view>
-					<!-- 右边滑块的内容 -->
-				</RangeSlider>
-				<text class="plan-unit">{{ serTime }}</text>
-			</view>
-		</view>
-
-		<view class="part part3 mrg50T">
-			<view class="title">3. 示例:页面第三个滑块</view>
-
-			<view class="text-center mrg10T">
-				<text>区间:</text>
-				<text>{{ rangeValues3[0] }}</text>
-				<text>~</text>
-				<text>{{ rangeValues3[1] }}</text>
-			</view>
-
-			<view class="text-center mrg50T">
-				<RangeSlider
-					:width="slideWidth"
-					:height="slideHeight"
-					:blockSize="slideBlockSize"
-					:min="slideMin"
-					:max="slideMax"
-					:values="rangeValues3"
-					:step="step"
-					:liveMode="isLiveMode"
-					@rangechange="onRangeChange3"
-				>
-					<view slot="minBlock" class="range-slider-block"></view>
-					<!-- 左边滑块的内容 -->
-					<view slot="maxBlock" class="range-slider-block"></view>
-					<!-- 右边滑块的内容 -->
-				</RangeSlider>
-			</view>
-		</view>
-
-		<text class="tips">修改自:https://github.com/Money888/wechat-rangeslider</text>
-	</view>
-</template>
-
-<script>
-import RangeSlider from '../../components/range-slider/range-slider.vue';
-
-export default {
-	data() {
-		return {
-			// rangeValues: [2, 5], //当前区间值
-			// slideWidth: 350, //宽度
-			// slideHeight: 80,  //高度
-			// slideBlockSize: 56, //圆形按钮大小
-			// slideMin: 0,  //slider最小值
-			// slideMax: 12,  //slider最大值
-
-			rangeValues: [4, 5.2],
-			slideWidth: 350,
-			slideHeight: 80,
-			slideBlockSize: 30,
-			slideMin: 0,
-			slideMax: 10,
-			isLiveMode: true,
-			step: 0.1,
-			//
-			timeMinValue: 0,
-			timeMaxValue: 10,
-
-			rangeValues2: [1, 6],
-			serTime: '02:24:00-14:24:00',
-
-			rangeValues3: [3, 5]
-		};
-	},
-	components: {
-		RangeSlider
-	},
-	onLoad() {
-		console.log('index onload');
-	},
-	methods: {
-		pad: function(num, n) {
-			return Array(n - ('' + num).length + 1).join(0) + num;
-		},
-		onRangeChange: function(e) {
-			this.rangeValues = [e.minValue, e.maxValue];
-
-			console.log(this.rangeValues);
-			console.log(JSON.stringify(e));
-		},
-		test: function() {
-			this.rangeValues = [4.2, 6.6];
-		},
-		onRangeChange2: function(e) {
-			let startTime = this.formatTimeBySliderValue(e.originalValue.minValue);
-			let endTime = this.formatTimeBySliderValue(e.originalValue.maxValue);
-			this.serTime = startTime + '-' + endTime;
-		},
-		onRangeChange3: function(e) {
-			this.rangeValues3 = [e.minValue, e.maxValue];
-		},
-		formatTimeBySliderValue(value) {
-			//按比例,将滑块上面的数值进行转换为时间形式
-			//转换为分钟数
-			let minutes = (24 * 60 * value) / this.slideMax;
-			//转换为小时数
-			let hours = parseInt(minutes / 60);
-			//剩余分钟数
-			let minutes_min = parseInt(minutes % 60);
-			return '' + this.pad(hours, 2) + ':' + this.pad(minutes_min, 2) + ':' + '00';
-		}
-	}
-};
-</script>
-
-<style lang="scss">
-view {
-	display: flex;
-}
-
-.content {
-	justify-content: center;
-	flex-direction: column;
-}
-
-.sliderBox {
-	justify-content: center;
-	margin-right: 50rpx;
-}
-
-.text-center {
-	justify-content: center;
-}
-
-.rowBox {
-	flex-direction: row;
-	align-items: center;
-	justify-content: center;
-}
-
-.mrg10T {
-	margin-top: 10rpx;
-}
-
-.tips {
-	color: #999;
-	font-size: 24rpx;
-	text-align: center;
-	margin-top: 100rpx;
-}
-
-.testBtn {
-	margin-top: 50rpx;
-}
-
-.part {
-	flex-direction: column;
-	justify-content: center;
-	border-top: 1rpx solid #ccc;
-	padding-top: 50rpx;
-	.title {
-		font-size: 32rpx;
-		padding: 0 30rpx;
-	}
-}
-
-.part2 {
-	margin-top: 100rpx;
-}
-</style>

+ 6 - 13
utils/request.js

@@ -56,21 +56,14 @@ const request = (options) => {
 				carhelp.setToken(token);
 				carhelp.setToken(token);
 				
 				
 				options.token=token
 				options.token=token
-				
-				var isson= requestSon(options)
-				//requestNum(options);
-				resolve(isson);
 				 
 				 
-			} else  if(res.data.code == 415||(res.data.code == 200&&!res.data.result)||res.data.code == 400){
-				
-				var url="var windowlocationhref".split("#")[1]
-				var windowlocationhref="#/pages/login/index?message=请登录&back="+ url+"&phone="+options.data.phone
-				
-			 
-				
-			}else{
-				reject(res.data.message)
+			} else{
+				console.log("游客访问")
 			}
 			}
+			var isson= requestSon(options)
+			//requestNum(options);
+			resolve(isson);
+			
 		}).catch(error => {
 		}).catch(error => {
 			
 			
 			let [err, res] = error;
 			let [err, res] = error;

Some files were not shown because too many files changed in this diff