Commit e3c3d707 authored by 李超鹏's avatar 李超鹏

Merge remote-tracking branch 'origin/master'

parents 007b6544 cc8f6f40
......@@ -36,7 +36,7 @@
:class="{'time-item':true,'active': item.pkey===appointRange}" v-for="(item,index) in timeList"
:key="item.pkey">
<button class="time" :plain="true"
:disabled="item.disabled" :hair-line="false"
:disabled="item.disabled || (currentDayIndex == 0 && item.pkey <= currentPkey)" :hair-line="false"
@click="timeChange(item,index,timeList)">
{{item.name}}
</button>
......@@ -101,7 +101,9 @@
appointRange: null,
appointRangeText: '',
num: 0,
hasLast: false
hasLast: false,
currentPkey: 'appointment_range_' + new Date().getHours(),
currentDayIndex: -1,
}
},
watch: {
......@@ -125,6 +127,7 @@
this.appointTime = item.day
this.appointRange = null
this.appointRangeText = ''
this.currentDayIndex = index
this.$emit('date-change', data)
},
timeChange(item, index, list) {
......
......@@ -125,14 +125,16 @@
setValue() {
const dataValue = []
this.imgList.map(item=>{
dataValue.push(item.path)
dataValue.push(item.src)
})
console.log("dataValue", dataValue)
this.valueChange(dataValue)
},
closeTake(val) {
if(val && val.length > 0){
val.forEach((item,index,array)=>{
item.path = item.key
item.src = item.key
this.imgList.push(item)
})
this.setValue()
......
......@@ -19,7 +19,7 @@
<image class="address-image" :src="dizhiImage" mode="widthFix"></image>
<text>{{ formatAddress(orderData) }}</text>
</view>
<view v-if="showDistance">
<view v-if="showDistance" class="address-right-view">
{{orderDistance}}km
</view>
</view>
......@@ -216,6 +216,7 @@
}
},
created() {
console.log('+++++++++++')
/*
orderStatus:
待接单 orderStatus<31 工单状态小于31
......@@ -249,9 +250,9 @@
} else {
this.orderType = this.types[this.type]
}
this.timeout = this.orderData.currentOverTime < new Date().getTime()
this.timestamp = Math.round(Math.abs(this.orderData.currentOverTime - new Date().getTime()) / 1000)
console.log('++++++', this.timestamp)
},
methods: {
handleClick() {
......@@ -382,17 +383,19 @@
align-items: center;
align-items: flex-start;
text-align: left;
margin-right: 30rpx;
.address-image {
width: 26rpx;
height: 28rpx;
margin-right: 8rpx;
flex-shrink: 0;
margin-top: 4rpx;
margin-top: 4rpx;
}
}
.address-right-view {}
.address-right-view {
margin-left: 30rpx;
}
}
}
......
......@@ -113,12 +113,22 @@
photo.currentItemLength = 0
// this.ctx = uni.createCameraContext();
this.updateTime()
this.getLocation()
const locationData = uni.getStorageSync('locationData')
const validityTime = 60000
if (Date.now() - locationData.locationTime < validityTime) { // 1分钟内不重复请求位置信息
this.waterInfo.latitude = locationData.waterInfo.latitude
this.waterInfo.longitude = locationData.waterInfo.longitude
this.baiduLocation()
} else {
this.getLocation()
}
this.getMarkPath()
this.initData()
photo.currentItem = this.currentItem
if (this.currentItem.images.length > 0) {
if (this.currentItem.images && this.currentItem.images.length > 0) {
this.shadowInitShow = true
this.standardShow = true
this.standardStatus = true
......@@ -266,6 +276,17 @@
success: function(res) {
waterInfo.longitude = parseFloat(res.longitude).toFixed(4)
waterInfo.latitude = parseFloat(res.latitude).toFixed(3)
const data = {
waterInfo: {
latitude: waterInfo.latitude,
longitude: waterInfo.longitude
},
locationTime: Date.now()
}
uni.setStorage({
key: 'locationData',
data: data,
})
that.baiduLocation()
},
fail(err) {
......
......@@ -33,7 +33,7 @@
<!-- 入驻前-->
<view v-if="needSettled" class="tip-view">
<image :src="weiruzhuImage" class="tip-view-image"></image>
<view class="tip-other">入驻通过后平台将向您推荐订单</view>
<view class="tip-other">入驻后平台将向您分配或推荐订单</view>
<u-button class="settle-button" type="primary" shape="circle" @click="immediatelyIn"
:custom-style="buttonStyle">
立即入驻
......@@ -269,7 +269,8 @@
if (self.search.pageNumber == 1) {
self.orderList = []
}
self.orderList.push(...res.data.list);
self.orderList.push(...res.data.list);
console.log('this.orderlist;', this.orderList)
self.currentLoadStatus = res.data.total > self.orderList.length && res.data.list.length == self.search.pageSize ? 'loadmore' : 'nomore'
}
......
......@@ -2,7 +2,7 @@
<view class="com-content">
<complete-check :show="completeCheckStatus" :list-data="completeCheckResult" :pass="pass" @close="closeCheckResult" @handle="handerProgrom" @change="confirm"></complete-check>
<view class="u-wrap">
<u-navbar :background="{background: '#2272FF'}" back-icon-color="#fff" :title-size="32" title-color="#fff" :border-bottom="false" title="完工信息"></u-navbar>
<u-navbar :background="{background: '#2272FF'}" back-icon-color="#fff" :title-size="32" title-color="#fff" :border-bottom="false" title="完工信息" back-text=" " ></u-navbar>
<u-tabs-swiper class="order-tabs" ref="tabs" :current="tabIndex" name="panelName" :list="list" @change="tabsChange" :is-scroll="false" bg-color="#2272FF" inactive-color="#a6c6ff" active-color="#fff" height="80" font-size="32"></u-tabs-swiper>
<view class="u-menu-wrap">
<scroll-view scroll-y scroll-with-animation class="u-tab-view menu-scroll-view" :scroll-top="scrollTop" :scroll-into-view="itemId" v-if="list[tabIndex].items.length > 1">
......
<template>
<view class="order-wrap">
<u-navbar back-icon-color="#FFFFFF" :background="background" :border-bottom="false"></u-navbar>
<u-navbar back-icon-color="#FFFFFF" back-text=" " :background="background" :border-bottom="false"></u-navbar>
<view class="header">
<view class="title">订单信息</view>
<view v-show="allowRejection" class="button" @click="rejectOrder">拒单</view>
......@@ -126,7 +126,7 @@
<view>
<u-toast ref="uToast" />
</view>
<view v-if="showCenterBtn" @click="handleBtn" class="button" :class="['center-button-view', btnClass]">
<view v-if="showCenterBtn" @click="$u.throttle(handleBtn, 500)" class="button" :class="['center-button-view', btnClass]">
<text>{{ centerButtonText }}</text>
<view v-if="order.currentOverTime && showTimeOut" class="time-view">
<text style="padding-right: 8rpx;">{{order.currentOverTime > new Date().getTime()?'剩':'超'}}</text>
......@@ -151,7 +151,7 @@
</view>
<!-- 异常预约 ,现场拍照 这里是调用拍照的两个组件-->
<view class="right">
<view v-if="errorSignIn || scenePhoto" @click="$u.debounce(handleClickRight, 500)" :class="['button', {'active': scenePhoto}]">
<view v-if="errorSignIn || scenePhoto" @click="$u.throttle(handleClickRight, 500)" :class="['button', {'active': scenePhoto}]">
<text>{{errorSignIn ? '异常' : '拍照'}}</text>
</view>
......@@ -233,7 +233,8 @@
contactAddressLongitud:0,
contactAddressLatitud:0,
num:0,
showTimeOut:true
showTimeOut:true,
clicking: false,
}
},
onLoad(option) {
......@@ -610,8 +611,13 @@
}
return
}
if (this.clicking) {
return
}
this.clicking = true
this.$u.api[this.submitType](data, this.order.orderId).then(res => {
let self = this
this.clicking = false
if ((res.data.code!==undefined && res.data.code === 200)
|| (res.code!==undefined && res.code === 200) ) {
this.$refs.uToast.show({
......@@ -732,6 +738,7 @@
if(!currentOverTime){
return 0
}
console.log('--------', Math.round(Math.abs(this.order.currentOverTime - new Date().getTime()) / 1000))
return Math.round(Math.abs(this.order.currentOverTime - new Date().getTime()) / 1000);
},
timeOutChange(currentOverTime){
......@@ -858,7 +865,6 @@
}
.address-cell {
height: 24rpx;
font-size: 24rpx;
font-weight: 400;
color: #333333;
......
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