|
@@ -14,7 +14,7 @@ const imgArrTemp = ['like.png', 'likeAc.png']
|
|
|
const imgArr = imgArrTemp.map(item => require(`@/assets/img/${item}`))
|
|
|
|
|
|
function A2main() {
|
|
|
- const sceneCode = 'mm-1562'
|
|
|
+ const SCENE_CODE = 'SG-zeRFYMaTE9F'
|
|
|
// 漫游的状态
|
|
|
const { state3d } = useSelector((state: RootState) => state.three)
|
|
|
|
|
@@ -24,10 +24,10 @@ function A2main() {
|
|
|
const [viewNum, setViewNum] = useState(1)
|
|
|
|
|
|
useEffect(() => {
|
|
|
- http.get(`https://count.4dage.com/api/count/detail/${sceneCode}`).then(res => {
|
|
|
+ http.get(`https://count.4dage.com/api/count/detail/${SCENE_CODE}`).then(res => {
|
|
|
setLikeNum(res.data.starSum!)
|
|
|
})
|
|
|
- http.get(`https://count.4dage.com/api/count/saveVisit/${sceneCode}`).then(res => {
|
|
|
+ http.get(`https://count.4dage.com/api/count/saveVisit/${SCENE_CODE}`).then(res => {
|
|
|
setViewNum(res.data.visitSum!)
|
|
|
})
|
|
|
}, [])
|
|
@@ -37,7 +37,7 @@ function A2main() {
|
|
|
if (like) return
|
|
|
setLike(true)
|
|
|
setTimeout(() => {
|
|
|
- http.get(`https://count.4dage.com/api/count/saveStar/${sceneCode}`).then(res => {
|
|
|
+ http.get(`https://count.4dage.com/api/count/saveStar/${SCENE_CODE}`).then(res => {
|
|
|
setLikeNum(likeNum + 1)
|
|
|
setLike(false)
|
|
|
})
|
|
@@ -70,6 +70,13 @@ function A2main() {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ const hiddenMap = (isShow: boolean) => {
|
|
|
+ const cad: any = document.querySelector('.cad')
|
|
|
+ if (cad) {
|
|
|
+ cad.style.visibility = isShow ? 'hidden' : 'visible'
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
return (
|
|
|
<div className={styles.A2main} id='gui' style={{ display: 'none' }}>
|
|
|
<A21vrOff />
|
|
@@ -167,6 +174,7 @@ function A2main() {
|
|
|
// 停止自动导览
|
|
|
window.player.director.stopTour()
|
|
|
setHotListShow(true)
|
|
|
+ hiddenMap(true)
|
|
|
}}
|
|
|
>
|
|
|
<img src='images/hotlist.png' alt='' />
|
|
@@ -190,7 +198,7 @@ function A2main() {
|
|
|
alt=''
|
|
|
/>
|
|
|
{/* 鼠标移入 */}
|
|
|
- <div className='hoveImg'>全景模型</div>
|
|
|
+ <div className='hoveImg'>迷你模型</div>
|
|
|
</div>
|
|
|
<div data-original-title='俯视图' id='gui-modes-floorplan' rel='tooltip'>
|
|
|
<img
|
|
@@ -308,7 +316,10 @@ function A2main() {
|
|
|
<A3hotList
|
|
|
show={hotListShow}
|
|
|
setShow={setHotListShow}
|
|
|
- closeFu={() => setHotListShow(false)}
|
|
|
+ closeFu={() => {
|
|
|
+ setHotListShow(false)
|
|
|
+ hiddenMap(false)
|
|
|
+ }}
|
|
|
/>
|
|
|
</div>
|
|
|
)
|