Modernize Phriction ordering/paging
Summary: Ref T7803. Fixes T7809. Move Phriction away from getReversePaging() / getPagingColumn(). Test Plan: Paged "All Documents", "Updated", and viewed document hierarchy. Reviewers: btrahan Reviewed By: btrahan Subscribers: ite-klass, epriestley Maniphest Tasks: T7809, T7803 Differential Revision: https://secure.phabricator.com/D12360
This commit is contained in:
@@ -249,6 +249,8 @@ abstract class PhabricatorCursorPagedPolicyAwareQuery
|
||||
->setViewer($this->getPagingViewer())
|
||||
->withIDs(array((int)$cursor));
|
||||
|
||||
$this->willExecuteCursorQuery($query);
|
||||
|
||||
$object = $query->executeOne();
|
||||
if (!$object) {
|
||||
throw new Exception(
|
||||
@@ -260,6 +262,11 @@ abstract class PhabricatorCursorPagedPolicyAwareQuery
|
||||
return $object;
|
||||
}
|
||||
|
||||
protected function willExecuteCursorQuery(
|
||||
PhabricatorCursorPagedPolicyAwareQuery $query) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Simplifies the task of constructing a paging clause across multiple
|
||||
@@ -446,7 +453,7 @@ abstract class PhabricatorCursorPagedPolicyAwareQuery
|
||||
/**
|
||||
* @task order
|
||||
*/
|
||||
private function getOrderVector() {
|
||||
protected function getOrderVector() {
|
||||
if (!$this->orderVector) {
|
||||
$vector = $this->getDefaultOrderVector();
|
||||
$vector = PhabricatorQueryOrderVector::newFromVector($vector);
|
||||
|
||||
Reference in New Issue
Block a user