File tree 1 file changed +4
-5
lines changed 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -653,24 +653,23 @@ private function doPaging()
653
653
private function doOrdering ()
654
654
{
655
655
if (array_key_exists ('order ' , $ this ->input ) && count ($ this ->input ['order ' ]) > 0 ) {
656
- $ columns = $ this ->cleanColumns ($ this ->last_columns );
657
-
658
656
for ($ i = 0 , $ c = count ($ this ->input ['order ' ]); $ i < $ c ; $ i ++) {
659
657
$ order_col = (int ) $ this ->input ['order ' ][$ i ]['column ' ];
660
658
$ order_dir = $ this ->input ['order ' ][$ i ]['dir ' ];
659
+
661
660
if ($ this ->new_version ) {
662
661
$ column = $ this ->input ['columns ' ][$ order_col ];
663
662
if ($ column ['orderable ' ] == "true " ) {
664
- if ( ! empty ($ column ['name ' ])) {
663
+ if (! empty ($ column ['name ' ])) {
665
664
$ this ->query ->orderBy ($ column ['name ' ], $ order_dir );
666
665
} elseif (isset ($ columns [$ order_col ])) {
667
666
$ this ->query ->orderBy ($ columns [$ order_col ], $ order_dir );
668
667
}
669
668
}
670
669
} else {
671
- if (isset ($ columns [$ order_col ])) {
670
+ if (isset ($ this -> columns [$ order_col ])) {
672
671
if ($ this ->input ['columns ' ][$ order_col ]['orderable ' ] == "true " ) {
673
- $ this ->query ->orderBy ($ columns [$ order_col ], $ order_dir );
672
+ $ this ->query ->orderBy ($ this -> columns [$ order_col ], $ order_dir );
674
673
}
675
674
}
676
675
}
You can’t perform that action at this time.
0 commit comments