Browse Source

feat: 公共设施:数据取自地图编辑器,展示所有的公共设施ICON,点击跳转找店页面,直接导航到离当前位置最近的公共设施;

v1.0.1
jiannibang 3 years ago
parent
commit
ddf4a9ce9b
  1. 6
      src/composables/useInitConfigAndMallInfo.js
  2. 9
      src/http/api.js
  3. 7
      src/views/Guide/Guide.vue

6
src/composables/useInitConfigAndMallInfo.js

@ -1,4 +1,4 @@
import { getConfig, getCurrentFloor, getGuideList, getTheme, getIndexList, getQMGoShopData } from '@/http/api'
import { getConfig, getCurrentFloor, getGuideList, getTheme, getQMGoShopData } from '@/http/api'
import { useStore } from '@/store/root'
import VConsole from 'vconsole'
@ -27,10 +27,8 @@ export const useInitConfigAndMallInfo = async () => {
const { buildingList, shopList } = _guideList.data
store.SET_SHOP_LIST(shopList.filter(({ yaxis }) => !!yaxis))
store.SET_BUILDING_LIST(buildingList)
const res = await getIndexList()
const { data } = res
const {
data: { searchList, recommendList }
} = await getQMGoShopData()
store.SET_INDEX_LIST({ ...data, recommendList, hotSearch: searchList })
store.SET_INDEX_LIST({ recommendList, hotSearch: searchList })
}

9
src/http/api.js

@ -16,12 +16,6 @@ export const getMemberBenefits = () => get(`${url().sourceUrl}/JSON/getMemberInt
//获取停车场数据
export const getParkingList = () => get(`${url().sourceUrl}/JSON/getParkingInfo.json`)
//获取服务信息
export const getServeList = () => get(`${url().sourceUrl}/JSON/getServeList.json`)
//获取 周边交通图片
export const getTrafficList = () => get(`${url().sourceUrl}/JSON/getMallTraffic.json`)
//获取品牌喜欢数量
export const getBrandLikesNumber = shopCode => get(`${url().interfaceUrl}/guide/v1/web/getBrandStar?shopCode=${shopCode}`)
@ -34,9 +28,6 @@ export const getCinemaInfo = () => get(`${url().sourceUrl}/JSON/getCinemaInfo.js
//获取商场介绍
export const getMallInfoList = () => get(`${url().sourceUrl}/JSON/getMallInfo.json`)
//是否显示语音
export const getIsShowVoiceBtn = () => get(`${url().sourceUrl}/JSON/getMallVoice.json`)
//获取跳转时间
export const getBackTime = () => get(`${url().sourceUrl}/JSON/getBackTime.json`)

7
src/views/Guide/Guide.vue

@ -260,11 +260,8 @@ watch(facility, fac => {
if (fac) handleFacility(fac)
else hideMapDialog()
})
const handleFacility = async fac => {
const index = currentBuildingFloorsList.value.findIndex(item => item.floorOrder === fac.floor)
console.log(index, currentBuildingFloorsList.value[index])
await changeFloor(index)
setTimeout(() => showFacility(fac), 500)
const handleFacility = fac => {
window.Map_QM.pathNode(fac)
}
</script>

Loading…
Cancel
Save