|
@@ -151,14 +151,14 @@
|
|
|
</el-form>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div v-if="ifMapReload && center.data.lat != ''">
|
|
|
+ <div v-if="ifMapReload && center.lat && center.lng">
|
|
|
<GoogleMap
|
|
|
api-key="AIzaSyAvTVnnDLfxdaK2i-f0pRMJOrdwZvxUBjU"
|
|
|
style="width: 100%; height: 500px"
|
|
|
- :center="center.data"
|
|
|
+ :center="center"
|
|
|
:zoom="5"
|
|
|
>
|
|
|
- <Marker :options="{ position: center.data }" />
|
|
|
+ <Marker :options="{ position: center }" />
|
|
|
</GoogleMap>
|
|
|
|
|
|
</div>
|
|
@@ -184,7 +184,7 @@ import { getCurLanguage } from '@/composables/common.js';
|
|
|
import { getContactType } from "@/utils/common";
|
|
|
|
|
|
const L = getCurLanguage();
|
|
|
-const center = reactive({data:{ lat: 0, lng: 0 }})
|
|
|
+const center = reactive({lat: '', lng: '' })
|
|
|
const address = ref()
|
|
|
const email = ref()
|
|
|
const phone = ref()
|
|
@@ -360,8 +360,8 @@ const getMapInfo = () => {
|
|
|
address.value = res.data.address
|
|
|
email.value = res.data.email
|
|
|
phone.value = res.data.servicePhone
|
|
|
- center.data.lat = Number(res.data.storeMapInfo)
|
|
|
- center.data.lng = Number(res.data.storeMapInfoW)
|
|
|
+ center.lat = Number(res.data.storeMapInfo)
|
|
|
+ center.lng = Number(res.data.storeMapInfoW)
|
|
|
ifMapReload.value =true
|
|
|
})
|
|
|
|