diff --git a/epmet-apartment-front/index.html b/epmet-apartment-front/index.html index 001e3b0..c5e1eba 100644 --- a/epmet-apartment-front/index.html +++ b/epmet-apartment-front/index.html @@ -7,8 +7,8 @@ 青岛市免租金住房保障平台 - - + +
diff --git a/src/views/showings/apartmentDetail.vue b/src/views/showings/apartmentDetail.vue index 25e1a62..f3a59dd 100644 --- a/src/views/showings/apartmentDetail.vue +++ b/src/views/showings/apartmentDetail.vue @@ -4,7 +4,7 @@ { title: '看房', path: '/Showings' }, { title: '公寓详情', path: '' }, ]" - :width="1510" + :width="1678" />
@@ -118,6 +118,7 @@ const imgList = ref([ 'https://example.com/img2.jpg', 'https://example.com/img3.jpg', ]) +import centerImg from '@/assets/images/maker.png' const HouseApartmentList = ref([]) const houseId = route.query.id; const houseDetail = ref({}); // 存储房屋详情数据 @@ -214,12 +215,35 @@ const initMap = async () => { zoom: 13, center: [residentialDetail.value.longtitude, residentialDetail.value.latitude], }); - const marker = new AMap.Marker({ + // 创建自定义标记,包含图标和文字 + const customMarker = new AMap.Marker({ position: [residentialDetail.value.longtitude, residentialDetail.value.latitude], - title: '公寓位置', // 鼠标悬停文字 - icon: '../../assets/images/maker.png' // 自定义图标 + title: '公寓位置', + icon: centerImg, + // 使用自定义内容 + content: ` +
+ +
+ ${residentialDetail.value.deptName || '公寓名称'} +
+
+ ` }); - map.add(marker); + map.add(customMarker); } catch (err) { diff --git a/src/views/showings/components/HouseList.vue b/src/views/showings/components/HouseList.vue index 66ec09d..c73ea10 100644 --- a/src/views/showings/components/HouseList.vue +++ b/src/views/showings/components/HouseList.vue @@ -3,20 +3,23 @@
选择乐业社区
-
- -
-
{{ item.apartmentName }}
-
共{{ item.total }}间
-
{{ item.address }}
-
-
- {{ getLabel(tag) }} +
+
+ +
+
{{ item.apartmentName }}
+
共{{ item.total }}间
+
{{ item.address }}
+
+
+ {{ getLabel(tag) }} +
+
-
+