修改bug
This commit is contained in:
@@ -982,6 +982,7 @@ let setNavigation = () => {
|
||||
path: pageType.value === 2 ? "/intermediaryHousing" : pageType.value === 3 ? "/needHousing" : "/personHousing",
|
||||
title: pageType.value === 2 ? "中介房源" : pageType.value === 3 ? "求房源" : "个人房源",
|
||||
}
|
||||
housingInfo["data"]["info"].location = housingInfo["data"]["info"].location + ''
|
||||
store.state.routeList["thirdIndex"] = {
|
||||
path: `${store.state.routeList["secondaryIndex"].path}`,
|
||||
query: {
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
|
||||
<div class="list wid1200 flexflex" ref="gridContainer">
|
||||
<template v-if="list.length != 0">
|
||||
<apartment-item v-for="(item, index) in list" :key="index" :item="item"></apartment-item>
|
||||
<apartment-item v-for="(item, index) in list" :key="index" :item="item" :pitchValue="pitchValue" @handlecollect="handlecollect"></apartment-item>
|
||||
</template>
|
||||
</div>
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
<!-- 其他附近房源 -->
|
||||
<div v-if="moreList.length != 0" class="other-nearby-listings-box flexcenter">没有找到更多房源,为您推荐其他附近房源</div>
|
||||
<div class="wid1200" ref="moreShowList">
|
||||
<apartment-item v-for="(item, index) in moreList" :key="index" :item="item"></apartment-item>
|
||||
<apartment-item v-for="(item, index) in moreList" :key="index" :item="item" :pitchValue="pitchValue"></apartment-item>
|
||||
</div>
|
||||
|
||||
<div class="bottom-tps" v-if="list.length != 0 && page == 0">- 到底了 -</div>
|
||||
@@ -178,7 +178,7 @@ let moreLoading = ref(false)
|
||||
// 加载更多数据列表
|
||||
const getMoreList = () => {
|
||||
if (morePage.value == 0 || moreLoading.value) return
|
||||
console.log("11111");
|
||||
console.log("11111")
|
||||
moreLoading.value = true
|
||||
let postData = {
|
||||
page: morePage.value,
|
||||
@@ -189,7 +189,7 @@ const getMoreList = () => {
|
||||
if (res.code != 200) return
|
||||
const data = res.data
|
||||
if (!data.data) return
|
||||
|
||||
|
||||
moreList.value = moreList.value.concat(data.data)
|
||||
moreState.value = true
|
||||
if (data.data && data.data.length < data.limit) morePage.value = 0
|
||||
@@ -212,6 +212,11 @@ const getMoreScroll = () => {
|
||||
let offsetHeight = body.offsetHeight
|
||||
if (scrollTop + clientHeight >= offsetHeight - 200 && !moreLoading.value) getMoreList()
|
||||
}
|
||||
|
||||
// 处理列表的点击收藏
|
||||
const handlecollect = item => {
|
||||
console.log("item", item)
|
||||
}
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.screen-box {
|
||||
|
||||
Reference in New Issue
Block a user