Browse Source

fix: 🧩 根据楼层修改地图位置

pull/2/head
liyongle 3 years ago
parent
commit
fb49958c24
  1. 7
      src/components/Map/Map.vue
  2. 19
      src/composables/useGuideFilterShop.ts

7
src/components/Map/Map.vue

@ -90,9 +90,10 @@ function handleDetail() {
<style lang="scss" scoped> <style lang="scss" scoped>
#mapContainer { #mapContainer {
position: absolute; position: absolute;
right: 0;
width: 1432px;
height: 948px;
top: 152px;
right: 345px;
width: 1122px;
height: 676px;
} }
.map-flex { .map-flex {
display: flex; display: flex;

19
src/composables/useGuideFilterShop.ts

@ -14,6 +14,23 @@ export const useGuideFilterShop = () => {
floorIdx.value = floorOrder floorIdx.value = floorOrder
selectedShopList.value = shopList.value.filter(item => item.floorOrder === floorOrder) selectedShopList.value = shopList.value.filter(item => item.floorOrder === floorOrder)
hideMapDialog() hideMapDialog()
if (floorOrder === 6) {
const art: any = document.getElementById('mapContainer')
art.style.width = '2244px'
art.style.height = '1352px'
art.style.right = '690px'
art.style.top = '304px'
window.Map_QM.changeWindowResize(2244, 1352)
} else {
const art: any = document.getElementById('mapContainer')
if (art.style.width !== '2864px') {
art.style.width = '2864px'
art.style.height = '1896px'
art.style.right = '0'
art.style.top = '0'
window.Map_QM.changeWindowResize(2864, 1896)
}
}
window.Map_QM.showFloor(floorOrder) window.Map_QM.showFloor(floorOrder)
} }
@ -32,7 +49,7 @@ export const useGuideFilterShop = () => {
// 筛选美食业态 // 筛选美食业态
function changeFoodShopList() { function changeFoodShopList() {
selectedShopList.value = selectedShopList.value.filter(item => {
selectedShopList.value = shopList.value.filter(item => {
let flag = false let flag = false
for (let i = 0; i < specialIndustryList.value.length; i++) { for (let i = 0; i < specialIndustryList.value.length; i++) {
if (specialIndustryList.value[i].content.industry_id === item.industryFatherCode) { if (specialIndustryList.value[i].content.industry_id === item.industryFatherCode) {

Loading…
Cancel
Save