|
@@ -95,14 +95,19 @@ module.exports = function(data) { |
|
@@ -95,14 +95,19 @@ module.exports = function(data) { |
95
|
var load = new InfiniteLoad({
|
95
|
var load = new InfiniteLoad({
|
96
|
offset: {
|
96
|
offset: {
|
97
|
height: function() {
|
97
|
height: function() {
|
98
|
- return parseFloat($container.offset().top) + parseFloat($container.height());
|
98
|
+ return parseFloat($container.offset().top) + parseFloat($container.height())-200;
|
99
|
}
|
99
|
}
|
100
|
}
|
100
|
}
|
101
|
});
|
101
|
});
|
102
|
var options;
|
102
|
var options;
|
103
|
var url = data.url;
|
103
|
var url = data.url;
|
|
|
104
|
+ var firstCount = data.firstCount;
|
|
|
105
|
+ var pageCount=data.pageCount;
|
104
|
|
106
|
|
105
|
delete data.url;
|
107
|
delete data.url;
|
|
|
108
|
+ delete data.firstCount;
|
|
|
109
|
+ delete data.pageCount;
|
|
|
110
|
+
|
106
|
|
111
|
|
107
|
|
112
|
|
108
|
load.on('after', function(p) {
|
113
|
load.on('after', function(p) {
|
|
@@ -111,6 +116,8 @@ module.exports = function(data) { |
|
@@ -111,6 +116,8 @@ module.exports = function(data) { |
111
|
pageIndex: p.index
|
116
|
pageIndex: p.index
|
112
|
});
|
117
|
});
|
113
|
|
118
|
|
|
|
119
|
+ data.pageCount = (data.pageIndex == 1) ? firstCount : pageCount;
|
|
|
120
|
+
|
114
|
options = {
|
121
|
options = {
|
115
|
type: 'POST',
|
122
|
type: 'POST',
|
116
|
url: url,
|
123
|
url: url,
|