{{ (item.distance / 1000)?.toFixed(2)
- }}km
+ }}km
@@ -85,10 +85,38 @@ export default {
}
},
async mounted() {
- const res = await this.$geo.getWebGeo();
- this.searchparams.latitude = res.lat;
- this.searchparams.longitude = res.lon;
this.init();
+
+ if (wx && this.$isWechat()) {
+ this.$post('/v1/client/HWxinfoClient/share', JSON.stringify(location.href)).then(res => {
+ const data = res.data || {};
+ const jsApiList = data.jsApiList || ['onMenuShareTimeline', 'onMenuShareAppMessage', 'updateAppMessageShareData', 'updateTimelineShareData', 'openLocation', 'getLocation'];
+ const openTagList = data.openTagList || ['wx-open-launch-weapp'];
+ jsApiList.push('wx-open-launch-weapp');
+ wx.config({
+ debug: false,
+ appId: data.appid,
+ timestamp: Number(data.timestamp) || 0,
+ nonceStr: data.noncestr,
+ signature: data.signature,
+ jsApiList: jsApiList,
+ openTagList: openTagList
+ });
+ wx.ready(() => {
+ wx.getLocation({
+ type: 'gcj02',
+ success: (e) => {
+ this.searchparams.latitude = e.latitude;
+ this.searchparams.longitude = e.longitude;
+ }
+ });
+ });
+ });
+ } else {
+ const res = await this.$geo.getWebGeo();
+ this.searchparams.latitude = res.lat;
+ this.searchparams.longitude = res.lon;
+ }
this.$nextTick(() => {
this.checkScroll();
const ro = new ResizeObserver(() => this.checkScroll());
diff --git a/src/views/User/Checkout/Checkout.vue b/src/views/User/Checkout/Checkout.vue
index bb5a769..88ba8fe 100644
--- a/src/views/User/Checkout/Checkout.vue
+++ b/src/views/User/Checkout/Checkout.vue
@@ -1,64 +1,71 @@
- {{ data.shop.feeratio }}%
+
+
+ {{ data.shop.feeratio }}%
+ - 实付 -
- ¥{{ actualPay.toFixed(2) }} ++ 实付 +
+ ¥{{ actualPay.toFixed(2) }} +