gjy 2 lat temu
rodzic
commit
d93798a0db

+ 174 - 0
common/TabBarView.js

@@ -0,0 +1,174 @@
+
+/**
+ * App端 手绘 tabbar 可以实现凸起按钮
+ * version:1.0.2
+ */
+export default class TabBarView{
+	constructor(){
+		//tabbar 配置
+		this.configs = {
+			background:'#fff', //背景
+			height: 50 , //高度
+			fontSize: 15, //字体大小
+			iconWidth: 24, //图片大小
+			borderStyle:'#F5F5F5', //bordercolor
+			color:'#000000', //字体颜色
+			selectedColor:'#038AFF',
+			midIconWidth:60 //中间凸起按钮大小
+		}
+		
+		//白名单 不需要配置
+		this.whiteList = [];
+		
+		// //tabbar 列表 midButton:true 可实现凸起 想凸几个凸几个
+		this.tabBarList =[{
+				icon: "./static/images/common/huoyuan@2x(1).png",
+				selectIcon: "./static/images/common/huoyuan@2x.png",
+				name: "货源",
+				path: "/pages/goodSource/index"
+				
+			},
+			{
+				"path": "/pages/riders/index",
+				"icon": "static/images/common/zhaoche.png",
+				"selectIcon": "static/images/common/zhaoche_check.png",
+				"name": "车友"
+			},
+			{
+				"path": "/pages/order/index",
+				"icon": "/static/images/common/dingdan@2x(1).png",
+				"selectIcon": "/static/images/common/dingdan@2x.png",
+				"name": "订单"
+			},
+			{
+				"path": "/pages/news/index",
+				"icon": "/static/images/common/mesicon@2x.png",
+				"selectIcon": "/static/images/common/xiaoxi@2x.png",
+				"name": "消息"
+			},
+			{
+				"path": "/pages/mine/index",
+				"icon": "/static/images/common/iconmy@2x.png",
+				"selectIcon": "/static/images/common/my@2x.png",
+				"name": "我的"
+			}
+		]
+		
+		//tabbarItem宽度
+		this.tabbarItemWidth = Math.floor( 100 / this.tabBarList.length );
+	}
+	
+	//开局初始化tabbar
+	init(){
+		this.whiteList = [];
+		//创建tabbar盒子
+		const tabBarBox = new plus.nativeObj.View('tabBarBox', {
+			position:'dock',
+			dock:'bottom',
+			bottom:'0px',
+			left:'0px',
+			width:'100%',
+			height: this.configs.height + 'px',
+			backgroundColor:this.configs.background
+		},[
+			{
+				tag:'rect',
+				id:'taBarBoxRect',
+				rectStyles:{
+					color:this.configs.borderStyle
+				},
+				position:{
+					top:'0px',
+					left:'0px',
+					width:"100%",
+					height:'1px'
+				}
+			}
+		]);
+		
+		//显示tabbar 盒子
+		tabBarBox.show();
+		
+		//创建tabbar item
+		for(let i = 0; i < this.tabBarList.length; i++){
+			const tabItem = this.tabBarList[i];
+			this.whiteList.push(tabItem.path);
+			const tabbarItem = new plus.nativeObj.View('tabBarItem' + i,this.setTabBarStyle(tabItem.midButton,i),this.drawTabBar(false,tabItem));
+			//添加tabbarItem 事件 根据自己需求 默认调转页面
+			tabbarItem.addEventListener("click", function(e) {
+				uni.switchTab({
+					url:tabItem.path
+				})
+			}, false);
+		}
+	}
+	
+	//监听tabbar
+	$watch(){
+		setTimeout(()=>{
+			const pages = getCurrentPages();
+			const page = pages[pages.length - 1];
+			const path = '/'+ page.route;
+			const tabBarBox = plus.nativeObj.View.getViewById('tabBarBox');
+			for(let i = 0; i < this.tabBarList.length; i++){
+				const tabItem = this.tabBarList[i];
+				const tabBarItem = plus.nativeObj.View.getViewById('tabBarItem' + i);
+				tabBarItem.draw(this.drawTabBar(tabItem.path === path,tabItem))
+				if(this.whiteList.indexOf(path) != -1){
+					tabBarItem.show();
+				}else{
+					tabBarItem.hide();
+				}
+			}
+			if(this.whiteList.indexOf(path) != -1){
+				tabBarBox.show();
+			}else{
+				tabBarBox.hide();
+			}
+		},0)
+	}
+	
+	//设置 tabbar 风格
+	setTabBarStyle(midButton,i){
+		return {
+			position:'dock',
+			bottom:'0px',
+			left:this.tabbarItemWidth * i + '%',
+			dock:'bottom',
+			width: this.tabbarItemWidth + '%' ,
+			height: midButton ? this.configs.height + (this.configs.midIconWidth / 2) + 'px' : this.configs.height - 1 + 'px'
+		}
+	}
+	
+	//画 tabbar 样式
+	drawTabBar(select,tabItem){
+		return	[
+					{
+						tag:'img',
+						id:'tabItemIcon',
+						src:select ? tabItem.selectIcon : tabItem.icon,
+						position:{
+							top:tabItem.midButton ? '0px' : '4px',
+							left:'auto',
+							width:tabItem.midButton ? this.configs.midIconWidth : this.configs.iconWidth,
+							height:tabItem.midButton ? this.configs.midIconWidth : this.configs.iconWidth,
+						}
+					},
+					{
+						tag:'font',
+						id:'tabItemFont',
+						text: tabItem.name,
+						textStyles:{
+							size:'10px',
+							color:select ? this.configs.selectedColor : this.configs.color,
+						},
+						position:{
+							bottom:'5px',
+							left:'auto',
+							width:'100%',
+							height:'12px' 
+						}
+					}
+				]
+	}
+}

+ 19 - 0
common/helper.js

@@ -15,6 +15,23 @@ const imgTypeList = [{
 		name: '拍照',
 	}
 ]
+// 当前日期是否超过今天(校验有效期)
+const periodOfValidity=function(year1,month1,day1){
+	let nowDate = new Date();
+	let year = nowDate.getFullYear()
+	let month = nowDate.getMonth() + 1
+	let day = nowDate.getDate()
+	if(year1<year){
+		return false
+	}
+	if(year1==year&&month1<month){
+		return false
+	}
+	if(year1==year&&month1==month&&day1<=day){
+		return false
+	}
+	return true
+}
 const makeValidityPeriod = function(type,yearnum) {
 	console.log(yearnum)
 	//获取当前年
@@ -173,6 +190,7 @@ const filterArea = (q) => {
 	}
 	return q
 }
+
 // 根据当前时间获取本周一到本周日日期
 function getDates() {
 	// var new_Date = new Date(t2)
@@ -436,6 +454,7 @@ export default {
 	imgType,
 	imgTypeList,
 	makeValidityPeriod,
+	periodOfValidity,
 	getProvinceAbbreviation,
 	filterUrban,
 	filterArea,

+ 0 - 1
components/itmister-address-picker/city_other.json

@@ -5,7 +5,6 @@
 { "name": "天津", "city":[{"name":"天津", "area":["全市","和平区","河东区","河西区","南开区","河北区","红桥区","塘沽区","汉沽区","大港区","东丽区","西青区","津南区","北辰区","武清区","宝坻区","宁河县","静海县","蓟  县"]}]},
 
 { "name": "河北", "city":[
-         {"name":"全省", "area":[]},
          {"name":"石家庄", "area":["全市","长安区","桥东区","桥西区","新华区","郊  区","井陉矿区","井陉县","正定县","栾城县","行唐县","灵寿县","高邑县","深泽县","赞皇县","无极县","平山县","元氏县","赵  县","辛集市","藁","晋州市","新乐市","鹿泉市"]},
 
          {"name":"唐山", "area":["全市","路南区","路北区","古冶区","开平区","新  区","丰润县","滦  县","滦南县","乐亭县","迁西县","玉田县","唐海县","遵化市","丰南市","迁安市"]},

+ 59 - 2
components/itmister-date-picker/itmister-date-picker.nvue

@@ -162,12 +162,59 @@
 				year,
 				month,
 				day,
-				value: year=='长期'||year=='随时'?[0,0,0]:[Number(year - this.startYear+1), month , day], // 默认选中当天
+				value: this.dateStatus==0?[Number(year - this.startYear), month-1 , day]:year=='长期'||year=='随时'?[0,0,0]:[Number(year - this.startYear+1), month , day], // 默认选中当天
 				visible: true,
 				indicatorStyle: `height: ${Math.round(uni.getSystemInfoSync().screenWidth/(750/100))}px;`
 			}
 		},
 		methods: {
+			setYearList(){
+				const date = new Date();
+				let years = [],months = [];
+				if(this.dateStatus==1){
+					years = ['长期'];
+					months = [''];
+				}
+				if(this.dateStatus==2){
+					years = ['随时'];
+					months = [''];
+				}
+				const currectyear = date.getFullYear()
+				const currectmonth = date.getMonth() + 1
+				const currectday = date.getDate()
+				// console.log(this.checkYear)
+				// const month = date.getMonth() + 1
+				// const day = date.getDate();
+				
+				// 传截止日期设置起始年份和终止年份
+				if(JSON.stringify(this.endDate)!='{}'){
+					if(this.endDate.year&&this.endDate.year<currectyear){
+						this.showtoast('截止日期年份必须大于等于当前年份')
+						return
+					}
+					if(this.endDate.year&&this.endDate.year==currectyear&&this.endDate.month&&this.endDate.month<currectmonth){
+						this.showtoast('截止日期月份必须大于等于当前月份')
+						return
+					}
+					if(this.endDate.year&&this.endDate.year==currectyear&&this.endDate.month&&this.endDate.month==currectmonth&&this.endDate.day&&this.endDate.day<currectday){
+						this.showtoast('截止日期必须大于等于今天')
+						return
+					}
+					var obj=this.createExpirationDate()
+					// console.log(obj)
+					years=obj.years
+				}
+				
+				// console.log(year,month,day)
+				// 未传截止日期设置起始年份和终止年份
+				if(JSON.stringify(this.endDate)=='{}'){
+					for (let i = this.startYear; i <= currectyear + this.futureYear; i++) {
+						years.push(i);
+					}
+				}
+				// console.log(years,2222222)
+				this.years=years
+			},
 			createExpirationDate(){
 				let years = [],months = [];
 				if(this.dateStatus==1){
@@ -222,6 +269,7 @@
 			},
 			setValue(){
 				var val=[]
+				console.log(this.days)
 				for (let i = 0; i < this.years.length; i++) {
 					if(this.year==this.years[i]){
 						val[0]=i
@@ -342,6 +390,15 @@
 					})
 				}
 			},
+			'dateStatus':{
+				handler(val){
+					this.dateStatus=val
+					this.setYearList()
+					// console.log(this.years,3333333)
+				},
+				deep: true,
+				immediate: true
+			},
 			"endDate":{
 				handler(val){
 					this.endDate=val
@@ -480,7 +537,7 @@
 						this.days = [''];
 					}else{
 						const months = [''];
-						console.log(this.endDate)
+						// console.log(this.endDate)
 						if(this.endDate.year&&val===this.endDate.year&&this.endDate.month){
 							for (let i = 1; i <= this.endDate.month; i++) {
 								months.push(i);

+ 2 - 2
config/index.js

@@ -1,8 +1,8 @@
 const dev = {
 	// baseUrlNew: 'https://api.changyuntong56.com',
-	// baseUrlNew: 'https://apitest.changyuntong56.com',
+	baseUrlNew: 'https://apitest.changyuntong56.com',
 	// baseUrlNew: 'https://apitest.eliangeyun.com',
-	baseUrlNew: 'http://192.168.110.9:8099',
+	// baseUrlNew: 'http://192.168.110.9:8099',
 	// baseUrlNew: 'http://192.168.110.82:8999',
 	// baseUrlNew: 'http://192.168.1.119:8999',
 	h5Appid: 'wxb66b599f7f61b46f',

+ 21 - 7
pages/goodSource/cargoOwnerSee.vue

@@ -87,10 +87,10 @@
 								<view class="evaluate_name">{{item.driverName}}</view>
 								<view class="evaluate_date m-top10">{{objectInfo.createDate.split(' ')[0]}}</view>
 								<view class="flex m-top10">
-									<view class="branch_css ">{{item.count}}</view>
+									<view class="branch_css ">{{item.ownerScoreObtained}}</view>
 									<view class="">
-										<start count="5" v-model="item.count" size="35" activeColor="#ffaa00" :size="18"
-											:allowHalf='true' :readonly='true'>
+										<start count="5" v-model="item.ownerScoreObtained" size="35" activeColor="#ffaa00" :size="18"
+											:allowHalf='true' :disabled='true'>
 										</start>
 									</view>
 								</view>
@@ -98,7 +98,7 @@
 									{{item.driverContent}}
 								</view>
 								<view style='flex-wrap: wrap;' class='flex'>
-									<u--image style='margin:7rpx;border:1px solid #ccc;' v-for="(item,index) in item.imgList" :src="item" width='170rpx'
+									<u--image style='margin:7rpx;border:1px solid #ccc;' v-for="(item1,index) in item.imgList" @click='ylImg(item.imgList)' :src="item1" width='170rpx'
 										height='170rpx'>
 									</u--image>
 								</view>
@@ -165,6 +165,20 @@
 			this.show = true
 		},
 		methods: {
+			ylImg(src) {
+				uni.previewImage({
+					urls: src,
+					longPressActions: {
+						itemList: ['发送给朋友', '保存图片', '收藏'],
+						success: function(data) {
+							console.log('选中了第' + (data.tapIndex + 1) + '个按钮,第' + (data.index + 1) + '张图片');
+						},
+						fail: function(err) {
+							console.log(err.errMsg);
+						}
+					}
+				});
+			},
 			selectTypeClose() {
 				this.show = false
 			},
@@ -220,9 +234,9 @@
 								that.list[i].imgList = that.list[i].driverUrl.split(',')
 							}
 
-							that.list[i].count = (Number(that.list[i].ownerCredit) + Number(that.list[i]
-								.tranEfficiency) + Number(that.list[i].freightPayment) + Number(that.list[i]
-								.serviceQuality) + Number(that.list[i].comprehensiveSatisfaction)) / 15 * 5
+							// that.list[i].count = (Number(that.list[i].ownerCredit) + Number(that.list[i]
+							// 	.tranEfficiency) + Number(that.list[i].freightPayment) + Number(that.list[i]
+							// 	.serviceQuality) + Number(that.list[i].comprehensiveSatisfaction)) / 15 * 5
 						}
 						that.mescroll.endBySize(res.data.records.length, res.data.total);
 						uni.hideLoading()

+ 20 - 56
pages/mine/driverCertification.vue

@@ -238,13 +238,14 @@
 						</u--input>
 						<view @click="manualInput(index)" class="type">选择支行</view>
 					</view>
-					<view class="flex" v-if="!isShowManualInput">
-						<u--input class="select-bankzh" placeholder="选择开户支行" inputAlign='right' border="none"
+					<view class="flex align-center" v-if="!isShowManualInput">
+						<!-- <u--input class="select-bankzh" placeholder="选择开户支行" inputAlign='right' border="none"
 							v-model="item.bankDepositBranch">
-						</u--input>
-						<!-- <view class="select-bankzh point" @click="selectZhbank">
+						</u--input> -->
+						<view 
+						 :style="{'color':item.bankDepositBranch?'#000':'#C6CBD5'}" style='font-size:15px;text-align:right;' class="select-bankzh point" @click="selectZhbank">
 							{{item.bankDepositBranch?item.bankDepositBranch:'选择开户支行'}}
-						</view> -->
+						</view>
 						<view @click="manualInput" class="type">手动输入</view>
 					</view>
 				</view>
@@ -408,7 +409,6 @@
 			this.get_camera_permission()
 			console.log(this.userInfo)
 			//获取截止日期List数据
-			this.validityPeriod = this.$helper.makeValidityPeriod(0)
 			this.dataDetails.driverPhone = this.userInfo.phone
 			this.dataDetails.commonId = this.userInfo.id
 			//获取认证状态
@@ -602,7 +602,7 @@
 				this.$request.baseRequest('', '/driverInfo/firstAuthentication', {
 						driverPhone: this.userInfo.phone,
 					}).then(res => {
-						if (res.data) {
+						if (res.data.passOnce==1) {
 							this.isFirstAuthentication = false
 						} else {
 							this.isFirstAuthentication = true
@@ -635,6 +635,7 @@
 				this.isShowBank = false
 			},
 			manualInput(val) {
+				console.log(1111111111111)
 				this.index = val
 
 				if (this.isShowManualInput) {
@@ -680,55 +681,12 @@
 				// }
 			},
 			// 回调参数为包含columnIndex、value、values
-			confirmValidityPeriod(e) {
-				console.log('confirm', e)
-				if (e.value[0] == '长期') {
-					if (e.value[1] || e.value[2]) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "选择长期不允许选择月日!",
-						})
-						return
-					}
-					this.dataDetails.cardValidityDate = e.value[0]
-				} else {
-					if (!e.value[1] || !e.value[2]) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "日期格式错误,请重新选择!",
-						})
-						return
-					}
-					var date = new Date()
-					if (e.value[0] < date.getFullYear()) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "身份证已过期!",
-						})
-						return
-					}
-					if (e.value[0] == date.getFullYear() && Number(e.value[1]) < (date.getMonth() + 1)) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "身份证已过期!",
-						})
-						return
-					}
-					if (e.value[0] == date.getFullYear() && Number(e.value[1]) == (date.getMonth() + 1) && Number(e.value[
-							2]) <= (date.getDate())) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "身份证已过期!",
-						})
-						return
-					}
-					this.dataDetails.cardValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-				}
-
-				this.isShowcardValidity = false
+			confirmValidityPeriod(date) {
+					this.dataDetails.cardValidityDate = date.date
 			},
 			selectValidityPeriod() {
-				this.isShowcardValidity = true
+				this.$refs.dateEl.show()
+				// this.isShowcardValidity = true
 			},
 			//设置图片
 			setImage(e) {
@@ -760,6 +718,7 @@
 				// this.isShowimgType = true
 				// this.imgTypeSelect()
 				this.index = index
+				this.dataDetails.hyDriverPayeeInfoList[index].bankDepositBranch=''
 				this.imgTypeSelect()
 			},
 			// 上传图片
@@ -994,7 +953,12 @@
 							res => {
 								if (res.data.distinguishNum != "01") { //不等于01 证明银行卡验证不通过
 									// this.payCheck = false //验证开关
-									uni.$u.toast(res.data.distinguish);
+									// uni.$u.toast(res.data.distinguish);
+									this.$refs.uToast.show({
+										type: 'error',
+										message: res.data.distinguish,
+										duration:4000
+									})
 								} else {
 									uni.$u.route('/pages/mine/driverCertificationNext', {
 										data: JSON.stringify(this.dataDetails),
@@ -1375,7 +1339,7 @@
 
 		.select-bankzh {
 			width: 230rpx;
-			height: 48rpx;
+			// height: 48rpx;
 		}
 	}
 

+ 35 - 244
pages/mine/driverCertificationNext.vue

@@ -60,89 +60,6 @@
 					<u--input placeholder="请输入驾驶证发证机关" inputAlign='right' border="none" v-model="dataDetails.lssuingAuthority" >
 					</u--input>
 				</view>
-<!--
-				<view class="title">上传行驶证主页</view>
-				<view @click="uploadImg(3)" class="picture picture3" v-if="!dataDetails.drivingLicenseHomePage">
-					<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-					<view class="text">上传行驶证主页</view>
-				</view>
-				<view v-if="dataDetails.drivingLicenseHomePage" @click.stop="uploadImg(1)"
-					class="preview-card-img picture">
-					<view @click.stop="delCard(1)">
-						<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-						</image>
-					</view>
-					<image class="" :src="dataDetails.drivingLicenseHomePage" mode="aspectFit"></image>
-				</view>
-				<view class="title">上传行驶证副页</view>
-				<view @click="uploadImg(4)" class="picture picture4" v-if="!dataDetails.drivingLicenseBackPage">
-					<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-					<view class="text">上传行驶证副页</view>
-				</view>
-				<view v-if="dataDetails.drivingLicenseBackPage" @click.stop="uploadImg(1)"
-					class="preview-card-img picture">
-					<view @click.stop="delCard(1)">
-						<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-						</image>
-					</view>
-					<image class="" :src="dataDetails.drivingLicenseBackPage" mode="aspectFit"></image>
-				</view>
-				<view class="flex row flex-space-between">
-					<view class="left-text">行驶证档案编号</view>
-					<u--input placeholder="输入行驶证档案编号" inputAlign='right' border="none" v-model="dataDetails.drivingLicenseNumber">
-					</u--input>
-				</view>
-
-				<view class="flex row flex-space-between">
-					<view class="left-text">行驶证有效期</view>
-					<view class="" @click="selectValidityPeriod(1)">
-						{{dataDetails.drivingLicenseValidityDate?dataDetails.drivingLicenseValidityDate:'选择有效截止日期>'}}
-					</view>
-				</view>
-
-
-				<view class="" v-if="isGCar">
-					<view class="title">挂车行驶证主页</view>
-					<view @click="uploadImg(5)" class="picture picture5" v-if="!dataDetails.trailerLicenseHomePage">
-						<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-						<view class="text">上传挂车行驶证主页</view>
-					</view>
-					<view v-if="dataDetails.trailerLicenseHomePage" @click.stop="uploadImg(1)"
-						class="preview-card-img picture">
-						<view @click.stop="delCard(1)">
-							<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-							</image>
-						</view>
-						<image class="" :src="dataDetails.trailerLicenseHomePage" mode="aspectFit"></image>
-					</view>
-				</view>
-				<view v-if="isGCar">
-					<view class="title">挂车行驶证副页</view>
-					<view @click="uploadImg(6)" class="picture picture6" v-if="!dataDetails.trailerLicenseBackPage">
-						<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-						<view class="text">上传挂车行驶证副页</view>
-					</view>
-					<view v-if="dataDetails.trailerLicenseBackPage" @click.stop="uploadImg(1)"
-						class="preview-card-img picture">
-						<view @click.stop="delCard(1)">
-							<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-							</image>
-						</view>
-						<image class="" :src="dataDetails.trailerLicenseBackPage" mode="aspectFit"></image>
-					</view>
-				</view>
-				<view class="flex row">
-					<view class="left-text">挂车行驶证档案编号</view>
-					<u--input placeholder="输入挂车行驶证档案编号" inputAlign='right' border="none" v-model="dataDetails.trailerLicenseNumber">
-					</u--input>
-				</view>
-
-				<view class="flex row flex-space-between" v-if="isGCar">
-					<view class="left-text">挂车行驶证有效期</view>
-					<view class="" @click="selectValidityPeriod(2)">
-						{{dataDetails.trailerLicenseValidityDate?dataDetails.trailerLicenseValidityDate:'选择有效截止日期>'}}
-					</view>
-				</view>-->
 
 				<view class="title">从业资格证</view>
 				<view @click="uploadImg(7)" class="picture picture7" v-if="!dataDetails.qualificationCertificate">
@@ -169,62 +86,7 @@
 					<u--input maxlength='30' placeholder="请输入从业资格证号" inputAlign='right' border="none" v-model="dataDetails.qualificationCertificateNumber">
 					</u--input>
 				</view>
-<!--
-				<view class="title">道路运输证</view>
-				<view @click="uploadImg(8)" class="picture picture8" v-if="!dataDetails.operationCertificate">
-					<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-					<view class="text">上传道路运输证</view>
-				</view>
-				<view v-if="dataDetails.operationCertificate" @click.stop="uploadImg(1)"
-					class="preview-card-img picture">
-					<view @click.stop="delCard(1)">
-						<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-						</image>
-					</view>
-					<image class="" :src="dataDetails.operationCertificate" mode="aspectFit"></image>
-				</view>
-				<view class="flex row">
-					<view class="left-text">道路运输证号</view>
-					<u--input placeholder="输入道路运输证号" inputAlign='right' border="none" v-model="dataDetails.operationCertificateNumber">
-					</u--input>
-				</view>
-				<view class="flex row flex-space-between">
-					<view class="left-text">道路运输证有效期</view>
-					<view class="" @click="selectValidityPeriod(4)">
-						{{dataDetails.operationCertificateValidityDate?dataDetails.operationCertificateValidityDate:'选择有效期>'}}
-					</view>
-				</view>
 
-				<view v-if="isGCar">
-					<view class="title">挂车道路运输证</view>
-					<view @click="uploadImg(9)" class="picture picture9"
-						v-if="!dataDetails.trailerOperationCertificate">
-						<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-						<view class="text">上传挂车道路运输证</view>
-					</view>
-					<view v-if="dataDetails.trailerOperationCertificate" @click.stop="uploadImg(1)"
-						class="preview-card-img picture">
-						<view @click.stop="delCard(1)">
-							<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-							</image>
-						</view>
-						<image class="" :src="dataDetails.trailerOperationCertificate" mode="aspectFit"></image>
-					</view>
-				</view>
-				<view class="flex row">
-					<view class="left-text">挂车道路运输证号</view>
-					<u--input placeholder="输入挂车道路运输证号" inputAlign='right' border="none" v-model="dataDetails.trailerOperationCertificateNumber">
-					</u--input>
-				</view>
-
-				<view class="flex row flex-space-between" v-if="isGCar">
-					<view class="left-text">挂车道路运输证有效期</view>
-					<view class="" @click="selectValidityPeriod(5)">
-						{{dataDetails.trailerOperationCertificateValidityDate?dataDetails.trailerOperationCertificateValidityDate:'选择有效期>'}}
-					</view>
-				</view>
-			
-				-->
 				<view class="flex row noborder">
 					<view class="left-text">通讯地址</view>
 					<u--textarea v-model="dataDetails.postalAddress" border="none"  placeholder="输入通讯地址" autoHeight  maxlength="30"></u--textarea>
@@ -249,9 +111,16 @@
 				@select="imgTypeSelect" :closeOnClickOverlay="true" :closeOnClickAction="true"
 				@close="isShowimgType=false">
 			</u-action-sheet>
-			<u-picker :show="isShowValidity" ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
+			<!-- <u-picker :show="isShowValidity" ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
 				:closeOnClickOverlay='true' @close='isShowValidity=false' @cancel='isShowValidity=false'>
-			</u-picker>
+			</u-picker> -->
+			<itmister-date-picker :dateStatus="0"
+			ref="datestartEl" :startYear="1980"  :futureYear="10" 
+			@dateConfirm="confirmValidityPeriod"></itmister-date-picker>
+			<itmister-date-picker :overdueContent="overdueContent" :dateStatus="status" 
+			:periodOfValidity="true" 
+			ref="dateEl" :startYear="1980"  :futureYear="10" 
+			@dateConfirm="confirmValidityPeriod"></itmister-date-picker>
 			<u-picker :show="isShowDrive" ref="uPicker" :columns="driveList" @confirm="confirmDriveType"
 				:closeOnClickOverlay='true' @close='isShowDrive=false' @cancel='isShowDrive=false'>
 			</u-picker>
@@ -271,11 +140,12 @@
 				consentStatus: false,
 				isGCar: true,
 				ValidityPeriodType: '',
-				validityPeriod: [],
 				isShowValidity: false,
 				isShowDrive:false,
 				driveList:[["A2","B2"]],
+				overdueContent:'',
 				uploadType: '',
+				status:1,
 				isShowimgType: false,
 				dataDetails: {},
 				radiolist: [{
@@ -299,9 +169,6 @@
 				this.dataDetails = JSON.parse(options.data)
 				this.dataDetails.driverType = 1
 			}
-			this.validityPeriod = this.$helper.makeValidityPeriod('kong',1980)
-			this.validityPeriod1 = this.$helper.makeValidityPeriod(0,1980)
-			console.log(this.validityPeriod)
 		},
 		methods: {
 			async get_camera_permission() {
@@ -360,126 +227,50 @@
 				// });
 			},
 			validate(data) {},
-			confirmValidityPeriod(e) {
-				console.log('confirm', e)
-				if(e.value[0]=='长期'){
-					if (e.value[1] || e.value[2]) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "选择长期不允许选择月日!",
-						})
-						return
-					}
+			confirmValidityPeriod(date) {
+				console.log('confirm', date)
 					switch (this.ValidityPeriodType) {
 						case 0:
-							this.dataDetails.driverLicenseValidityStartDate = e.value[0]
+							this.dataDetails.driverLicenseValidityStartDate = date.date
 							break
 						case 1:
-							this.dataDetails.drivingLicenseValidityDate = e.value[0] 
+							this.dataDetails.drivingLicenseValidityDate = date.date 
 							break
 						case 2:
-							this.dataDetails.trailerLicenseValidityDate = e.value[0]
+							this.dataDetails.trailerLicenseValidityDate = date.date
 							break
 						case 3:
-							this.dataDetails.qualificationCertificateValidityDate = e.value[0] 
+							this.dataDetails.qualificationCertificateValidityDate = date.date 
 							break
 						case 4:
-							this.dataDetails.operationCertificateValidityDate = e.value[0] 
+							this.dataDetails.operationCertificateValidityDate = date.date 
 							break
 						case 5:
-							this.dataDetails.trailerOperationCertificateValidityDate = e.value[0] 
+							this.dataDetails.trailerOperationCertificateValidityDate = date.date 
 							break
 						case 9:
-							this.dataDetails.driverLicenseValidityDate = e.value[0]
+							this.dataDetails.driverLicenseValidityDate = date.date
 							break
 					}
+					this.$forceUpdate()
+				
+			},
+			selectValidityPeriod(type) {
+				this.ValidityPeriodType = type
+				if(type==0){
+					this.$refs.datestartEl.show()
 				}else{
-					if(e.value[0]==''){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "年份不能为空!",
-						})
-						return
-					}else if(e.value[1]==''){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "月份不能为空!",
-						})
-						return
-					}else if(e.value[2]==''){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "日期不能为空!",
-						})
-						return
-					}
-					var date=new Date()
-					var text=''
-					switch (this.ValidityPeriodType) {
-						case 3:
-							text='从业资格证已过期!'
-							break
-						case 9:
-							text='驾驶证已过期!'
-							break
-					}
-					if(this.ValidityPeriodType==3||this.ValidityPeriodType==9){
-						if(e.value[0]<date.getFullYear()){
-							this.$refs.uToast.show({
-								type: 'error',
-								message: text,
-							})
-							return
-						}
-						if(e.value[0]==date.getFullYear()&&Number(e.value[1])<(date.getMonth()+1)){
-							this.$refs.uToast.show({
-								type: 'error',
-								message: text,
-							})
-							return
-						}
-						if(e.value[0]==date.getFullYear()&&Number(e.value[1])==(date.getMonth()+1)&&Number(e.value[2])<=(date.getDate())){
-							this.$refs.uToast.show({
-								type: 'error',
-								message: text,
-							})
-							return
-						}
-					}
 					switch (this.ValidityPeriodType) {
-						case 0:
-							this.dataDetails.driverLicenseValidityStartDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-							break
-						case 1:
-							this.dataDetails.drivingLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-							break
-						case 2:
-							this.dataDetails.trailerLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-							break
-						case 3:
-							this.dataDetails.qualificationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-								.value[2]
-							break
-						case 4:
-							this.dataDetails.operationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[
-								2]
-							break
-						case 5:
-							this.dataDetails.trailerOperationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-								.value[2]
-							break
-						case 9:
-							this.dataDetails.driverLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-									.value[2]
-								break
+					case 3:
+						this.status=0
+						this.overdueContent='从业资格证已过期'
+						break
+					case 9:
+						this.overdueContent='驾驶证已过期'
+						break
 					}
+					this.$refs.dateEl.show()
 				}
-				this.isShowValidity = false
-			},
-			selectValidityPeriod(type) {
-				
-				this.ValidityPeriodType = type
-				this.isShowValidity = true
 			},
 			driveType(){
 				this.isShowDrive = true

+ 23 - 49
pages/mine/editDriverCertification.vue

@@ -90,6 +90,10 @@
 			<u-picker :show="isShowcardValidity" ref="uPicker" :columns="validityPeriod"
 				@confirm="confirmValidityPeriod" @change="changeHandler" @cancel='isShowcardValidity= false'>
 			</u-picker>
+			<itmister-date-picker :overdueContent="'身份证已过期'" :dateStatus="status" :periodOfValidity="true"
+			 :checkYear="year" :checkMonth="month" :checkDay="day"
+			 ref="dateEl" :startYear="1999"  :futureYear="30" 
+			 @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
 			<u-action-sheet :actions="$helper.imgTypeList" :title="$helper.imgType" :show="isShowimgType"
 				@select="imgTypeSelect" :closeOnClickOverlay="true" :closeOnClickAction="true"
 				@close="isShowimgType=false">
@@ -122,10 +126,13 @@
 					width: 188,
 					height: 273
 				},
+				status:1,
 				tips: '',
 				// refCode: null,
 				seconds: 30,
-
+				year:'',
+				month:'',
+				day:'',
 				radiolist1: [{
 						name: '男',
 						disabled: false
@@ -178,8 +185,6 @@
 			_this = this;
 			console.log(this.userInfo)
 			this.get_camera_permission()
-			//获取截止日期List数据
-			this.validityPeriod = this.$helper.makeValidityPeriod(0)
 			// this.dataDetails.driverPhone = this.userInfo.phone
 			this.dataDetails.commonId = this.userInfo.id
 			//获取认证状态
@@ -295,54 +300,23 @@
 						uni.$u.toast(res.message);
 					});
 			},
-			confirmValidityPeriod(e) {
-				console.log('confirm', e)
-				if (e.value[0] == '长期') {
-					this.dataDetails.cardValidityDate = e.value[0]
-					if (e.value[1] || e.value[2]) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "选择长期不允许选择月日!",
-						})
-						return
-					}
-				} else {
-					if (!e.value[1] || !e.value[2]) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "日期格式错误,请重新选择!",
-						})
-						return
-					}
-					var date=new Date()
-					if(e.value[0]<date.getFullYear()){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "身份证已过期!",
-						})
-						return
-					}
-					if(e.value[0]==date.getFullYear()&&Number(e.value[1])<(date.getMonth()+1)){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "身份证已过期!",
-						})
-						return
-					}
-					if(e.value[0]==date.getFullYear()&&Number(e.value[1])==(date.getMonth()+1)&&Number(e.value[2])<=(date.getDate())){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "身份证已过期!",
-						})
-						return
-					}
-					this.dataDetails.cardValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-				}
-
-				this.isShowcardValidity = false
+			confirmValidityPeriod(date) {
+				console.log('confirm', date)
+				this.dataDetails.cardValidityDate = date.date
 			},
 			selectValidityPeriod() {
-				this.isShowcardValidity = true
+				if(this.dataDetails.cardValidityDate!='长期'){
+					var arr=this.dataDetails.cardValidityDate.split('-')
+					this.year=arr[0]
+					this.month=arr[1]
+					this.day=arr[2]
+				}
+				if(this.dataDetails.cardValidityDate=='长期'){
+					this.year='长期'
+					this.month=''
+					this.day=''
+				}
+				this.$refs.dateEl.show()
 			},
 			//设置图片
 			setImage(e) {

+ 61 - 244
pages/mine/editDriverCertificationNext.vue

@@ -60,91 +60,7 @@
 					<u--input placeholder="请输入驾驶证发证机关" inputAlign='right' border="none" v-model="dataDetails.lssuingAuthority" >
 					</u--input>
 				</view>
-				<!--
-				<view class="title">上传行驶证主页</view>
-				<view @click="uploadImg(3)" class="picture picture3" v-if="!dataDetails.drivingLicenseHomePage">
-					<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-					<view class="text">上传行驶证主页</view>
-				</view>
-				<view v-if="dataDetails.drivingLicenseHomePage" @click.stop="uploadImg(3)"
-					class="preview-card-img picture">
-					<view @click.stop="delCard(3)">
-						<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-						</image>
-					</view>
-					<image class="" :src="dataDetails.drivingLicenseHomePage" mode="aspectFit"></image>
-				</view>
-				<view class="title">上传行驶证副页</view>
-				<view @click="uploadImg(4)" class="picture picture4" v-if="!dataDetails.drivingLicenseBackPage">
-					<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-					<view class="text">上传行驶证副页</view>
-				</view>
-				<view v-if="dataDetails.drivingLicenseBackPage" @click.stop="uploadImg(4)"
-					class="preview-card-img picture">
-					<view @click.stop="delCard(4)">
-						<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-						</image>
-					</view>
-					<image class="" :src="dataDetails.drivingLicenseBackPage" mode="aspectFit"></image>
-				</view>
-				<view class="flex row">
-					<view class="left-text">行驶证档案编号</view>
-					<u--input placeholder="输入行驶证档案编号" inputAlign='left' border="none"
-						v-model="dataDetails.drivingLicenseNumber">
-					</u--input>
-				</view>
-				<view class="flex row">
-					<view class="left-text">行驶证有效期</view>
-					<view class="" @click="selectValidityPeriod(1)">
-						{{dataDetails.drivingLicenseValidityDate?dataDetails.drivingLicenseValidityDate:'选择有效截止日期>'}}
-					</view>
-				</view>
-
-
-				<view class="" v-if="isGCar">
-					<view class="title row flex">挂车行驶证主页</view>
-					<view @click="uploadImg(5)" class="picture picture5" v-if="!dataDetails.trailerLicenseHomePage">
-						<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-						<view class="text">上传挂车行驶证主页</view>
-					</view>
-					<view v-if="dataDetails.trailerLicenseHomePage" @click.stop="uploadImg(5)"
-						class="preview-card-img picture">
-						<view @click.stop="delCard(5)">
-							<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-							</image>
-						</view>
-						<image class="" :src="dataDetails.trailerLicenseHomePage" mode="aspectFit"></image>
-					</view>
-				</view>
-				<view v-if="isGCar">
-					<view class="title row flex">挂车行驶证副页</view>
-					<view @click="uploadImg(6)" class="picture picture6" v-if="!dataDetails.trailerLicenseBackPage">
-						<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-						<view class="text">上传挂车行驶证副页</view>
-					</view>
-					<view v-if="dataDetails.trailerLicenseBackPage" @click.stop="uploadImg(6)"
-						class="preview-card-img picture">
-						<view @click.stop="delCard(6)">
-							<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-							</image>
-						</view>
-						<image class="" :src="dataDetails.trailerLicenseBackPage" mode="aspectFit"></image>
-					</view>
-				</view>
-				<view class="flex row" v-if="isGCar">
-					<view class="left-text">挂车行驶证档案编号</view>
-					<u--input placeholder="输入挂车行驶证档案编号" inputAlign='left' border="none"
-						v-model="dataDetails.trailerLicenseNumber">
-					</u--input>
-				</view>
-				<view class="flex row" v-if="isGCar">
-					<view class="left-text">挂车行驶证有效期</view>
-					<view class="" @click="selectValidityPeriod(2)">
-						{{dataDetails.trailerLicenseValidityDate?dataDetails.trailerLicenseValidityDate:'选择有效截止日期>'}}
-					</view>
-				</view>
-				-->
-
+				
 				<view class="title">从业资格证</view>
 				<view @click="uploadImg(7)" class="picture picture7" v-if="!dataDetails.qualificationCertificate">
 					<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
@@ -170,64 +86,6 @@
 					<u--input maxlength='19' placeholder="请输入从业资格证号" inputAlign='right' border="none" v-model="dataDetails.qualificationCertificateNumber">
 					</u--input>
 				</view>
-				<!--
-
-				<view class="title">道路运输证</view>
-				<view @click="uploadImg(8)" class="picture picture8" v-if="!dataDetails.operationCertificate">
-					<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-					<view class="text">上传道路运输证</view>
-				</view>
-				<view v-if="dataDetails.operationCertificate" @click.stop="uploadImg(8)"
-					class="preview-card-img picture">
-					<view @click.stop="delCard(8)">
-						<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-						</image>
-					</view>
-					<image class="" :src="dataDetails.operationCertificate" mode="aspectFit"></image>
-				</view>
-				<view class="flex row">
-					<view class="left-text">道路运输证号</view>
-					<u--input placeholder="输入道路运输证号" inputAlign='left' border="none"
-						v-model="dataDetails.operationCertificateNumber">
-					</u--input>
-				</view>
-				<view class="flex row">
-					<view class="left-text">道路运输证有效期</view>
-					<view class="" @click="selectValidityPeriod(4)">
-						{{dataDetails.operationCertificateValidityDate?dataDetails.operationCertificateValidityDate:'选择有效期>'}}
-					</view>
-				</view>
-
-				<view v-if="isGCar">
-					<view class="title row flex">挂车道路运输证</view>
-					<view @click="uploadImg(9)" class="picture picture9"
-						v-if="!dataDetails.trailerOperationCertificate">
-						<image class="xj-image" src="@/static/images/mine/ic_shanchuan@2x.png"></image>
-						<view class="text">上传挂车道路运输证</view>
-					</view>
-					<view v-if="dataDetails.trailerOperationCertificate" @click.stop="uploadImg(9)"
-						class="preview-card-img picture">
-						<view @click.stop="delCard(9)">
-							<image class='del-card' src="@/static/images/common/quxiao@2x.png">
-							</image>
-						</view>
-						<image class="" :src="dataDetails.trailerOperationCertificate" mode="aspectFit"></image>
-					</view>
-				</view>
-				<view class="flex row" v-if="isGCar">
-					<view class="left-text">挂车道路运输证号</view>
-					<u--input placeholder="输入挂车道路运输证号" inputAlign='left' border="none"
-						v-model="dataDetails.trailerOperationCertificateNumber">
-					</u--input>
-				</view>
-				<view class="flex row" v-if="isGCar">
-					<view class="left-text">挂车运输证有效期</view>
-					<view class="" @click="selectValidityPeriod(5)">
-						{{dataDetails.trailerOperationCertificateValidityDate?dataDetails.trailerOperationCertificateValidityDate:'选择有效期>'}}
-					</view>
-				</view>
-				
-				-->
 				<view class="flex row noborder align-center">
 					<view class="left-text">通讯地址</view>
 					<u--textarea v-model="dataDetails.postalAddress" border="none"  placeholder="输入通讯地址" autoHeight  maxlength="30"></u--textarea>
@@ -249,9 +107,18 @@
 				@select="imgTypeSelect" :closeOnClickOverlay="true" :closeOnClickAction="true"
 				@close="isShowimgType=false">
 			</u-action-sheet>
-			<u-picker :show="isShowValidity" ref="uPicker" :columns="ValidityPeriodType==9?validityPeriod1:validityPeriod" @confirm="confirmValidityPeriod"
+			<itmister-date-picker :dateStatus="0"
+			:checkYear="year" :checkMonth="month" :checkDay="day"
+			ref="datestartEl" :startYear="1980"  :futureYear="10" 
+			@dateConfirm="confirmValidityPeriod"></itmister-date-picker>
+			<itmister-date-picker :overdueContent="overdueContent" :dateStatus="status" 
+			:periodOfValidity="true" 
+			:checkYear="year" :checkMonth="month" :checkDay="day"
+			ref="dateEl" :startYear="1980"  :futureYear="10" 
+			@dateConfirm="confirmValidityPeriod"></itmister-date-picker>
+			<!-- <u-picker :show="isShowValidity" ref="uPicker" :columns="ValidityPeriodType==9?validityPeriod1:validityPeriod" @confirm="confirmValidityPeriod"
 				:closeOnClickOverlay='true' @close='isShowValidity=false' @cancel='isShowValidity=false'>
-			</u-picker>
+			</u-picker> -->
 			<u-picker :show="isShowDrive" ref="uPicker" :columns="driveList" @confirm="confirmDriveType"
 				:closeOnClickOverlay='true' @close='isShowDrive=false' @cancel='isShowDrive=false'>
 			</u-picker>
@@ -280,6 +147,9 @@
 				uploadType: '',
 				isShowimgType: false,
 				dataDetails: {},
+				year:'',
+				month:'',
+				day:'',
 				radiolist: [{
 						name: '挂车司机',
 						disabled: false
@@ -302,8 +172,6 @@
 			} else {
 				this.radiovalue = '非挂车司机'
 			}
-			this.validityPeriod = this.$helper.makeValidityPeriod('kong',1980)
-			this.validityPeriod1 = this.$helper.makeValidityPeriod(0,1980)
 		},
 		methods: {
 			async get_camera_permission() {
@@ -361,125 +229,74 @@
 				// 	data: this.consentStatus
 				// });
 			},
-			confirmValidityPeriod(e) {
-				console.log('confirm', e)
-				if(e.value[0]=='长期'){
-					if (e.value[1] || e.value[2]) {
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "选择长期不允许选择月日!",
-						})
-						return
-					}
+			confirmValidityPeriod(date) {
+				console.log('confirm', date)
 					switch (this.ValidityPeriodType) {
 						case 0:
-							this.dataDetails.driverLicenseValidityStartDate = e.value[0]
+							this.dataDetails.driverLicenseValidityStartDate = date.date
 							break
 						case 1:
-							this.dataDetails.drivingLicenseValidityDate = e.value[0] 
+							this.dataDetails.drivingLicenseValidityDate = date.date 
 							break
 						case 2:
-							this.dataDetails.trailerLicenseValidityDate = e.value[0]
+							this.dataDetails.trailerLicenseValidityDate = date.date
 							break
 						case 3:
-							this.dataDetails.qualificationCertificateValidityDate = e.value[0] 
+							this.dataDetails.qualificationCertificateValidityDate = date.date 
 							break
 						case 4:
-							this.dataDetails.operationCertificateValidityDate = e.value[0] 
+							this.dataDetails.operationCertificateValidityDate = date.date 
 							break
 						case 5:
-							this.dataDetails.trailerOperationCertificateValidityDate = e.value[0] 
+							this.dataDetails.trailerOperationCertificateValidityDate = date.date 
 							break
 						case 9:
-							this.dataDetails.driverLicenseValidityDate = e.value[0]
+							this.dataDetails.driverLicenseValidityDate = date.date
 							break
 					}
-				}else{
-					if(e.value[0]==''){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "年份不能为空!",
-						})
-						return
-					}else if(e.value[1]==''){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "月份不能为空!",
-						})
-						return
-					}else if(e.value[2]==''){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: "日期不能为空!",
-						})
-						return
+					this.$forceUpdate()
+				
+			},
+			selectValidityPeriod(type) {
+				this.ValidityPeriodType = type
+				if(type==0){
+					if(this.dataDetails.driverLicenseValidityStartDate!='长期'){
+						var arr=this.dataDetails.driverLicenseValidityStartDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
 					}
-					var date=new Date()
-					var text=''
+					console.log()
+					this.$refs.datestartEl.show()
+				}else{
 					switch (this.ValidityPeriodType) {
-						case 3:
-							text='从业资格证已过期!'
-							break
-						case 9:
-							text='驾驶证已过期!'
-							break
-					}
-					if(this.ValidityPeriodType==3||this.ValidityPeriodType==9){
-						if(e.value[0]<date.getFullYear()){
-							this.$refs.uToast.show({
-								type: 'error',
-								message: text,
-							})
-							return
-						}
-						if(e.value[0]==date.getFullYear()&&Number(e.value[1])<(date.getMonth()+1)){
-							this.$refs.uToast.show({
-								type: 'error',
-								message: text,
-							})
-							return
-						}
-						if(e.value[0]==date.getFullYear()&&Number(e.value[1])==(date.getMonth()+1)&&Number(e.value[2])<=(date.getDate())){
-							this.$refs.uToast.show({
-								type: 'error',
-								message: text,
-							})
-							return
+					case 3:
+						this.status=0
+						this.overdueContent='从业资格证已过期'
+						if(this.dataDetails.qualificationCertificateValidityDate!='长期'){
+							var arr=this.dataDetails.qualificationCertificateValidityDate.split('-')
+							this.year=arr[0]
+							this.month=arr[1]
+							this.day=arr[2]
 						}
+						break
+					case 9:
+					if(this.dataDetails.driverLicenseValidityDate!='长期'){
+						var arr=this.dataDetails.driverLicenseValidityDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
 					}
-					switch (this.ValidityPeriodType) {
-						case 0:
-							this.dataDetails.driverLicenseValidityStartDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-							break
-						case 1:
-							this.dataDetails.drivingLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-							break
-						case 2:
-							this.dataDetails.trailerLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-							break
-						case 3:
-							this.dataDetails.qualificationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-								.value[2]
-							break
-						case 4:
-							this.dataDetails.operationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[
-								2]
-							break
-						case 5:
-							this.dataDetails.trailerOperationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-								.value[2]
-							break
-						case 9:
-							this.dataDetails.driverLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-									.value[2]
-								break
+					if(this.dataDetails.driverLicenseValidityDate=='长期'){
+						this.year='长期'
+						this.month=''
+						this.day=''
+					}
+						this.overdueContent='驾驶证已过期'
+						break
 					}
+					this.$refs.dateEl.show()
 				}
-				this.isShowValidity = false
-			},
-			selectValidityPeriod(type) {
-				this.ValidityPeriodType = type
-				this.isShowValidity = true
 			},
 			driveType(){
 				this.isShowDrive = true

+ 3 - 7
pages/mine/manageBankCards/addBankCard.vue

@@ -36,14 +36,9 @@
 					<view @click="manualInput" class="type">选择支行</view>
 				</view>
 				<view class="flex align-center" v-if="!isShowManualInput">
-					<!-- 	<u--input  @click="selectZhbank" placeholder="选择开户支行" inputAlign='left' border="none" disabled>
-					</u--input> -->
-					<u--input class="select-bankzh point" placeholder="选择开户支行" inputAlign='left' border="none"
-						v-model="dataDetails.bankDepositBranch">
-					</u--input>
-					<!-- <view class="select-bankzh" @click="selectZhbank">
+					<view :style="{'color':dataDetails.bankDepositBranch?'#000':'#C6CBD5'}" style='font-size:15px;' class="select-bankzh" @click="selectZhbank">
 						{{dataDetails.bankDepositBranch?dataDetails.bankDepositBranch:'选择开户支行'}}
-					</view> -->
+					</view>
 					<view @click="manualInput" class="type">手动输入</view>
 				</view>
 
@@ -239,6 +234,7 @@
 										'/driverInfo/bankShibie', {
 											bankImg: result,
 										}).then(res => {
+											_this.dataDetails.bankDepositBranch=''
 										_this.dataDetails.payeeAddressUrl = result
 										if (res.data.bankNo) {
 											_this.dataDetails.bankCard = res.data.bankNo

+ 114 - 97
pages/mine/manageVehicles/addVehicle.vue

@@ -137,9 +137,10 @@
 			</view>
 			<view class="flex row flex-space-between">
 				<view class="left-text">使用性质</view>
-				<u--input placeholder="输入使用性质" inputAlign='right' border="none" v-model="dataDetails.useNature"
+				{{dataDetails.useNature?dataDetails.useNature:'输入使用性质'}}
+				<!-- <u--input placeholder="输入使用性质" inputAlign='right' border="none" v-model="dataDetails.useNature"
 					disabled>
-				</u--input>
+				</u--input> -->
 			</view>
 			<view class="flex row flex-space-between">
 				<view class="left-text">发证机关</view>
@@ -227,9 +228,10 @@
 			</view>
 			<view class="flex row flex-space-between" v-if="sign == '挂车'">
 				<view class="left-text">使用性质</view>
-				<u--input placeholder="输入使用性质" inputAlign='right' border="none" v-model="dataDetails.guaUseNature"
+				{{dataDetails.guaUseNature?dataDetails.guaUseNature:'输入使用性质'}}
+			<!-- 	<u--input placeholder="输入使用性质" inputAlign='right' border="none" v-model="dataDetails.guaUseNature"
 					disabled>
-				</u--input>
+				</u--input> -->
 			</view>
 			<view class="flex row flex-space-between" v-if="sign == '挂车'">
 				<view class="left-text">发证机关</view>
@@ -333,7 +335,7 @@
 				<view class="flex row">
 					<view class="left left-text">挂车车牌号</view>
 					<view class="right flex">
-						<input class="car-uumber" v-model='dataDetails.guaCarNumber'
+						<input class="car-uumber" v-model='dataDetails.guaCarNumber1'
 							@click.stop="handleShowKeyboard1(index)" :disabled="true" placeholder-class= "phsy" placeholder="输入挂车牌号"
 							name="input"></input>
@@ -408,9 +410,12 @@
 		</u-action-sheet>
 		<u-picker :show="carColor" :columns="colorColumns" :closeOnClickOverlay='true' @close='colorClose'
 			@cancel='colorClose' @confirm='confirmColor' ></u-picker>
-		<u-picker :show="isShowValidity" ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
+		<!-- <u-picker :show="isShowValidity" ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
 			:closeOnClickOverlay='true' @close='isShowValidity=false' @cancel='isShowValidity=false'>
-		</u-picker>
+		</u-picker> -->
+		<itmister-date-picker :overdueContent="overdueContent" :dateStatus="0" :periodOfValidity="true" ref="dateEl" :startYear="1999"  :futureYear="6" @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
+		<itmister-date-picker :overdueContent="overdueContent" :dateStatus="1" :periodOfValidity="true" ref="dateXSZEl" :startYear="1999"  :futureYear="10" @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
+		<itmister-date-picker :dateStatus="0" ref="daterestsEl" :startYear="1980"  :futureYear="0" @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
 		<u-picker :show="isShowCarType" ref="uPicker" :columns="carTypeList" @confirm="confirmCarType"
 			:closeOnClickOverlay='true' @close='isShowCarType=false' @cancel='isShowCarType=false'>
 		</u-picker>
@@ -433,6 +438,7 @@
 				keyShow1: false,
 				carNumber: '',
 				carNumber1: "",
+				overdueContent:'',
 				dataDetails: {
 					// driverId: '',
 					// carNumber: '',
@@ -451,6 +457,7 @@
 					// addressUrl: ''
 
 				},
+				startYear:1980,
 				carTypeList:[["汽油","柴油","油电混合","纯电动","插电式混合动力","增程式"]],
 				isShowCarType:false,
 				carModelColumns: [
@@ -484,7 +491,9 @@
 			_this = this;
 			this.dataDetails.commonId = this.userInfo.id
 			this.get_camera_permission()
-			this.validityPeriod = this.$helper.makeValidityPeriod()
+		},
+		onShow(){
+			this.startYear=new Date().getFullYear()-30
 		},
 		methods: {
 			async get_camera_permission() {
@@ -517,10 +526,10 @@
 			},
 			//挂车牌号弹出键盘
 			handleShowKeyboard1(index) {
-				if (this.dataDetails.guaCarNumber == '') {
+				if (this.dataDetails.guaCarNumber1 == '') {
 					this.carNumber1 = ''
 				} else {
-					this.carNumber1 = this.dataDetails.guaCarNumber
+					this.carNumber1 = this.dataDetails.guaCarNumber1
 				}
 				if (this.$refs.keyboard1.open) {
 					this.$refs.keyboard1.open(false) //true 键盘显示 false 键盘隐藏
@@ -536,7 +545,7 @@
 			},
 			handleClick1(e) {
 				this.carNumber1 = e.value
-				this.dataDetails.guaCarNumber = e.value //键盘输入值
+				this.dataDetails.guaCarNumber1 = e.value //键盘输入值
 			},
 			delCard(type) {
 				switch (type) {
@@ -569,7 +578,38 @@
 			},
 			selectValidityPeriod(type) {
 				this.ValidityPeriodType = type
-				this.isShowValidity = true
+				switch (this.ValidityPeriodType) {
+					case 1:
+					this.overdueContent='行驶证已过期'
+					this.$refs.dateXSZEl.show()
+					break;
+					case 2:
+					this.overdueContent='挂车行驶证已过期'
+					this.$refs.dateXSZEl.show()
+					break;
+					case 4:
+					this.overdueContent='道路运输证已过期'
+					this.$refs.dateEl.show()
+					break;
+					case 5:
+					this.overdueContent='挂车道路运输证已过期'
+					this.$refs.dateEl.show()
+					break;
+					case 6:
+					this.$refs.daterestsEl.show()
+					break;
+					case 7:
+					this.$refs.daterestsEl.show()
+					break;
+					case 8:
+					this.$refs.daterestsEl.show()
+					break;
+					case 9:
+					this.$refs.daterestsEl.show()
+					break;
+				}
+				// this.isShowValidity = true
+				
 			},
 			// 上传图片
 			imgTypeSelect(val) {
@@ -691,8 +731,12 @@
 															_this.dataDetails.trailerLicenseIssueDate = res
 																.data.licenseIssueDate
 														}
-														_this.dataDetails.guaCarNumber = res.data
-															.carNum //车牌号
+														if(res.data
+															.carNum){
+																_this.dataDetails.guaCarNumber1 = res.data
+															.carNum.substring(0,6)
+															}
+														 //车牌号
 														_this.dataDetails.guaOwner = res.data
 															.owner //车辆所有人
 														_this.$forceUpdate()
@@ -801,105 +845,40 @@
 
 				// }
 			},
-			confirmValidityPeriod(e) {
-				console.log('confirm', e)
-				if(e.value[0]==''){
-					this.$refs.uToast.show({
-						type: 'error',
-						message: "年份不能为空!",
-					})
-					return
-				}else if(e.value[1]==''){
-					this.$refs.uToast.show({
-						type: 'error',
-						message: "月份不能为空!",
-					})
-					return
-				}else if(e.value[2]==''){
-					this.$refs.uToast.show({
-						type: 'error',
-						message: "日期不能为空!",
-					})
-					return
-				}
-				var date=new Date()
-				var text=''
-				switch (this.ValidityPeriodType) {
-					case 4:
-						text='道路运输证已过期!'
-						break
-					case 5:
-						text='挂车道路运输证已过期!'
-						break
-					case 1:
-						text='行驶证已过期!'
-						break
-					case 2:
-						text='挂车行驶证已过期!'
-						break
-				}
-				if(this.ValidityPeriodType==1||this.ValidityPeriodType==2||this.ValidityPeriodType==4||this.ValidityPeriodType==5){
-					if(e.value[0]<date.getFullYear()){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: text,
-						})
-						return
-					}
-					if(e.value[0]==date.getFullYear()&&Number(e.value[1])<(date.getMonth()+1)){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: text,
-						})
-						return
-					}
-					if(e.value[0]==date.getFullYear()&&Number(e.value[1])==(date.getMonth()+1)&&Number(e.value[2])<=(date.getDate())){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: text,
-						})
-						return
-					}
-				}
+			confirmValidityPeriod(date) {
+				console.log('confirm', date)
 				switch (this.ValidityPeriodType) {
 					case 0:
-						this.dataDetails.driverLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
+						this.dataDetails.driverLicenseValidityDate = date.date
 						break
 					case 1:
-						this.dataDetails.drivingLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
+						this.dataDetails.drivingLicenseValidityDate = date.date
 						break
 					case 2:
-						this.dataDetails.trailerLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
+						this.dataDetails.trailerLicenseValidityDate = date.date
 						break
 					case 3:
-						this.dataDetails.qualificationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.qualificationCertificateValidityDate = date.date
 						break
 					case 4:
-						this.dataDetails.operationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[
-							2]
+						this.dataDetails.operationCertificateValidityDate = date.date
 						break
 					case 5:
-						this.dataDetails.trailerOperationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.trailerOperationCertificateValidityDate = date.date
 					case 6: //行驶证注册日期
-						this.dataDetails.drivingLicenseRegistrationDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.drivingLicenseRegistrationDate = date.date
 						break
 					case 7: //行驶证发证日期
-						this.dataDetails.drivingLicenseIssueDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.drivingLicenseIssueDate = date.date
 						break
 					case 8: //挂车行驶证注册日期
-						this.dataDetails.trailerLicenseRegistrationDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.trailerLicenseRegistrationDate = date.date
 						break
 					case 9: //挂车行驶证发证日期
-						this.dataDetails.trailerLicenseIssueDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.trailerLicenseIssueDate = date.date
 						break
 				}
-				this.isShowValidity = false
+				this.$forceUpdate()
 			},
 			// 车型切换
 			changeCarModel(e) {
@@ -1184,6 +1163,18 @@
 					})
 					return true
 				}
+				
+				if(this.dataDetails.drivingLicenseValidityDate!='长期'){
+					var arr=this.dataDetails.drivingLicenseValidityDate.split('-')
+					if(!this.$helper.periodOfValidity(arr[0],arr[1],arr[2])){
+						this.$refs.uToast.show({
+							type: 'error',
+							message: "行驶证已过期!",
+						})
+						return true
+					}
+				}
+				
 				if (uni.$u.test.isEmpty(this.dataDetails.lssuingAuthority)) {
 					this.$refs.uToast.show({
 						type: 'error',
@@ -1255,6 +1246,16 @@
 						})
 						return true
 					}
+					if(this.dataDetails.trailerLicenseValidityDate!='长期'){
+						var arr=this.dataDetails.trailerLicenseValidityDate.split('-')
+						if(!this.$helper.periodOfValidity(arr[0],arr[1],arr[2])){
+							this.$refs.uToast.show({
+								type: 'error',
+								message: "挂车行驶证已过期!",
+							})
+							return true
+						}
+					}
 					if (uni.$u.test.isEmpty(this.dataDetails.guaLssuingAuthority)) {
 						this.$refs.uToast.show({
 							type: 'error',
@@ -1324,7 +1325,13 @@
 					})
 					return true
 				}
-				
+				if (this.dataDetails.servicingWeight>100000) {
+					this.$refs.uToast.show({
+						type: 'error',
+						message: "整备质量输入错误!",
+					})
+					return true
+				}
 				if (uni.$u.test.isEmpty(this.dataDetails.carLong) || uni.$u.test.isEmpty(this.dataDetails.carWidth) || uni
 					.$u.test.isEmpty(this.dataDetails.carHeight)) {
 					this.$refs.uToast.show({
@@ -1359,7 +1366,7 @@
 						})
 						return true
 					}
-					if (uni.$u.test.isEmpty(this.dataDetails.guaCarNumber)) {
+					if (uni.$u.test.isEmpty(this.dataDetails.guaCarNumber1)) {
 						this.$refs.uToast.show({
 							type: 'error',
 							message: "挂车车牌号不能为空!",
@@ -1380,6 +1387,13 @@
 						})
 						return true
 					}
+					if (uni.$u.test.isEmpty(this.dataDetails.guaServicingWeight)) {
+						this.$refs.uToast.show({
+							type: 'error',
+							message: "挂车整备质量不能为空!",
+						})
+						return true
+					}
 					if (uni.$u.test.isEmpty(this.dataDetails.guaCarApprovedWeight)) {
 						this.$refs.uToast.show({
 							type: 'error',
@@ -1431,8 +1445,8 @@
 					delete this.dataDetails.guaUseNature
 				}
 				if(this.dataDetails.carCategory == "挂车"){
-					if(this.dataDetails.guaCarNumber.indexOf('挂')==-1){
-						this.dataDetails.guaCarNumber=this.dataDetails.guaCarNumber+'挂'
+					if(this.dataDetails.guaCarNumber1.indexOf('挂')==-1){
+						this.dataDetails.guaCarNumber=this.dataDetails.guaCarNumber1+'挂'
 					}
 				}
 				uni.showLoading({
@@ -1585,7 +1599,7 @@
 		}
 
 		.title {
-			color: #999999;
+			color: #000;
 			margin: 20rpx 0;
 		}
 	}
@@ -1675,4 +1689,7 @@
 	.car-uumber{
 		text-align:right;
 	}
+	.content{
+		font-size:15px;
+	}
 </style>

+ 137 - 84
pages/mine/manageVehicles/editVehicle.vue

@@ -368,9 +368,12 @@
 		</u-action-sheet>
 		<u-picker :show="carColor" :columns="colorColumns" :closeOnClickOverlay='true' @close='colorClose'
 			@cancel='colorClose' @confirm='confirmColor' ></u-picker>
-		<u-picker :show="isShowValidity" ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
+		<!-- <u-picker :show="isShowValidity" ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
 			:closeOnClickOverlay='true' @close='isShowValidity=false' @cancel='isShowValidity=false'>
-		</u-picker>
+		</u-picker> -->
+		<itmister-date-picker :checkYear="year" :checkMonth="month" :checkDay="day" :overdueContent="overdueContent" :dateStatus="0" :periodOfValidity="true" ref="dateEl" :startYear="1999"  :futureYear="6" @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
+		<itmister-date-picker :checkYear="year" :checkMonth="month" :checkDay="day" :overdueContent="overdueContent" :dateStatus="1" :periodOfValidity="true" ref="dateXSZEl" :startYear="1999"  :futureYear="10" @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
+		<itmister-date-picker :checkYear="year" :checkMonth="month" :checkDay="day" :dateStatus="0" ref="daterestsEl" :startYear="startYear"  :futureYear="0" @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
 		<u-picker :show="isShowCarType" ref="uPicker" :columns="carTypeList" @confirm="confirmCarType"
 			:closeOnClickOverlay='true' @close='isShowCarType=false' @cancel='isShowCarType=false'>
 		</u-picker>
@@ -393,6 +396,10 @@
 				keyShow1: false,
 				carNumber: '',
 				carNumber1: "",
+				overdueContent:'',
+				year:'',
+				month:'',
+				day:'',
 				dataDetails: {
 					// driverId: '',
 					// carNumber: '',
@@ -431,7 +438,8 @@
 				isShowValidity: false,
 				uploadType: '',
 				isShowimgType: false,
-				sign: "挂车"
+				sign: "挂车",
+				startYear:1980
 
 			};
 		},
@@ -439,6 +447,7 @@
 			...mapState(['hasLogin', 'userInfo', 'firstAuthentication']),
 		},
 		onLoad(options) {
+			
 			_this = this;
 			console.log(options)
 			if(options.guaCarNumber){
@@ -459,7 +468,9 @@
 				url: options.guaAddressUrl
 			}]
 			this.get_camera_permission()
-			this.validityPeriod = this.$helper.makeValidityPeriod()
+		},
+		onShow(){
+			this.startYear=new Date().getFullYear()-30
 		},
 		methods: {
 			async get_camera_permission() {
@@ -543,7 +554,93 @@
 			},
 			selectValidityPeriod(type) {
 				this.ValidityPeriodType = type
-				this.isShowValidity = true
+				var arr=[]
+				switch (this.ValidityPeriodType) {
+					case 1:
+					if(this.dataDetails.drivingLicenseValidityDate!='长期'){
+						arr=this.dataDetails.drivingLicenseValidityDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}else{
+						this.year='长期'
+						this.month=''
+						this.day=''
+					}
+					this.overdueContent='行驶证已过期'
+					this.$refs.dateXSZEl.show()
+					break;
+					case 2:
+					if(this.dataDetails.trailerLicenseValidityDate!='长期'){
+						arr=this.dataDetails.trailerLicenseValidityDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}else{
+						this.year='长期'
+						this.month=''
+						this.day=''
+					}
+					this.overdueContent='挂车行驶证已过期'
+					this.$refs.dateXSZEl.show()
+					break;
+					case 4:
+					if(this.dataDetails.operationCertificateValidityDate){
+						arr=this.dataDetails.operationCertificateValidityDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}
+					this.overdueContent='道路运输证已过期'
+					this.$refs.dateEl.show()
+					break;
+					case 5:
+					if(this.dataDetails.trailerOperationCertificateValidityDate){
+						arr=this.dataDetails.trailerOperationCertificateValidityDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}
+					this.overdueContent='挂车道路运输证已过期'
+					this.$refs.dateEl.show()
+					break;
+					case 6:
+					if(this.dataDetails.drivingLicenseRegistrationDate){
+						arr=this.dataDetails.drivingLicenseRegistrationDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}
+					this.$refs.daterestsEl.show()
+					break;
+					case 7:
+					if(this.dataDetails.drivingLicenseIssueDate){
+						arr=this.dataDetails.drivingLicenseIssueDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}
+					this.$refs.daterestsEl.show()
+					break;
+					case 8:
+					if(this.dataDetails.trailerLicenseRegistrationDate){
+						arr=this.dataDetails.trailerLicenseRegistrationDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}
+					this.$refs.daterestsEl.show()
+					break;
+					case 9:
+					if(this.dataDetails.trailerLicenseIssueDate){
+						arr=this.dataDetails.trailerLicenseIssueDate.split('-')
+						this.year=arr[0]
+						this.month=arr[1]
+						this.day=arr[2]
+					}
+					this.$refs.daterestsEl.show()
+					break;
+				}
 			},
 			// 上传图片
 			imgTypeSelect(val) {
@@ -774,106 +871,40 @@
 						}
 					});
 			},
-			confirmValidityPeriod(e) {
-				console.log('confirm', e)
-				if(e.value[0]==''){
-					this.$refs.uToast.show({
-						type: 'error',
-						message: "年份不能为空!",
-					})
-					return
-				}else if(e.value[1]==''){
-					this.$refs.uToast.show({
-						type: 'error',
-						message: "月份不能为空!",
-					})
-					return
-				}else if(e.value[2]==''){
-					this.$refs.uToast.show({
-						type: 'error',
-						message: "日期不能为空!",
-					})
-					return
-				}
-				var date=new Date()
-				var text=''
-				switch (this.ValidityPeriodType) {
-					case 4:
-						text='道路运输证已过期!'
-						break
-					case 5:
-						text='挂车道路运输证已过期!'
-						break
-					case 1:
-						text='行驶证已过期!'
-						break
-					case 2:
-						text='挂车行驶证已过期!'
-						break
-				}
-				if(this.ValidityPeriodType==1||this.ValidityPeriodType==2||this.ValidityPeriodType==4||this.ValidityPeriodType==5){
-					if(e.value[0]<date.getFullYear()){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: text,
-						})
-						return
-					}
-					if(e.value[0]==date.getFullYear()&&Number(e.value[1])<(date.getMonth()+1)){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: text,
-						})
-						return
-					}
-					if(e.value[0]==date.getFullYear()&&Number(e.value[1])==(date.getMonth()+1)&&Number(e.value[2])<=(date.getDate())){
-						this.$refs.uToast.show({
-							type: 'error',
-							message: text,
-						})
-						return
-					}
-				}
+			confirmValidityPeriod(date) {
+				
 				switch (this.ValidityPeriodType) {
 					case 0:
-						this.dataDetails.driverLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
+						this.dataDetails.driverLicenseValidityDate = date.date
 						break
 					case 1:
-						this.dataDetails.drivingLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
+						this.dataDetails.drivingLicenseValidityDate = date.date
 						break
 					case 2:
-						this.dataDetails.trailerLicenseValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
+						this.dataDetails.trailerLicenseValidityDate = date.date
 						break
 					case 3:
-						this.dataDetails.qualificationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.qualificationCertificateValidityDate = date.date
 						break
 					case 4:
-						this.dataDetails.operationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e.value[
-							2]
+						this.dataDetails.operationCertificateValidityDate = date.date
 						break
 					case 5:
-						this.dataDetails.trailerOperationCertificateValidityDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.trailerOperationCertificateValidityDate = date.date
 						break
 					case 6: //行驶证注册日期
-						this.dataDetails.drivingLicenseRegistrationDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.drivingLicenseRegistrationDate = date.date
 						break
 					case 7: //行驶证发证日期
-						this.dataDetails.drivingLicenseIssueDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.drivingLicenseIssueDate = date.date
 						break
 					case 8: //挂车行驶证注册日期
-						this.dataDetails.trailerLicenseRegistrationDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.trailerLicenseRegistrationDate = date.date
 						break
 					case 9: //挂车行驶证发证日期
-						this.dataDetails.trailerLicenseIssueDate = e.value[0] + '-' + e.value[1] + '-' + e
-							.value[2]
+						this.dataDetails.trailerLicenseIssueDate = date.date
 						break
 				}
-				this.isShowValidity = false
 			},
 			// 车型切换
 			changeCarModel(e) {
@@ -1031,6 +1062,7 @@
 				});
 			},
 			validate() {
+				
 				// true 为校验不通过
 				if (uni.$u.test.isEmpty(this.dataDetails.carNumber)) {
 					this.$refs.uToast.show({
@@ -1190,6 +1222,16 @@
 					})
 					return true
 				}
+				if(this.dataDetails.drivingLicenseValidityDate!='长期'){
+					var arr=this.dataDetails.drivingLicenseValidityDate.split('-')
+					if(!this.$helper.periodOfValidity(arr[0],arr[1],arr[2])){
+						this.$refs.uToast.show({
+							type: 'error',
+							message: "行驶证已过期!",
+						})
+						return true
+					}
+				}
 				if (uni.$u.test.isEmpty(this.dataDetails.lssuingAuthority)) {
 					this.$refs.uToast.show({
 						type: 'error',
@@ -1241,6 +1283,7 @@
 						})
 						return true
 					}
+					
 					if (uni.$u.test.isEmpty(this.dataDetails.guaCarNumber)) {
 						this.$refs.uToast.show({
 							type: 'error',
@@ -1312,6 +1355,16 @@
 						})
 						return true
 					}
+					if(this.dataDetails.trailerLicenseValidityDate!='长期'){
+						var arr=this.dataDetails.trailerLicenseValidityDate.split('-')
+						if(!this.$helper.periodOfValidity(arr[0],arr[1],arr[2])){
+							this.$refs.uToast.show({
+								type: 'error',
+								message: "挂车行驶证已过期!",
+							})
+							return true
+						}
+					}
 					if (uni.$u.test.isEmpty(this.dataDetails.guaLssuingAuthority)) {
 						this.$refs.uToast.show({
 							type: 'error',
@@ -1476,7 +1529,7 @@
 		}
 
 		.title {
-			color: #999999;
+			color: #000;
 			margin: 20rpx 0;
 		}
 	}

+ 33 - 2
pages/mine/often/oftenRoute.vue

@@ -6,14 +6,14 @@
 				<view class="route_site flex">
 					<span class="blueDot dot"></span>
 					<view class="site_text">
-						<!-- {{item.sendProvince}} -->{{item.sendCity ? item.sendCity: item.sendProvince}}
+						{{item.sendProvince}}{{item.sendCity }}
 						{{item.sendArea}}
 					</view>
 					<!-- {{item.sendCity ? item.sendCity: item.sendProvince}} {{item.sendArea}} -->
 					<image class="jt_css" src="@/static/images/goodSource/jt.png" mode='widthFix'></image>
 					<span class="redDot dot"></span>
 					<view class="site_text">
-						<!-- {{item.unloadProvince}} -->{{item.unloadCity ? item.unloadCity: item.unloadProvince}}
+						{{item.unloadProvince}}{{item.unloadCity }}
 						{{item.unloadArea}}
 					</view>
 				</view>
@@ -95,6 +95,37 @@
 							if (page.num == 1) {
 								this.routeData = []
 							}
+							if(res.data.records>0){
+								for (let i = 0; i < res.data.records.length; i++) {
+									if(res.data.records[i].sendProvince=='北京'
+									||res.data.records[i].sendProvince=='天津'
+									||res.data.records[i].sendProvince=='上海'
+									||res.data.records[i].sendProvince=='重庆'
+									||res.data.records[i].sendProvince=='台湾'
+									||res.data.records[i].sendProvince=='澳门'
+									||res.data.records[i].sendProvince=='香港'
+									||res.data.records[i].sendProvince=='钓鱼岛'){
+										res.data.records[i].sendProvince=''
+									}
+									if(res.data.records[i].sendCity=='钓鱼岛'){
+										res.data.records[i].sendArea=''
+									}
+									if(res.data.records[i].unloadProvince=='北京'
+									||res.data.records[i].unloadProvince=='天津'
+									||res.data.records[i].unloadProvince=='上海'
+									||res.data.records[i].unloadProvince=='重庆'
+									||res.data.records[i].unloadProvince=='台湾'
+									||res.data.records[i].unloadProvince=='澳门'
+									||res.data.records[i].unloadProvince=='香港'
+									||res.data.records[i].unloadProvince=='钓鱼岛'){
+										res.data.records[i].unloadProvince=''
+									}
+									if(res.data.records[i].unloadCity=='钓鱼岛'){
+										res.data.records[i].unloadArea=''
+									}
+								}
+							}
+							console.log(res.data.records)
 							this.routeData = this.routeData.concat(res.data.records); //追加新数据
 							this.$forceUpdate()
 							this.mescroll.endBySize(res.data.records.length, res.data.total);

+ 0 - 4
pages/mine/settings/editAvatar.vue

@@ -102,15 +102,11 @@
 				// 						.catch(res => {
 				// 							uni.$u.toast(res.message);
 				// 						});
-					
-					
-					
 				// 				}
 				// 			)
 				// 		}
 				// 	});
 				// }
-
 			},
 			submit() {
 				this.deptListurl.id = this.userInfo.id

+ 1 - 1
pages/news/newsSee.vue

@@ -32,7 +32,7 @@
 <style lang="scss">
 	.center{
 		padding:30rpx;
-		height: calc(100vh - 11.2vh);
+		height: calc(100vh - 4vh);
 		background: #F5F6FA ;
 		.news_info{
 			background: #FFFFFF;

+ 21 - 7
pages/order/cargoOwnerSee.vue

@@ -87,10 +87,10 @@
 								<view class="evaluate_name">{{item.driverName}}</view>
 								<view class="evaluate_date m-top10">{{objectInfo.createDate.split(' ')[0]}}</view>
 								<view class="flex m-top10">
-									<view class="branch_css ">{{item.count}}</view>
+									<view class="branch_css ">{{item.ownerScoreObtained}}</view>
 									<view class="">
-										<start count="5" v-model="item.count" size="35" activeColor="#ffaa00" :size="18"
-											:allowHalf='true' :readonly='true'>
+										<start count="5" v-model="item.ownerScoreObtained" size="35" activeColor="#ffaa00" :size="18"
+											:allowHalf='true' :disabled='true'>
 										</start>
 									</view>
 								</view>
@@ -98,7 +98,7 @@
 									{{item.driverContent}}
 								</view>
 								<view style='flex-wrap: wrap;' class='flex'>
-									<u--image style='margin:7rpx;border:1px solid #ccc;' v-for="(item,index) in item.imgList" :src="item" width='170rpx'
+									<u--image style='margin:7rpx;border:1px solid #ccc;' v-for="(item1,index) in item.imgList" @click='ylImg(item.imgList)' :src="item1" width='170rpx'
 										height='170rpx'>
 									</u--image>
 								</view>
@@ -166,6 +166,20 @@
 			this.show = true
 		},
 		methods: {
+			ylImg(src) {
+				uni.previewImage({
+					urls: src,
+					longPressActions: {
+						itemList: ['发送给朋友', '保存图片', '收藏'],
+						success: function(data) {
+							console.log('选中了第' + (data.tapIndex + 1) + '个按钮,第' + (data.index + 1) + '张图片');
+						},
+						fail: function(err) {
+							console.log(err.errMsg);
+						}
+					}
+				});
+			},
 			selectTypeClose() {
 				this.show = false
 			},
@@ -221,9 +235,9 @@
 								that.list[i].imgList = that.list[i].driverUrl.split(',')
 							}
 
-							that.list[i].count = (Number(that.list[i].ownerCredit) + Number(that.list[i]
-								.tranEfficiency) + Number(that.list[i].freightPayment) + Number(that.list[i]
-								.serviceQuality) + Number(that.list[i].comprehensiveSatisfaction)) / 15 * 5
+							// that.list[i].count = (Number(that.list[i].ownerCredit) + Number(that.list[i]
+							// 	.tranEfficiency) + Number(that.list[i].freightPayment) + Number(that.list[i]
+							// 	.serviceQuality) + Number(that.list[i].comprehensiveSatisfaction)) / 15 * 5
 						}
 						that.mescroll.endBySize(res.data.records.length, res.data.total);
 						uni.hideLoading()

+ 9 - 30
pages/order/confirmUnloading.vue

@@ -49,7 +49,7 @@
 			</view> -->
 			<view class="row-between">
 				<view class="left-text">卸车日期</view>
-				<view class="" @click="selectUnloadingDate">
+				<view class="row-right-text" @click="selectUnloadingDate">
 					{{detailData.carrierInfo.unloadingDate?detailData.carrierInfo.unloadingDate:'选择卸车日期'}}
 				</view>
 			</view>
@@ -63,11 +63,10 @@
 			</view> -->
 			<view class='row-between'>
 				<view class="row-left-text">定位</view>
-				<view class="flex align-center">
+				<view style='font-size:14px;' class="flex align-center">
 					{{detailData.carrierInfo.unloadCity}}{{detailData.carrierInfo.unloadArea}}
 					<view class="sx-style" @click.stop="getLngLat()">刷新</view>
 				</view>
-
 			</view>
 			<view class='s-flex'>
 				<view class="row-left-text" style="margin:20rpx 0;">上传卸车照片(1-3张)</view>
@@ -87,9 +86,11 @@
 		<u-modal :show="isShowAlert" :title="alertTitle" :content='alertContent' :closeOnClickOverlay='true'
 			:showCancelButton='true' confirmColor='#2772FB' @confirm="confirmClick" @close="cancelClick"
 			@cancel="cancelClick"></u-modal>
-		<u-picker :show="isShowValidity" :defaultIndex='defaultIndex' ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
+		<!--<u- picker :show="isShowValidity" :defaultIndex='defaultIndex' ref="uPicker" :columns="validityPeriod" @confirm="confirmValidityPeriod"
 			:closeOnClickOverlay='true' @close='isShowValidity=false' @cancel='isShowValidity=false'>
-		</u-picker>
+		</u-picker> -->
+		<itmister-date-picker :dateStatus="0" ref="dateEl" :endDate="array" :startYear="1999"  
+		:futureYear="30" @dateConfirm="confirmValidityPeriod"></itmister-date-picker>
 		<u-toast ref="uToast"></u-toast>
 	</view>
 </template>
@@ -103,7 +104,6 @@
 				imgList: [],
 				fileList1: [],
 				fileList2:[],
-				isShowValidity: false,
 				validityPeriod: [],
 				sourceType: ['camera'],
 				imgList1:[],
@@ -165,7 +165,6 @@
 				receiptImg:this.detailData.hyCarrierInfo.receiptImg,
 				id: this.detailData.carrierId?this.detailData.carrierId:this.detailData.hyCarrierInfo.id,
 			}
-			this.validityPeriod = this.$helper.makeValidityPeriod()
 			// #ifdef APP-PLUS
 			this.getLngLat();
 			// #endif
@@ -189,25 +188,6 @@
 				month = month + 1;
 				month = month.toString().padStart(2, "0");
 				date = date.toString().padStart(2, "0");
-				this.defaultIndex=[]
-				console.log(this.validityPeriod)
-				for(var i=0;i<this.validityPeriod[0].length;i++){
-					if(this.validityPeriod[0][i]==year){
-						console.log(this.validityPeriod[0][i])
-						this.defaultIndex.push(i)
-					}
-				}
-				for(var i=0;i<this.validityPeriod[1].length;i++){
-					if(this.validityPeriod[1][i]==month){
-						this.defaultIndex.push(i)
-					}
-				}
-				for(var i=0;i<this.validityPeriod[2].length;i++){
-					if(this.validityPeriod[2][i]==date){
-						this.defaultIndex.push(i)
-					}
-				}
-				console.log(this.defaultIndex)
 				let defaultDate = `${year}-${month}-${date}`
 				this.detailData.carrierInfo.unloadingDate = defaultDate
 				// this.$forceUpdate()
@@ -220,7 +200,7 @@
 				console.log(this.detailData.totalFreight.length)
 			},
 			selectUnloadingDate() {
-				this.isShowValidity = true
+				this.$refs.dateEl.show()
 			},
 			getLngLat() {
 				let that = this
@@ -533,9 +513,8 @@
 						uni.$u.toast(res.message);
 					});
 			},
-			confirmValidityPeriod(e) {
-				this.detailData.carrierInfo.unloadingDate = e.value[0] + '-' + e.value[1] + '-' + e.value[2]
-				this.isShowValidity = false
+			confirmValidityPeriod(date) {
+				this.detailData.carrierInfo.unloadingDate = date.date
 			},
 		},
 	}

+ 3 - 2
pages/order/index.vue

@@ -40,11 +40,12 @@
 				class="mescroll">
 				<view class="evaluatePage flex flex-space-between" v-show="tabIndex == 6" @click="evaluateClick">
 					<view class="left flex flex-space-between" @click="evaluateClick">
-						<u-icon size="20" name="edit-pen"></u-icon>
+						<!-- <u-icon size="20" name="edit-pen"></u-icon> -->
+						<image style='width:14px;height:14px;margin-right:7px;' src="../../static/images/order/pingjiabianji.png" mode=""></image>
 						<view style="margin-left: 20prx;">我的评价</view>
 					</view>
 					<view class="right">
-						<u-icon size="20" name="arrow-right"></u-icon>
+						<image style='width:12px;height:12px;' src="../../static/images/order/right.png" mode=""></image>
 					</view>
 				</view>
 				<view :id="'good'+good.id" class="good-list" v-for="good in goods" 

+ 71 - 70
pages/order/signContract.vue

@@ -431,89 +431,89 @@
 				} else { //提交合同
 					this.contractCheck = true
 					_obj.submitFlag = 2
-				}
-				if (!that.isScaleStart) {
-					if (!this.userInfo.signImg) {
+					if (!that.isScaleStart) {
+						if (!this.userInfo.signImg) {
+							that.$refs.uToast.show({
+								type: 'error',
+								message: "手写签名不能为空!",
+							})
+							return
+						}
+					
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.carrierInfo.carNo)) {
 						that.$refs.uToast.show({
 							type: 'error',
-							message: "手写签名不能为空!",
+							message: "车牌号不能为空!",
 						})
 						return
 					}
-
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.carrierInfo.carNo)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "车牌号不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.weight)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "装车净重不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.freight)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "运费不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.tranStartDate)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "运输起始日期不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.tranEndDate)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "运输截止日期不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.driverName)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "联络人姓名不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.driverPhone)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "联络人电话不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.advanceCharge) && that.dataDetails.advanceCharge != 0) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "装车后预付款不能为空!",
-					})
-					return
-				}
-				if (uni.$u.test.isEmpty(that.dataDetails.bankDeposit)) {
-					that.$refs.uToast.show({
-						type: 'error',
-						message: "收款账号不能为空!",
-					})
-					return
+					if (uni.$u.test.isEmpty(that.dataDetails.weight)) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "装车净重不能为空!",
+						})
+						return
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.freight)) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "运费不能为空!",
+						})
+						return
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.tranStartDate)) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "运输起始日期不能为空!",
+						})
+						return
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.tranEndDate)) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "运输截止日期不能为空!",
+						})
+						return
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.driverName)) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "联络人姓名不能为空!",
+						})
+						return
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.driverPhone)) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "联络人电话不能为空!",
+						})
+						return
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.advanceCharge) && that.dataDetails.advanceCharge != 0) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "装车后预付款不能为空!",
+						})
+						return
+					}
+					if (uni.$u.test.isEmpty(that.dataDetails.bankDeposit)) {
+						that.$refs.uToast.show({
+							type: 'error',
+							message: "收款账号不能为空!",
+						})
+						return
+					}
+					
+					
 				}
 				_obj.trailerNumber = that.dataDetails.trailerNumber
 				_obj.tranStartDate = that.dataDetails.tranStartDate
 				_obj.tranEndDate = that.dataDetails.tranEndDate
-
 				_obj.contactPersonName = that.dataDetails.driverName
 				_obj.contactPersonPhone = that.dataDetails.driverPhone
 				_obj.freightCars = that.dataDetails.freight
 				// _obj.advanceCharge = that.dataDetails.advanceCharge
-				_obj.id = that.dataDetails.id
 				_obj.carNumber = that.dataDetails.carrierInfo.carNo
 				_obj.weight = that.dataDetails.weight
 				_obj.advanceCharge = that.dataDetails.advanceCharge
@@ -521,6 +521,7 @@
 				_obj.bankDeposit = that.dataDetails.bankDeposit
 				_obj.bankDepositBranch = that.dataDetails.bankDepositBranch
 				_obj.payeeName = that.dataDetails.payeeName
+				_obj.id = that.dataDetails.id
 				_obj.typeFlag = 2
 				uni.canvasToTempFilePath({
 					canvasId: 'handWriting',

+ 2 - 2
pages/public/register.vue

@@ -265,9 +265,9 @@
 						identification:1,//司机标识
 						avatarUrl:"https://taohaoliang.oss-cn-beijing.aliyuncs.com/appData/1656724567954127.png"//司机默认头像
 					}).then(res => {
-						if (res.code == '11002') {
+						if (res.code == '11003') {
 							uni.showToast({
-								title: '验证码错误或过期,请重新获取',
+								title: res.message,
 								icon: 'none',
 								duration: 2000
 							})

+ 2 - 2
pages/riders/addFleet.vue

@@ -1,5 +1,5 @@
 <template>
-	<view class="center">
+	<view class="center1">
 
 		<view class="flex row form_css">
 			<view class="left-text">车队名称</view>
@@ -366,7 +366,7 @@
 </script>
 
 <style lang="scss">
-	.center {
+	.center1 {
 		padding: 30rpx;
 	}
 

+ 65 - 26
pages/riders/index.vue

@@ -74,8 +74,7 @@
 		<view class="riders" v-if="indexbtn == 2">
 			<view class="flex riders_top">
 				<view @click="selectChange" class="riders_city">{{city ? city : province}}</view>
-				<itmister-address-picker ref="addressElthree" :showCheck="false" @confirmChange="confirmChangethree">
-				</itmister-address-picker>
+				
 				<u-search placeholder="输入车队信息关键字" bgColor="#ffffff" v-model="searchKeyWord" @search="getList"
 					maxlength="15"></u-search>
 			</view>
@@ -126,6 +125,8 @@
 				暂无数据
 			</view> -->
 		</view>
+		<itmister-address-picker ref="addressElthree" :showCheck="false" @confirmChange="confirmChangethree">
+		</itmister-address-picker>
 		<u-toast ref="uToast"></u-toast>
 		<u-modal :show="isShowAlert" :title="alertTitle" :closeOnClickOverlay='true' :showCancelButton='true'
 			confirmColor='#2772FB' @confirm="confirmClick" @close="cancelClick" @cancel="cancelClick"></u-modal>
@@ -134,6 +135,9 @@
 </template>
 
 <script>
+	import {
+		mapState
+	} from 'vuex';
 	import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
 	import itmisterAddressPicker from '@/components/itmister-address-picker/itmister-address-picker.nvue'
 	import itmisterAddressPickerOther from '@/components/itmister-address-picker/itmister-address-picker-other.nvue'
@@ -149,6 +153,7 @@
 				routeData: [], //列表
 				// show1: false,
 				// show2: false,
+				passOnce:'',
 				title1: "",
 				title2: "",
 				sendInfo: {
@@ -227,6 +232,9 @@
 			// this.getList()
 		},
 		onLoad() {},
+		computed: {
+			...mapState(['hasLogin', 'userInfo']),
+		},
 		methods: {
 			mescrollInit(mescroll) {
 				this.mescroll = mescroll;
@@ -338,32 +346,59 @@
 			lookfleet(item) {
 				uni.$u.route("/pages/riders/fleetSee?fleetId=" + item.id)
 			},
+			async getPassOnce() {
+				
+				await this.$request.baseRequest('', '/driverInfo/firstAuthentication', {
+						driverPhone: this.userInfo.phone,
+					}).then(res => {
+						if(res.data){
+							// this.passOnce=res.data.passOnce
+							uni.setStorageSync("firstAuthentication", res.data) //更新缓存数据(解决pc端审核后未及时更新缓存  用于车友判断)
+						}
+					})
+					.catch(res => {
+						uni.$u.toast(res.message);
+					});
+			},
 			checking() {
-				this.statusVal = uni.getStorageSync("firstAuthentication").authenticationStatus
+				// this.getPassOnce()
+				// this.statusVal = this.passOnce
 				if (uni.getStorageSync("firstAuthentication")) {
-					if (this.statusVal != "已认证" && this.statusVal != "已过期") {
-						uni.setTabBarItem({
-							index: 1,
-							text: '车友',
-							pagePath: "/pages/riders/checkPage",
-							iconPath: 'static/images/common/zhaoche.png',
-							selectedIconPath: 'static/images/common/zhaoche_check.png'
-						})
-						uni.switchTab({
-							url: '/pages/riders/checkPage'
-						});
-					} else {
-						uni.setTabBarItem({
-							index: 1,
-							text: '车友',
-							pagePath: "/pages/riders/index",
-							iconPath: 'static/images/common/zhaoche.png',
-							selectedIconPath: 'static/images/common/zhaoche_check.png'
+					this.$request.baseRequest('', '/driverInfo/firstAuthentication', {
+							driverPhone: this.userInfo.phone,
+						}).then(res => {
+							if(res.data){
+								// this.passOnce=res.data.passOnce
+								uni.setStorageSync("firstAuthentication", res.data) //更新缓存数据(解决pc端审核后未及时更新缓存  用于车友判断)
+								if (res.data.passOnce!=1) {
+									uni.setTabBarItem({
+										index: 1,
+										text: '车友',
+										pagePath: "/pages/riders/checkPage",
+										iconPath: 'static/images/common/zhaoche.png',
+										selectedIconPath: 'static/images/common/zhaoche_check.png'
+									})
+									uni.switchTab({
+										url: '/pages/riders/checkPage'
+									});
+								} else {
+									uni.setTabBarItem({
+										index: 1,
+										text: '车友',
+										pagePath: "/pages/riders/index",
+										iconPath: 'static/images/common/zhaoche.png',
+										selectedIconPath: 'static/images/common/zhaoche_check.png'
+									})
+									uni.switchTab({
+										url: '/pages/riders/index'
+									});
+								}
+							}
 						})
-						uni.switchTab({
-							url: '/pages/riders/index'
+						.catch(res => {
+							uni.$u.toast(res.message);
 						});
-					}
+					
 				} else if (!uni.getStorageSync("firstAuthentication") && !uni.getStorageSync("userInfo")) { //判断有没有登录
 					this.tipsShow = true
 					this.tipsText = "您尚未登录,请前去登录!"
@@ -456,6 +491,7 @@
 				}
 			},
 			selectChange() {
+				console.log(this.$refs.addressElthree)
 				this.$refs.addressElthree.show();
 			},
 			// 确认选中
@@ -811,8 +847,11 @@
 			}
 
 			.exchange {
-				line-height: 200rpx;
-				margin-top: 60rpx;
+				transform: rotate(-90deg);
+				position:relative;
+				left:30px;
+				// line-height: 200rpx;
+				// margin-top: 60rpx;
 			}
 		}
 	}

BIN
static/images/order/pingjiabianji.png


BIN
static/images/order/right.png