|
@@ -4,7 +4,7 @@
|
|
|
<view class="text-center text-red" v-if="isTrue && orderType == 2">超出配送距离</view>
|
|
<view class="text-center text-red" v-if="isTrue && orderType == 2">超出配送距离</view>
|
|
|
<view class="food">
|
|
<view class="food">
|
|
|
<view class="flex bg justify-between padding-lr-xl">
|
|
<view class="flex bg justify-between padding-lr-xl">
|
|
|
- <view @click="switchTab(2)" :class="orderType == 2 ? 'select' : ''" class="tabBtn" v-if="XCXIsSelect == '是' && showReach != 1 && shopTypeName!='三大运营商'">
|
|
|
|
|
|
|
+ <view @click="switchTab(2)" :class="orderType == 2 ? 'select' : ''" class="tabBtn" v-if="XCXIsSelect == '是' && showReach != 1 && shopTypeName != '三大运营商'">
|
|
|
<view class="title">外卖配送</view>
|
|
<view class="title">外卖配送</view>
|
|
|
<view :class="orderType == 2 ? 'active' : ''"></view>
|
|
<view :class="orderType == 2 ? 'active' : ''"></view>
|
|
|
</view>
|
|
</view>
|
|
@@ -27,9 +27,9 @@
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="flex margin-top" style="align-items: center;" v-if="shopTypeName=='三大运营商'">
|
|
|
|
|
|
|
+ <view class="flex margin-top" style="align-items: center" v-if="shopTypeName == '三大运营商'">
|
|
|
<view>请填写身份证号:</view>
|
|
<view>请填写身份证号:</view>
|
|
|
- <input type="idcard" v-model="idcard1" style="border: 1px solid;"/>
|
|
|
|
|
|
|
+ <input type="idcard" v-model="idcard1" style="border: 1px solid" />
|
|
|
</view>
|
|
</view>
|
|
|
<!-- 预约送达时间 -->
|
|
<!-- 预约送达时间 -->
|
|
|
<!-- <view class="goods_address" v-if="reservationOpenFlag==1">
|
|
<!-- <view class="goods_address" v-if="reservationOpenFlag==1">
|
|
@@ -112,6 +112,10 @@
|
|
|
<view>跑腿费</view>
|
|
<view>跑腿费</view>
|
|
|
<view class="tosend_header_do_ri">¥{{ paotuiMoney }}</view>
|
|
<view class="tosend_header_do_ri">¥{{ paotuiMoney }}</view>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
+ <view class="tosend_header_do justify-between" v-if="address.insideDeliveryFee && orderType == 2">
|
|
|
|
|
+ <view>特殊地址跑腿费</view>
|
|
|
|
|
+ <view class="tosend_header_do_ri">¥{{ address.insideDeliveryFee }}</view>
|
|
|
|
|
+ </view>
|
|
|
<view class="tosend_header_do justify-between do_bot" @click="isShow">
|
|
<view class="tosend_header_do justify-between do_bot" @click="isShow">
|
|
|
<view>优惠券</view>
|
|
<view>优惠券</view>
|
|
|
<view class="tosend_header_do_ri" v-if="coupon">- ¥{{ coupon.money }}</view>
|
|
<view class="tosend_header_do_ri" v-if="coupon">- ¥{{ coupon.money }}</view>
|
|
@@ -328,7 +332,9 @@ export default {
|
|
|
packMoney: 0, //打包费
|
|
packMoney: 0, //打包费
|
|
|
totalPrice: 0,
|
|
totalPrice: 0,
|
|
|
totalPrice1: 0,
|
|
totalPrice1: 0,
|
|
|
- address: {}, //地址
|
|
|
|
|
|
|
+ address: {
|
|
|
|
|
+ insideDeliveryFee: 0
|
|
|
|
|
+ }, //地址
|
|
|
addressId: '',
|
|
addressId: '',
|
|
|
parentId: '',
|
|
parentId: '',
|
|
|
shopId: '',
|
|
shopId: '',
|
|
@@ -383,13 +389,13 @@ export default {
|
|
|
intergral: 0,
|
|
intergral: 0,
|
|
|
// 是否显示积分模块
|
|
// 是否显示积分模块
|
|
|
isIntegral: false,
|
|
isIntegral: false,
|
|
|
- shopTypeName:'',//店铺类型
|
|
|
|
|
- idcard1:'',//身份证号
|
|
|
|
|
|
|
+ shopTypeName: '', //店铺类型
|
|
|
|
|
+ idcard1: '' //身份证号
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
onLoad(option) {
|
|
onLoad(option) {
|
|
|
console.log(option, '256')
|
|
console.log(option, '256')
|
|
|
- this.shopTypeName=option.shopTypeName
|
|
|
|
|
|
|
+ this.shopTypeName = option.shopTypeName
|
|
|
if (option.showReach) {
|
|
if (option.showReach) {
|
|
|
this.showReach = option.showReach
|
|
this.showReach = option.showReach
|
|
|
}
|
|
}
|
|
@@ -450,9 +456,9 @@ export default {
|
|
|
// #endif
|
|
// #endif
|
|
|
|
|
|
|
|
this.shopId = option.shopId
|
|
this.shopId = option.shopId
|
|
|
- if(option.shopTypeName=='三大运营商'){
|
|
|
|
|
- this.orderType =1
|
|
|
|
|
- }else{
|
|
|
|
|
|
|
+ if (option.shopTypeName == '三大运营商') {
|
|
|
|
|
+ this.orderType = 1
|
|
|
|
|
+ } else {
|
|
|
this.orderType = option.orderType
|
|
this.orderType = option.orderType
|
|
|
}
|
|
}
|
|
|
if (option.orderId) {
|
|
if (option.orderId) {
|
|
@@ -832,7 +838,7 @@ export default {
|
|
|
this.getDistance()
|
|
this.getDistance()
|
|
|
}
|
|
}
|
|
|
if (this.orderType == 2) {
|
|
if (this.orderType == 2) {
|
|
|
- this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.paotuiMoney) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
|
|
|
|
|
+ this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.paotuiMoney) + parseFloat(this.dabaoMoney) + this.address.insideDeliveryFee).toFixed(2)
|
|
|
} else {
|
|
} else {
|
|
|
this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
|
}
|
|
}
|
|
@@ -872,7 +878,7 @@ export default {
|
|
|
selCoupon(item) {
|
|
selCoupon(item) {
|
|
|
this.coupon = item
|
|
this.coupon = item
|
|
|
if (this.orderType == 2) {
|
|
if (this.orderType == 2) {
|
|
|
- this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney).toFixed(2)
|
|
|
|
|
|
|
+ this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney + this.address.insideDeliveryFee).toFixed(2)
|
|
|
} else {
|
|
} else {
|
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
|
}
|
|
}
|
|
@@ -899,7 +905,7 @@ export default {
|
|
|
selctHuo(item) {
|
|
selctHuo(item) {
|
|
|
this.huodong = item
|
|
this.huodong = item
|
|
|
if (this.orderType == 2) {
|
|
if (this.orderType == 2) {
|
|
|
- this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney).toFixed(2)
|
|
|
|
|
|
|
+ this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney + this.address.insideDeliveryFee).toFixed(2)
|
|
|
} else {
|
|
} else {
|
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
|
}
|
|
}
|
|
@@ -934,7 +940,7 @@ export default {
|
|
|
if (!activityExists) {
|
|
if (!activityExists) {
|
|
|
this.coupon = ''
|
|
this.coupon = ''
|
|
|
if (this.orderType == 2) {
|
|
if (this.orderType == 2) {
|
|
|
- this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney).toFixed(2)
|
|
|
|
|
|
|
+ this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney + this.address.insideDeliveryFee).toFixed(2)
|
|
|
} else {
|
|
} else {
|
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
|
}
|
|
}
|
|
@@ -979,7 +985,7 @@ export default {
|
|
|
if (!activityExists) {
|
|
if (!activityExists) {
|
|
|
this.huodong = ''
|
|
this.huodong = ''
|
|
|
if (this.orderType == 2) {
|
|
if (this.orderType == 2) {
|
|
|
- this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney).toFixed(2)
|
|
|
|
|
|
|
+ this.totalPrice1 = parseFloat(this.totalPrice + this.paotuiMoney + this.dabaoMoney + this.address.insideDeliveryFee).toFixed(2)
|
|
|
} else {
|
|
} else {
|
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
this.totalPrice1 = parseFloat(this.totalPrice + this.dabaoMoney).toFixed(2)
|
|
|
}
|
|
}
|
|
@@ -1064,9 +1070,9 @@ export default {
|
|
|
limit: 1000
|
|
limit: 1000
|
|
|
// orderType: this.orderType
|
|
// orderType: this.orderType
|
|
|
}
|
|
}
|
|
|
- console.log(data)
|
|
|
|
|
|
|
+ // console.log(data)
|
|
|
this.$Request.get('/app/order/selectAllOrderList', data).then((res) => {
|
|
this.$Request.get('/app/order/selectAllOrderList', data).then((res) => {
|
|
|
- console.log(res)
|
|
|
|
|
|
|
+ // console.log(res)
|
|
|
uni.hideLoading()
|
|
uni.hideLoading()
|
|
|
if (res.code == 0 && res.data.pageUtils.list.length) {
|
|
if (res.code == 0 && res.data.pageUtils.list.length) {
|
|
|
this.GoodsorderId = res.data.pageUtils.list[0].orderId
|
|
this.GoodsorderId = res.data.pageUtils.list[0].orderId
|
|
@@ -1097,7 +1103,9 @@ export default {
|
|
|
|
|
|
|
|
this.totalPrice = res.data.money
|
|
this.totalPrice = res.data.money
|
|
|
if (this.orderType == 2) {
|
|
if (this.orderType == 2) {
|
|
|
- this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.paotuiMoney) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
|
|
|
|
|
+ this.totalPrice1 = parseFloat(
|
|
|
|
|
+ parseFloat(this.totalPrice) + parseFloat(this.paotuiMoney) + parseFloat(this.dabaoMoney) + this.address.insideDeliveryFee
|
|
|
|
|
+ ).toFixed(2)
|
|
|
} else {
|
|
} else {
|
|
|
this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
|
}
|
|
}
|
|
@@ -1151,7 +1159,9 @@ export default {
|
|
|
|
|
|
|
|
this.totalPrice = res.data.money
|
|
this.totalPrice = res.data.money
|
|
|
if (this.orderType == 2) {
|
|
if (this.orderType == 2) {
|
|
|
- this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.paotuiMoney) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
|
|
|
|
|
+ this.totalPrice1 = parseFloat(
|
|
|
|
|
+ parseFloat(this.totalPrice) + parseFloat(this.paotuiMoney) + parseFloat(this.dabaoMoney) + this.address.insideDeliveryFee
|
|
|
|
|
+ ).toFixed(2)
|
|
|
} else {
|
|
} else {
|
|
|
this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
this.totalPrice1 = parseFloat(parseFloat(this.totalPrice) + parseFloat(this.dabaoMoney)).toFixed(2)
|
|
|
}
|
|
}
|
|
@@ -1293,9 +1303,9 @@ export default {
|
|
|
addressId: this.address.addressId ? this.address.addressId : '',
|
|
addressId: this.address.addressId ? this.address.addressId : '',
|
|
|
orderType: this.orderType,
|
|
orderType: this.orderType,
|
|
|
type: res.enable ? 1 : 3,
|
|
type: res.enable ? 1 : 3,
|
|
|
- idCard:this.idcard1
|
|
|
|
|
|
|
+ idCard: this.idcard1
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
console.log(data)
|
|
console.log(data)
|
|
|
if (res.enable) {
|
|
if (res.enable) {
|
|
|
console.log('xin')
|
|
console.log('xin')
|
|
@@ -1553,6 +1563,8 @@ export default {
|
|
|
this.$Request.get('/app/address/selectAddressById', data).then((res) => {
|
|
this.$Request.get('/app/address/selectAddressById', data).then((res) => {
|
|
|
if (res.code == 0) {
|
|
if (res.code == 0) {
|
|
|
this.address = res.data
|
|
this.address = res.data
|
|
|
|
|
+
|
|
|
|
|
+ this.getInsideDeliveryFee(this.address.insideAddressId)
|
|
|
if (JSON.stringify(this.address) != '{}') {
|
|
if (JSON.stringify(this.address) != '{}') {
|
|
|
this.getDistance()
|
|
this.getDistance()
|
|
|
}
|
|
}
|
|
@@ -1576,12 +1588,24 @@ export default {
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
|
|
|
|
|
|
|
+ // console.log(that.address, '我的地址列表460777')
|
|
|
|
|
+
|
|
|
|
|
+ this.getInsideDeliveryFee(this.address.insideAddressId)
|
|
|
|
|
+
|
|
|
if (JSON.stringify(this.address) != '{}') {
|
|
if (JSON.stringify(this.address) != '{}') {
|
|
|
this.getDistance()
|
|
this.getDistance()
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
|
|
+ getInsideDeliveryFee(insideAddressId) {
|
|
|
|
|
+ this.$Request.get(`/app/inside-address/${insideAddressId}`).then((res) => {
|
|
|
|
|
+ // console.log(res, 987456)
|
|
|
|
|
+ if (res.code == 0) {
|
|
|
|
|
+ this.address.insideDeliveryFee = res.data.deliveryFee
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
goAddress() {
|
|
goAddress() {
|
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
|
url: '/my/address/index?add=1'
|
|
url: '/my/address/index?add=1'
|