Commit 08292bd5 authored by youjie's avatar youjie

优化选日期代码

parent 397fbdb3
...@@ -348,6 +348,7 @@ ...@@ -348,6 +348,7 @@
} }
}, },
btnStart(val){ btnStart(val){
uni.hideLoading()
if(this.timeType ==1){//出行时间的选择 if(this.timeType ==1){//出行时间的选择
this.msg.StartTime = val.year+'/'+val.month+'/'+val.day+' '+val.hour+':'+val.minute+':00'; this.msg.StartTime = val.year+'/'+val.month+'/'+val.day+' '+val.hour+':'+val.minute+':00';
this.STime = val this.STime = val
......
...@@ -242,9 +242,11 @@ ...@@ -242,9 +242,11 @@
return age; return age;
}, },
setBirthdayHandle(val){ setBirthdayHandle(val){
uni.hideLoading()
this.current.BirthDay=`${val.year}/${val.month}/${val.day}` this.current.BirthDay=`${val.year}/${val.month}/${val.day}`
}, },
setExpireHandle(val){ setExpireHandle(val){
uni.hideLoading()
this.current.PassportExpired=`${val.year}/${val.month}/${val.day}` this.current.PassportExpired=`${val.year}/${val.month}/${val.day}`
}, },
createNewGuest(obj){ createNewGuest(obj){
...@@ -281,6 +283,7 @@ ...@@ -281,6 +283,7 @@
}) })
}, },
setCountryHandle(val){ setCountryHandle(val){
uni.hideLoading()
this.current.Country=this.countries[val[0]].Name this.current.Country=this.countries[val[0]].Name
this.current.CountryId = this.countries[val[0]].ID this.current.CountryId = this.countries[val[0]].ID
this.defaultCountry = val this.defaultCountry = val
......
...@@ -434,6 +434,7 @@ ...@@ -434,6 +434,7 @@
}); });
}, },
setSaleHandle(val){ setSaleHandle(val){
uni.hideLoading()
this.createBy=this.sales[val[0]] this.createBy=this.sales[val[0]]
}, },
nativageToOrderHandle(){ nativageToOrderHandle(){
......
...@@ -452,6 +452,7 @@ export default { ...@@ -452,6 +452,7 @@ export default {
} }
}, },
confirmOpenTime(r){ confirmOpenTime(r){
uni.hideLoading()
this.msg.LegalIdCardTime=r.year+"-"+r.month+"-"+r.day this.msg.LegalIdCardTime=r.year+"-"+r.month+"-"+r.day
}, },
newMsg(type){ newMsg(type){
......
...@@ -454,6 +454,7 @@ ...@@ -454,6 +454,7 @@
}, },
methods: { methods: {
setDateHandler(val){ setDateHandler(val){
uni.hideLoading();
this.busInfor.time = `${val.year}-${val.month}-${val.day} ${val.hour}:${val.minute}` this.busInfor.time = `${val.year}-${val.month}-${val.day} ${val.hour}:${val.minute}`
this.orderMsg.OrderDate = this.busInfor.time this.orderMsg.OrderDate = this.busInfor.time
this.getPrices() this.getPrices()
......
...@@ -42,41 +42,37 @@ ...@@ -42,41 +42,37 @@
</label> </label>
</view> </view>
<template v-if="busInfor.CarType==1"> <template v-if="busInfor.CarType==1">
<view class="row items-center bus-input"> <view class="row items-center bus-input" @click="clickAirport">
<text class="bus-inputText" <text class="bus-inputText"
:style="{color: busInfor.AirportName?'#080A09':'#BCBCBC'}" :style="{color: busInfor.AirportName?'#080A09':'#BCBCBC'}">
@click="clickAirport">
{{busInfor.AirportName?busInfor.AirportName:busInfor.CarType==1?'出发地:选择机场':'目的地:选择机场'}} {{busInfor.AirportName?busInfor.AirportName:busInfor.CarType==1?'出发地:选择机场':'目的地:选择机场'}}
</text> </text>
</view> </view>
<view class="row items-center bus-input"> <view class="row items-center bus-input" @click="getTheCar=1,citiesVisible=true">
<text class="bus-inputText" <text class="bus-inputText"
:style="{color: busInfor.destination?'#080A09':'#BCBCBC'}" :style="{color: busInfor.destination?'#080A09':'#BCBCBC'}">
@click="getTheCar=1,citiesVisible=true">
{{busInfor.destination?busInfor.destination:busInfor.CarType==1?'目的地:地址或酒店':'出发地:地址或酒店'}} {{busInfor.destination?busInfor.destination:busInfor.CarType==1?'目的地:地址或酒店':'出发地:地址或酒店'}}
</text> </text>
</view> </view>
</template> </template>
<template v-if="busInfor.CarType==2"> <template v-if="busInfor.CarType==2">
<view class="row items-center bus-input"> <view class="row items-center bus-input" @click="getTheCar=3,citiesVisible=true">
<text class="bus-inputText" <text class="bus-inputText"
:style="{color: busInfor.startaddress?'#080A09':'#BCBCBC'}" :style="{color: busInfor.startaddress?'#080A09':'#BCBCBC'}">
@click="getTheCar=3,citiesVisible=true">
{{busInfor.startaddress?busInfor.startaddress:busInfor.CarType==1?'目的地:地址或酒店':'出发地:地址或酒店'}} {{busInfor.startaddress?busInfor.startaddress:busInfor.CarType==1?'目的地:地址或酒店':'出发地:地址或酒店'}}
</text> </text>
</view> </view>
<view class="row items-center bus-input"> <view class="row items-center bus-input" @click="clickAirport">
<text class="bus-inputText" <text class="bus-inputText"
:style="{color: busInfor.AirportName?'#080A09':'#BCBCBC'}" :style="{color: busInfor.AirportName?'#080A09':'#BCBCBC'}">
@click="clickAirport">
{{busInfor.AirportName?busInfor.AirportName:busInfor.CarType==1?'出发地:选择机场':'目的地:选择机场'}} {{busInfor.AirportName?busInfor.AirportName:busInfor.CarType==1?'出发地:选择机场':'目的地:选择机场'}}
</text> </text>
</view> </view>
</template> </template>
<view class="bus-input row-sbas-n" style="padding:36rpx 18rpx;"> <view class="bus-input row-sbas-n" style="padding:36rpx 18rpx;">
<view class="row"> <view class="row" @click="showDateHandle">
<text class="bus-inputText" :style="{color: busInfor.time?'#080A09':'#BCBCBC'}" @click="showDateHandle"> <text class="bus-inputText" :style="{color: busInfor.time?'#080A09':'#BCBCBC'}">
{{busInfor.time?busInfor.time:'接载时间'}} {{busInfor.time?busInfor.time:'接载时间'}}
</text> </text>
<u-icon name="arrow" :size="32" color="#000" style="position: relative;top: 2rpx;"></u-icon> <u-icon name="arrow" :size="32" color="#000" style="position: relative;top: 2rpx;"></u-icon>
...@@ -100,17 +96,15 @@ ...@@ -100,17 +96,15 @@
</view> </view>
</view> </view>
</scroll-view>--> </scroll-view>-->
<view class="row items-center bus-input"> <view class="row items-center bus-input" @click="getTheCar=3,citiesVisible=true">
<text class="bus-inputText" <text class="bus-inputText"
:style="{color: busInfor.startaddress?'#080A09':'#BCBCBC'}" :style="{color: busInfor.startaddress?'#080A09':'#BCBCBC'}">
@click="getTheCar=3,citiesVisible=true">
{{busInfor.startaddress?busInfor.startaddress:'出发地:地址或酒店'}} {{busInfor.startaddress?busInfor.startaddress:'出发地:地址或酒店'}}
</text> </text>
</view> </view>
<view class="row items-center bus-input"> <view class="row items-center bus-input" @click="getTheCar=2,citiesVisible=true">
<text class="bus-inputText" <text class="bus-inputText"
:style="{color: busInfor.destination?'#080A09':'#BCBCBC'}" :style="{color: busInfor.destination?'#080A09':'#BCBCBC'}">
@click="getTheCar=2,citiesVisible=true">
{{busInfor.destination?busInfor.destination:'目的地:地址或酒店'}} {{busInfor.destination?busInfor.destination:'目的地:地址或酒店'}}
</text> </text>
</view> </view>
...@@ -524,6 +518,7 @@ ...@@ -524,6 +518,7 @@
// this.getAirportList() // this.getAirportList()
}, },
setDateHandler(val){ setDateHandler(val){
uni.hideLoading()
this.busInfor.time = `${val.year}-${val.month}-${val.day} ${val.hour}:${val.minute}` this.busInfor.time = `${val.year}-${val.month}-${val.day} ${val.hour}:${val.minute}`
this.dateVisible = false this.dateVisible = false
}, },
......
...@@ -785,6 +785,7 @@ ...@@ -785,6 +785,7 @@
}) })
}, },
changeDown(e) { changeDown(e) {
uni.hideLoading()
let i = [e] let i = [e]
this.orderMsg.PhoneCode = this.countrys[i].PhoneCode this.orderMsg.PhoneCode = this.countrys[i].PhoneCode
}, },
...@@ -809,6 +810,7 @@ ...@@ -809,6 +810,7 @@
}, },
//选择时间 //选择时间
confirm(val) { confirm(val) {
uni.hideLoading()
if(!this.timeType){ if(!this.timeType){
this.busInfor.time = `${val.year}-${val.month}-${val.day} ${val.hour}:${val.minute}` this.busInfor.time = `${val.year}-${val.month}-${val.day} ${val.hour}:${val.minute}`
this.orderMsg.OrderDate = this.busInfor.time this.orderMsg.OrderDate = this.busInfor.time
......
...@@ -909,6 +909,7 @@ export default { ...@@ -909,6 +909,7 @@ export default {
} }
}, },
btnStart(val) { btnStart(val) {
uni.hideLoading();
if (this.timeType == 1) { if (this.timeType == 1) {
//出行时间的选择 //出行时间的选择
this.msg.StartTime = this.msg.StartTime =
......
...@@ -215,7 +215,7 @@ ...@@ -215,7 +215,7 @@
); );
}, },
btnStart(val){ btnStart(val){
uni.hideLoading()
if(this.timeType==1){ if(this.timeType==1){
this.qutime=val.hour+":"+val.minute this.qutime=val.hour+":"+val.minute
this.STime.hour = val.hour; this.STime.hour = val.hour;
......
...@@ -749,6 +749,7 @@ ...@@ -749,6 +749,7 @@
}) })
}, },
changeDown(e) { changeDown(e) {
uni.hideLoading();
let i = [e] let i = [e]
}, },
addGuest(index) { addGuest(index) {
...@@ -792,6 +793,7 @@ ...@@ -792,6 +793,7 @@
}, },
//选择时间 //选择时间
confirm(val) { confirm(val) {
uni.hideLoading();
this.orderMsg.ArrivalTime = val.hour + ':' + val.minute; this.orderMsg.ArrivalTime = val.hour + ':' + val.minute;
}, },
//计算总价 //计算总价
......
...@@ -804,6 +804,7 @@ ...@@ -804,6 +804,7 @@
); );
}, },
changeBranch(val) { changeBranch(val) {
uni.hideLoading()
this.msg.companyId = this.branchList[val].BId this.msg.companyId = this.branchList[val].BId
this.currentBrachName = this.branchList[val].BName this.currentBrachName = this.branchList[val].BName
this.CityId = this.branchList[val].CityId; this.CityId = this.branchList[val].CityId;
...@@ -1011,6 +1012,7 @@ ...@@ -1011,6 +1012,7 @@
}, },
//获取日期 //获取日期
getStratDate(val) { getStratDate(val) {
uni.hideLoading()
console.log(val, 'val'); console.log(val, 'val');
}, },
lower(e) { lower(e) {
......
...@@ -368,6 +368,7 @@ ...@@ -368,6 +368,7 @@
); );
}, },
btnStart(val) { btnStart(val) {
uni.hideLoading();
this.msg.FoundingTime = val.year+'-'+val.month+'-'+val.day; this.msg.FoundingTime = val.year+'-'+val.month+'-'+val.day;
}, },
}, },
......
...@@ -428,6 +428,7 @@ ...@@ -428,6 +428,7 @@
); );
}, },
confirmOpenTime(r){ confirmOpenTime(r){
uni.hideLoading()
this.model.OpenTime=r.year+"-"+r.month+"-"+r.day this.model.OpenTime=r.year+"-"+r.month+"-"+r.day
}, },
......
...@@ -380,6 +380,7 @@ ...@@ -380,6 +380,7 @@
); );
}, },
btnStart(val) { btnStart(val) {
uni.hideLoading();
this.msg.FoundingTime = val.year + '-' + val.month + '-' + val.day; this.msg.FoundingTime = val.year + '-' + val.month + '-' + val.day;
}, },
}, },
......
...@@ -396,6 +396,7 @@ ...@@ -396,6 +396,7 @@
); );
}, },
btnStart(val) { btnStart(val) {
uni.hideLoading();
this.msg.FoundingTime = val.year + '-' + val.month + '-' + val.day; this.msg.FoundingTime = val.year + '-' + val.month + '-' + val.day;
}, },
......
...@@ -208,6 +208,7 @@ ...@@ -208,6 +208,7 @@
); );
}, },
choosesupplier(val){ choosesupplier(val){
uni.hideLoading();
this.msg.SupplierId = this.array[val].ID; this.msg.SupplierId = this.array[val].ID;
this.SupplierName = this.array[val].Name; this.SupplierName = this.array[val].Name;
}, },
...@@ -217,7 +218,7 @@ ...@@ -217,7 +218,7 @@
this.showpicker = true; this.showpicker = true;
}, },
dateconfirm(val){ dateconfirm(val){
uni.hideLoading();
if(this.datetype==1){ if(this.datetype==1){
let StartTime = val.year +'-'+val.month +'-'+val.day; let StartTime = val.year +'-'+val.month +'-'+val.day;
......
...@@ -391,7 +391,7 @@ export default { ...@@ -391,7 +391,7 @@ export default {
this.showExpress = true; this.showExpress = true;
}, },
chosenExpressHandler(i) { chosenExpressHandler(i) {
uni.hideLoading();
this.forms.ExpressId = this.expressList[i].ID; this.forms.ExpressId = this.expressList[i].ID;
this.forms.expressName = this.expressList[i].Name; this.forms.expressName = this.expressList[i].Name;
}, },
......
...@@ -229,6 +229,7 @@ export default { ...@@ -229,6 +229,7 @@ export default {
this.research() this.research()
}, },
changeDown(e,type) { changeDown(e,type) {
uni.hideLoading()
let i = e[0] let i = e[0]
this.showVisaType = false; this.showVisaType = false;
this.showEntryType = false this.showEntryType = false
......
...@@ -1005,6 +1005,7 @@ ...@@ -1005,6 +1005,7 @@
}, err => {}) }, err => {})
}, },
changeDown(e,type){ changeDown(e,type){
uni.hideLoading()
let i = [e] let i = [e]
if(type == 1){ if(type == 1){
this.customer.count = this.countrys[i].ID this.customer.count = this.countrys[i].ID
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment