提交室内导览交互与讲解优化

This commit is contained in:
lyf
2026-06-14 23:48:13 +08:00
parent a7c1879f60
commit feb7310a46
33 changed files with 3257 additions and 361 deletions

View File

@@ -22,7 +22,7 @@
<view class="stats-row">
<view class="stat-item">
<text class="stat-value">{{ hall.exhibitCount }}</text>
<text class="stat-label">讲解</text>
<text class="stat-label">讲解内容</text>
</view>
<view class="stat-item">
<text class="stat-value">{{ hall.floorLabel }}</text>
@@ -32,7 +32,7 @@
<!-- 讲解列表 -->
<view class="exhibits-section">
<text class="section-title">展厅讲解内容</text>
<text class="section-title">空间讲解内容</text>
<view class="exhibits-grid">
<ExhibitCard
v-for="exhibit in exhibits"
@@ -63,6 +63,9 @@ import ExhibitCard from '@/components/content/ExhibitCard.vue'
import {
explainUseCase
} from '@/usecases/explainUseCase'
import {
guideUseCase
} from '@/usecases/guideUseCase'
import {
toExplainExhibitViewModel,
toHallDetailViewModel,
@@ -81,7 +84,7 @@ const hall = ref<HallDetailViewModel>({
id: '',
name: '展厅内容',
floorLabel: '楼层待补充',
description: '该展厅介绍待正式内容补充。',
description: '该空间介绍待 SGS 场景设置或 CMS 内容补充。',
image: '/static/hall-placeholder.jpg',
exhibitCount: 0,
area: '待补充'
@@ -111,7 +114,7 @@ const handleExhibitClick = (exhibit: any) => {
})
}
const handleNavigate = () => {
const handleNavigate = async () => {
if (!hall.value.poiId) {
uni.showToast({
title: '该展厅暂无三维位置数据',
@@ -120,6 +123,15 @@ const handleNavigate = () => {
return
}
const matchedPoi = await guideUseCase.getPoiById(hall.value.poiId)
if (!matchedPoi) {
uni.showToast({
title: '该空间位置尚未映射到当前三维导览资源',
icon: 'none'
})
return
}
uni.navigateTo({
url: `/pages/route/detail?facilityId=${encodeURIComponent(hall.value.poiId)}&target=${encodeURIComponent(hall.value.name)}&state=preview`
})