|
@@ -274,7 +274,9 @@ export default {
|
|
|
|
|
|
loadMoreHandle: _.throttle(function() {
|
|
|
|
|
|
- if(document.body.scrollTop>window.outerHeight){
|
|
|
+ const scrollTop = document.documentElement.scrollTop || document.body.scrollTop; // 滚动的高度
|
|
|
+
|
|
|
+ if(scrollTop>window.outerHeight){
|
|
|
this.showToTop=true
|
|
|
}else{
|
|
|
this.showToTop=false
|
|
@@ -282,7 +284,6 @@ export default {
|
|
|
|
|
|
if(this.page_no >= this.total_page) return
|
|
|
|
|
|
- const scrollTop = document.documentElement.scrollTop || document.body.scrollTop; // 滚动的高度
|
|
|
const clientHeight = document.documentElement.clientHeight || document.body.clientHeight; // 可视高度
|
|
|
const scrollHeight = document.body.scrollHeight; // 总高度
|
|
|
const bufferHeight = 400;
|