Commit 570d559a authored by 肖健's avatar 肖健

免费挪车牌下单的提示添加

parent dab0ec64
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<div class="get__content"> <div class="get__content">
<div class="address" v-if="addressShow"> <div class="address" v-if="addressShow">
<div class="address__left"> <div class="address__left">
<div class="right__title" @click="geMap"> <div class="right__title">
{{addressInfo.address}}&emsp;{{addressInfo.detailInfo}} {{addressInfo.address}}&emsp;{{addressInfo.detailInfo}}
</div> </div>
<div class="right__phone"> <div class="right__phone">
...@@ -162,16 +162,13 @@ export default { ...@@ -162,16 +162,13 @@ export default {
} }
}, },
methods: { methods: {
getMap() {
uni.getLocation({
type: 'wgs84',
success: function (res) {
//console.log('当前位置的经度:' + res.longitude);
//console.log('当前位置的纬度:' + res.latitude);
}
});
},
pay() { pay() {
if(!this.addressId) {
uni.showToast({
title:'请添加一个收货地址',
icon:'none',
})
} else {
let list = [{ let list = [{
id: this.freeCode.id, id: this.freeCode.id,
nums: 1, nums: 1,
...@@ -192,6 +189,7 @@ export default { ...@@ -192,6 +189,7 @@ export default {
this.http.httpTokenRequest(opts, this.createOrder).then(res => { this.http.httpTokenRequest(opts, this.createOrder).then(res => {
if (res.data.code == 200) { if (res.data.code == 200) {
let orderIds = res.data.data let orderIds = res.data.data
if(orderIds && orderIds.length > 0) {
that.orderSubmit = { that.orderSubmit = {
appId: 6, appId: 6,
ids: orderIds, ids: orderIds,
...@@ -221,8 +219,20 @@ export default { ...@@ -221,8 +219,20 @@ export default {
} }
}) })
} else {
uni.navigateTo({
url: '/pagesC/pages/shop/payOk'
})
} }
} else {
uni.showToast({
title: res.data.msg,
icon:'none',
}) })
}
})
}
}, },
add(){ add(){
this.nums++ this.nums++
......
...@@ -156,7 +156,6 @@ export default { ...@@ -156,7 +156,6 @@ export default {
that.$nextTick(() => { that.$nextTick(() => {
that.model1.carInfo = res.data.data; that.model1.carInfo = res.data.data;
that.model1.carInfo.carNo = res.data.data.carNo; that.model1.carInfo.carNo = res.data.data.carNo;
console.log(that.model1.carInfo)
that.$set(that.model1.carInfo, 'carNo', res.data.data.carNo); that.$set(that.model1.carInfo, 'carNo', res.data.data.carNo);
}) })
} }
......
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