|
|
@ -5,16 +5,6 @@ |
|
|
<view style="position: relative;height: 545rpx;"> |
|
|
<view style="position: relative;height: 545rpx;"> |
|
|
<view style="width:100%;height: 260rpx;position: fixed;top: 0;background: url('https://jewel-shop.oss-cn-beijing.aliyuncs.com/8bc15960c2dc40268e295d6dd23aecce.png') no-repeat;z-index: 90;" |
|
|
<view style="width:100%;height: 260rpx;position: fixed;top: 0;background: url('https://jewel-shop.oss-cn-beijing.aliyuncs.com/8bc15960c2dc40268e295d6dd23aecce.png') no-repeat;z-index: 90;" |
|
|
v-if="lastScrollTop>583"></view> |
|
|
v-if="lastScrollTop>583"></view> |
|
|
<!-- <view style="position: absolute;top: 110rpx;left: 20rpx;z-index: 999;"> |
|
|
|
|
|
<view @click="checkArea" v-if="areaName == ''"> |
|
|
|
|
|
点击选择区域 |
|
|
|
|
|
<uni-icons type="right" size="12" style="margin-left: 10rpx;"></uni-icons> |
|
|
|
|
|
</view> |
|
|
|
|
|
<view @click="checkArea" v-else> |
|
|
|
|
|
{{areaName}} |
|
|
|
|
|
<uni-icons type="right" size="12" style="margin-left: 10rpx;"></uni-icons> |
|
|
|
|
|
</view> |
|
|
|
|
|
</view> --> |
|
|
|
|
|
<view class="campus-hero campus-hero--ad"> |
|
|
<view class="campus-hero campus-hero--ad"> |
|
|
<swiper class="swiper hero-bg-swiper" circular :indicator-dots="indicatorDots" :autoplay="autoplay" |
|
|
<swiper class="swiper hero-bg-swiper" circular :indicator-dots="indicatorDots" :autoplay="autoplay" |
|
|
:interval="interval" :duration="duration"> |
|
|
:interval="interval" :duration="duration"> |
|
|
@ -974,6 +964,7 @@ |
|
|
isSwipeOrderActive(item, index) { |
|
|
isSwipeOrderActive(item, index) { |
|
|
return this.swipeOrder.id === item.id && this.swipeOrder.index === index && this.swipeOrder.progress > 0 |
|
|
return this.swipeOrder.id === item.id && this.swipeOrder.index === index && this.swipeOrder.progress > 0 |
|
|
}, |
|
|
}, |
|
|
|
|
|
//滑动开始 |
|
|
startSwipeOrder(event, item, index) { |
|
|
startSwipeOrder(event, item, index) { |
|
|
const touch = event.touches && event.touches[0] |
|
|
const touch = event.touches && event.touches[0] |
|
|
if (!touch) return |
|
|
if (!touch) return |
|
|
@ -1004,6 +995,7 @@ |
|
|
const progress = Math.min(100, Math.round(deltaX / (trackWidth * 0.72) * 100)) |
|
|
const progress = Math.min(100, Math.round(deltaX / (trackWidth * 0.72) * 100)) |
|
|
this.setSwipeOrderProgress(progress) |
|
|
this.setSwipeOrderProgress(progress) |
|
|
}, |
|
|
}, |
|
|
|
|
|
//滑动结束 |
|
|
endSwipeOrder(item, index) { |
|
|
endSwipeOrder(item, index) { |
|
|
if (this.swipeOrder.id !== item.id || this.swipeOrder.index !== index) return |
|
|
if (this.swipeOrder.id !== item.id || this.swipeOrder.index !== index) return |
|
|
if (this.swipeOrder.progress >= 92 && !this.swipeOrder.confirmed) { |
|
|
if (this.swipeOrder.progress >= 92 && !this.swipeOrder.confirmed) { |
|
|
@ -1174,6 +1166,7 @@ |
|
|
uni.hideLoading(); |
|
|
uni.hideLoading(); |
|
|
}).catch((res) => {}); |
|
|
}).catch((res) => {}); |
|
|
}, |
|
|
}, |
|
|
|
|
|
//广告跳转 |
|
|
goAdPage(item) { |
|
|
goAdPage(item) { |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: item.linkUrl + item.linkParams |
|
|
url: item.linkUrl + item.linkParams |
|
|
@ -1208,6 +1201,7 @@ |
|
|
url: '/package2/seckill/seckillGroup' |
|
|
url: '/package2/seckill/seckillGroup' |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
//跳转到子页面 |
|
|
goDetail(type) { |
|
|
goDetail(type) { |
|
|
let url = '' |
|
|
let url = '' |
|
|
switch (type) { |
|
|
switch (type) { |
|
|
@ -1231,11 +1225,13 @@ |
|
|
url: url |
|
|
url: url |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
//跳转到订单详情 |
|
|
goOrderDetail(item) { |
|
|
goOrderDetail(item) { |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
url: '/package1/order/orderDetail?id=' + item.id |
|
|
url: '/package1/order/orderDetail?id=' + item.id |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
|
|
|
//选择区域 |
|
|
onClickArea(item) { |
|
|
onClickArea(item) { |
|
|
uni.setStorageSync('area', JSON.stringify(item)) |
|
|
uni.setStorageSync('area', JSON.stringify(item)) |
|
|
this.areaName = item.title |
|
|
this.areaName = item.title |
|
|
@ -1272,6 +1268,7 @@ |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
//获取筛选条件列表 |
|
|
getShopArea() { |
|
|
getShopArea() { |
|
|
let that = this |
|
|
let that = this |
|
|
that.tui.request("/app/shopArea/getByParentId/" + that.searchForm.regionId, "GET", {}, false, true).then(( |
|
|
that.tui.request("/app/shopArea/getByParentId/" + that.searchForm.regionId, "GET", {}, false, true).then(( |
|
|
@ -1287,6 +1284,7 @@ |
|
|
} |
|
|
} |
|
|
}).catch((res) => {}) |
|
|
}).catch((res) => {}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
//获取用户当前未完成订单 |
|
|
getUserOrders() { |
|
|
getUserOrders() { |
|
|
let that = this |
|
|
let that = this |
|
|
that.tui.request("/mall/order/getOrdersByUserId/" + uni.getStorageSync('id'), "GET", {}, false, true).then( |
|
|
that.tui.request("/mall/order/getOrdersByUserId/" + uni.getStorageSync('id'), "GET", {}, false, true).then( |
|
|
@ -1302,6 +1300,7 @@ |
|
|
} |
|
|
} |
|
|
}).catch((res) => {}) |
|
|
}).catch((res) => {}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
//点击下拉框中某一条筛选条件 |
|
|
searchOrder(type, value) { |
|
|
searchOrder(type, value) { |
|
|
if (type == 'getarea') { |
|
|
if (type == 'getarea') { |
|
|
if (this.searchForm.getAreaId == value.id) { |
|
|
if (this.searchForm.getAreaId == value.id) { |
|
|
@ -1358,6 +1357,7 @@ |
|
|
fail: (err) => {} |
|
|
fail: (err) => {} |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
|
|
|
//配送单列表切换 |
|
|
checkTab1(type) { |
|
|
checkTab1(type) { |
|
|
this.checked = type |
|
|
this.checked = type |
|
|
if (type == 'waimai') { |
|
|
if (type == 'waimai') { |
|
|
@ -1395,6 +1395,7 @@ |
|
|
}); |
|
|
}); |
|
|
}).exec(); |
|
|
}).exec(); |
|
|
}, |
|
|
}, |
|
|
|
|
|
//拨打电话 |
|
|
makeCall(phone) { |
|
|
makeCall(phone) { |
|
|
uni.makePhoneCall({ |
|
|
uni.makePhoneCall({ |
|
|
phoneNumber: phone |
|
|
phoneNumber: phone |
|
|
@ -1406,9 +1407,11 @@ |
|
|
clearInterval(this.deliveryTimer); |
|
|
clearInterval(this.deliveryTimer); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
//筛选条件 |
|
|
checkAdd() { |
|
|
checkAdd() { |
|
|
this.isgetArea = !this.isgetArea |
|
|
this.isgetArea = !this.isgetArea |
|
|
}, |
|
|
}, |
|
|
|
|
|
//筛选条件 |
|
|
checkAdd1() { |
|
|
checkAdd1() { |
|
|
this.isputArea = !this.isputArea |
|
|
this.isputArea = !this.isputArea |
|
|
}, |
|
|
}, |
|
|
|