File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -53,6 +53,17 @@ public function getQueryResults()
53
53
return $ this ->_queryResults ;
54
54
}
55
55
56
+ /**
57
+ * @inheritdoc
58
+ */
59
+ public function prepare ($ forcePrepare = false )
60
+ {
61
+ if ($ forcePrepare ) {
62
+ $ this ->setTotalCount (null );
63
+ }
64
+ parent ::prepare ($ forcePrepare );
65
+ }
66
+
56
67
/**
57
68
* @return array all aggregations results
58
69
*/
Original file line number Diff line number Diff line change @@ -158,7 +158,7 @@ public function testTotalCountAfterSearch()
158
158
$ query ->andWhere (['name ' => 'user2 ' ]);
159
159
$ provider ->prepare (true );
160
160
$ this ->assertCount (1 , $ provider ->getModels ());
161
- $ this ->assertEquals (1 , $ provider -> getPagination () ->getPageCount ());
161
+ $ this ->assertEquals (1 , $ pagination ->getPageCount ());
162
162
$ this ->assertEquals (1 , $ provider ->getTotalCount ());
163
163
}
164
164
}
You can’t perform that action at this time.
0 commit comments