[BUGFIX] Use `addOrderBy()` to support multiple orderings
[Packages/TYPO3.CMS.git] / typo3 / sysext / recordlist / Classes / RecordList / DatabaseRecordList.php
index 0ada2cd..df11ef5 100644 (file)
@@ -3295,7 +3295,7 @@ class DatabaseRecordList
                 $orderBy = $GLOBALS['TCA'][$table]['ctrl']['sortby'] ?: $GLOBALS['TCA'][$table]['ctrl']['default_sortby'];
                 $orderBys = QueryHelper::parseOrderBy((string)$orderBy);
                 foreach ($orderBys as $orderBy) {
-                    $queryBuilder->orderBy($orderBy[0], $orderBy[1]);
+                    $queryBuilder->addOrderBy($orderBy[0], $orderBy[1]);
                 }
             }
         }