trade:新增是否自提的配置项
parent
d3c114325b
commit
7be4e398f3
|
@ -1,6 +1,6 @@
|
||||||
import request from "@/utils/request.js";
|
import request from "@/utils/request.js";
|
||||||
|
|
||||||
// 获得配送配置
|
// 获得交易配置
|
||||||
export function getTradeConfig() {
|
export function getTradeConfig() {
|
||||||
return request.get("app-api/trade/config/get");
|
return request.get("app-api/trade/config/get");
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
</div>
|
</div>
|
||||||
<div class="store-distance" @click.stop="showMaoLocation(item)">
|
<div class="store-distance" @click.stop="showMaoLocation(item)">
|
||||||
<span class="addressTxt" v-if="item.distance">距离{{ item.distance / 1000.0 }}千米</span>
|
<span class="addressTxt" v-if="item.distance">距离{{ item.distance.toFixed(2) }}千米</span>
|
||||||
<span class="addressTxt" v-else>查看地图</span>
|
<span class="addressTxt" v-else>查看地图</span>
|
||||||
<span class="iconfont icon-youjian" />
|
<span class="iconfont icon-youjian" />
|
||||||
</div>
|
</div>
|
||||||
|
@ -136,7 +136,7 @@
|
||||||
latitude: Number(e.latitude),
|
latitude: Number(e.latitude),
|
||||||
longitude: Number(e.longitude),
|
longitude: Number(e.longitude),
|
||||||
name: e.name,
|
name: e.name,
|
||||||
address: `${e.address}-${e.detailedAddress}`,
|
address: `${e.areaName}-${e.detailAddress}`,
|
||||||
success: function() {
|
success: function() {
|
||||||
console.log('success');
|
console.log('success');
|
||||||
}
|
}
|
||||||
|
|
|
@ -159,6 +159,7 @@
|
||||||
<script>
|
<script>
|
||||||
import * as CouponApi from '@/api/promotion/coupon.js';
|
import * as CouponApi from '@/api/promotion/coupon.js';
|
||||||
import * as OrderApi from '@/api/trade/order.js';
|
import * as OrderApi from '@/api/trade/order.js';
|
||||||
|
import * as ConfigApi from '@/api/trade/config.js';
|
||||||
import { openPaySubscribe } from '@/utils/SubscribeMessage.js';
|
import { openPaySubscribe } from '@/utils/SubscribeMessage.js';
|
||||||
import * as DeliveryApi from '@/api/trade/delivery.js';
|
import * as DeliveryApi from '@/api/trade/delivery.js';
|
||||||
import couponListWindow from '@/components/couponListWindow';
|
import couponListWindow from '@/components/couponListWindow';
|
||||||
|
@ -168,6 +169,7 @@
|
||||||
import { toLogin } from '@/libs/login.js';
|
import { toLogin } from '@/libs/login.js';
|
||||||
import { mapGetters } from "vuex";
|
import { mapGetters } from "vuex";
|
||||||
import * as Util from '@/utils/util.js';
|
import * as Util from '@/utils/util.js';
|
||||||
|
import {getTradeConfig} from "../../../api/trade/config";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
couponListWindow,
|
couponListWindow,
|
||||||
|
@ -253,8 +255,8 @@
|
||||||
// 处理 address 地址
|
// 处理 address 地址
|
||||||
this.addressId = options.addressId || 0;
|
this.addressId = options.addressId || 0;
|
||||||
// 获得门店自提是否开启
|
// 获得门店自提是否开启
|
||||||
DeliveryApi.getDeliveryConfig().then(res => {
|
ConfigApi.getTradeConfig().then(res => {
|
||||||
this.store_self_mention = res.data.pickUpEnable && this.productType === 'normal';
|
this.store_self_mention = res.data.deliveryPickUpEnabled && this.productType === 'normal';
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue