deming/pageE/tool/SendWash.vue

238 lines
5.1 KiB
Vue
Raw Normal View History

2020-06-04 00:21:34 +00:00
<template>
<view class="wash">
2020-07-27 01:36:59 +00:00
<view class="title">
2020-06-04 00:21:34 +00:00
<u-tabs-swiper ref="tabs" :list="list" :is-scroll="false" active-color="#FF780F" :current="current" font-size="32" :show-bar="false" @change="tabsChange" height="88" ></u-tabs-swiper>
</view>
<swiper :current="swiperCurrent" @animationfinish="animationfinish">
<swiper-item class="swiper-item">
<scroll-view scroll-y class="order-list">
2020-06-08 07:23:23 +00:00
<view v-for="(item, index) in 6" :key="index" class="order-item">
2020-06-04 00:21:34 +00:00
<view class="order-title">
<view class="order-text">订单状态</view>
<view class="order-status">已预约</view>
</view>
<view class="order-info">
<image src="../static/mine/23.png"></image>
<view>
<view>骑手名字xxx</view>
<view>联系方式123456789</view>
<view>所属公司xx公司</view>
</view>
</view>
2020-07-27 01:36:59 +00:00
<view class="send-btn">
<view class="btn" v-if="btn_show">
确认完成
</view>
</view>
2020-06-04 00:21:34 +00:00
</view>
</scroll-view>
</swiper-item>
<swiper-item class="swiper-item">
2020-06-08 07:23:23 +00:00
<scroll-view scroll-y style="height: 100%;" class="none-page">
2020-06-04 00:21:34 +00:00
<view></view>
</scroll-view>
</swiper-item>
<swiper-item class="swiper-item">
2020-06-08 07:23:23 +00:00
<scroll-view scroll-y class="comment">
<view v-for="(item, index) in 3" :key="index" class="comment-item">
<Comment></Comment>
</view>
2020-06-04 00:21:34 +00:00
</scroll-view>
</swiper-item>
</swiper>
2020-07-27 01:36:59 +00:00
<view class="popup" v-if="showPopup" @click="onTap">
<view class="popup_cont" @click="replaces(1)">
实体店历史订单
</view>
<view class="popup_cont" @click="replaces(2)">
平台历史订单
</view>
</view>
2020-06-04 00:21:34 +00:00
</view>
</template>
<script>
2020-06-08 07:23:23 +00:00
import Comment from '@/components/mine/comment/index'
2020-06-04 00:21:34 +00:00
export default {
data() {
return {
2020-07-27 01:36:59 +00:00
showPopup: false,
2020-06-04 00:21:34 +00:00
list: [{
2020-07-27 01:36:59 +00:00
name: '平台历史订单'
2020-06-04 00:21:34 +00:00
}, {
name: '申请表'
}, {
name: '评价'
}],
current: 0,
2020-07-27 01:36:59 +00:00
swiperCurrent: 0,
btn_show:true
2020-06-04 00:21:34 +00:00
}
},
2020-06-08 07:23:23 +00:00
components: {
Comment
},
2020-06-04 00:21:34 +00:00
onShow() {
this.current = 0;
this.swiperCurrent = 0;
2020-07-27 01:36:59 +00:00
this.showPopup= false
2020-06-04 00:21:34 +00:00
},
methods: {
tabsChange(index) {
this.swiperCurrent = index;
this.toApplyPage(index);
},
animationfinish(e) {
let current = e.detail.current;
this.swiperCurrent = current;
this.current = current;
this.toApplyPage(current);
},
toApplyPage(index) {
2020-07-27 01:36:59 +00:00
console.log(index)
var that = this;
2020-06-08 07:23:23 +00:00
if(index == 1) {
2020-07-27 01:36:59 +00:00
this.showPopup = false
2020-06-08 07:23:23 +00:00
uni.navigateTo({
url: '/pageE/tool/WashOrder'
});
2020-07-27 01:36:59 +00:00
}else if(index ==0){
this.history();
}else{
this.showPopup = false
2020-06-08 07:23:23 +00:00
}
2020-07-27 01:36:59 +00:00
},
history(){
this.showPopup = true;
},
replaces(e){
if(e == 1){
this.$set(this.list,0,{name: '实体店历史订单'} )
}else{
this.$set(this.list,0,{name: '平台历史订单'} )
}
},
onTap(){
this.showPopup = false
2020-06-04 00:21:34 +00:00
}
},
};
</script>
<style lang="scss" scoped>
.wash {
min-height: calc(100vh - var(--window-top));
background-color: #ECECEC;
display: flex;
flex-direction: column;
> uni-swiper {
flex: 1;
2020-07-27 01:36:59 +00:00
height: 85vh;
}
.title{
2020-06-04 00:21:34 +00:00
}
.swiper-item {
2020-06-08 07:23:23 +00:00
padding-top: 20rpx;
2020-06-04 00:21:34 +00:00
.order-list {
2020-06-08 07:23:23 +00:00
width: 100%;
height: 100%;
box-sizing: border-box;
padding: 0 30rpx;
2020-06-04 00:21:34 +00:00
.order-item {
padding: 30rpx;
width:690rpx;
2020-07-27 01:36:59 +00:00
height: 362rpx;
2020-06-04 00:21:34 +00:00
background: rgba(255,255,255,1);
border-radius: 10rpx;
margin-bottom: 20rpx;
.order-title {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 30rpx;
.order-text {
font-size: 30rpx;
color: rgba(51,51,51,1);
}
.order-status {
font-size: 28rpx;
color: rgba(255,120,15,1);
}
}
.order-info {
display: flex;
align-items: center;
> image {
width: 180rpx;
height: 160rpx;
border-radius: 10rpx;
margin-right: 30rpx;
}
> view {
font-size: 26rpx;
color: rgba(51,51,51,1);
> view:not(:last-child) {
margin-bottom: 19rpx;
}
}
}
2020-07-27 01:36:59 +00:00
.send-btn{
width: 100%;
display: flex;
justify-content: flex-end;
margin-top: 30rpx;
.btn{
width: 154rpx;
height: 54rpx;
background: RGBA(255, 254, 255, 1);
border-radius: 49rpx;
transform: translate(-50%, 0);
font-size: 26rpx;
border: 1rpx solid rgba(255,120,15,1);
color:rgba(255,120,15,1);
text-align: center;
line-height: 54rpx;
margin-right: -80rpx;
}
}
2020-06-04 00:21:34 +00:00
}
}
2020-06-08 07:23:23 +00:00
.comment {
width: 100%;
height: 100%;
.comment-item {
margin-bottom: 20rpx;
}
}
2020-06-04 00:21:34 +00:00
}
2020-07-27 01:36:59 +00:00
.popup{
width: 100%;
height: 100%;
position: fixed;
bottom: 0;
top: 88px;
left: 0;
right: 0;
z-index: 2;
background-color: rgba(0, 0, 0, 0.4);
transform: scale(1);
display: flex;
flex-direction: column;
justify-content: top;
align-items: center;
transition-duration: 0.3s;
.popup_cont{
border-top: 1px solid RGBA(239, 236, 240, 1);
background-color: #fff;
width: 100%;
height: 80rpx;
line-height: 80rpx;
font-size:28rpx;
font-family:PingFang SC;
font-weight:400;
color:rgba(102,102,102,1);
padding-left: 41rpx;
}
}
2020-06-04 00:21:34 +00:00
}
</style>