|
@@ -13,7 +13,7 @@ let house = (props, ref) => {
|
13
|
13
|
const [list, setList] = useState([])
|
14
|
14
|
const [radioHouse, setRadioHouse] = useState()
|
15
|
15
|
const [width, setWidth] = useState()
|
16
|
|
- // const [height, setHeight] = useState()
|
|
16
|
+ const [height, setHeight] = useState()
|
17
|
17
|
const [queryParams, setQueryParams] = useState({pageNum: 1, pageSize: 10})
|
18
|
18
|
const [total, setTotal] = useState(0)
|
19
|
19
|
|
|
@@ -72,6 +72,25 @@ let house = (props, ref) => {
|
72
|
72
|
// setHeight(res[0].height)
|
73
|
73
|
}
|
74
|
74
|
}).exec()
|
|
75
|
+
|
|
76
|
+ Taro.createSelectorQuery()
|
|
77
|
+ .selectAll('.tab')
|
|
78
|
+ .boundingClientRect(res => {
|
|
79
|
+ let found = false
|
|
80
|
+ if (res) {
|
|
81
|
+ for (let item of res) {
|
|
82
|
+ if (item.height) {
|
|
83
|
+ found = true
|
|
84
|
+ setHeight(Taro.getSystemInfoSync().safeArea.height - item.height - 50)
|
|
85
|
+ break
|
|
86
|
+ }
|
|
87
|
+ }
|
|
88
|
+ }
|
|
89
|
+
|
|
90
|
+ if (!found) {
|
|
91
|
+ setHeight(500)
|
|
92
|
+ }
|
|
93
|
+ }).exec()
|
75
|
94
|
})
|
76
|
95
|
|
77
|
96
|
}, [])
|
|
@@ -90,7 +109,7 @@ let house = (props, ref) => {
|
90
|
109
|
(!list || !list.length) && < View className='nodata'> 暂无数据</View>
|
91
|
110
|
}
|
92
|
111
|
<RecycleList
|
93
|
|
- height={508}
|
|
112
|
+ height={height}
|
94
|
113
|
width={width}
|
95
|
114
|
list={list}
|
96
|
115
|
total={total}
|