|
|
@@ -305,6 +305,7 @@ class AclQueryFeatures {
|
|
|
} else if ('limitstart' === $k) {
|
|
|
} else if ('order_by' === $k) {
|
|
|
} else if ('order_dir' === $k) {
|
|
|
+ } else if ('sortBy' === $k) {
|
|
|
} else {
|
|
|
throw new Exception("Not Implemented param '{$k}' = '{$v}'");
|
|
|
}
|
|
|
@@ -355,12 +356,15 @@ class AclQueryFeatures {
|
|
|
// 'order_by' => 'ID',
|
|
|
// 'order_dir' => 'desc',
|
|
|
// TODO: sortBy from wfs query
|
|
|
- $sortBy = $this->hasParam('order_by')
|
|
|
- ? ( $this->hasParam('order_dir')
|
|
|
- ? $this->getParam('order_by') . " " . $this->getParam('order_dir')
|
|
|
- : $this->getParam('order_by')
|
|
|
- )
|
|
|
- : '';
|
|
|
+ $sortBy = ($this->hasParam('sortBy')) ? $this->getParam('sortBy') : null;
|
|
|
+ if (!$sortBy) {
|
|
|
+ $sortBy = $this->hasParam('order_by')
|
|
|
+ ? ( $this->hasParam('order_dir')
|
|
|
+ ? $this->getParam('order_by') . " " . $this->getParam('order_dir')
|
|
|
+ : $this->getParam('order_by')
|
|
|
+ )
|
|
|
+ : '';
|
|
|
+ }
|
|
|
$limit = V::get('limit', 10, $this->_params, 'int');
|
|
|
$offset = V::get('limitstart', 0, $this->_params, 'int');
|
|
|
|