File tree Expand file tree Collapse file tree 3 files changed +21
-1
lines changed
Expand file tree Collapse file tree 3 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -86,6 +86,12 @@ public function clearOffset()
8686 return $ this ;
8787 }
8888
89+ public function orderBy ($ field , $ direction )
90+ {
91+ $ this ->orderBy [] = $ this ->values ->orderBy ($ field , $ direction );
92+ return $ this ;
93+ }
94+
8995 public function orderAscendingBy ($ field )
9096 {
9197 $ this ->orderBy [] = $ this ->values ->orderBy ($ field , 'asc ' );
Original file line number Diff line number Diff line change @@ -40,6 +40,14 @@ public function getOffset();
4040 */
4141 public function clearOffset ();
4242
43+ /**
44+ * @param $field
45+ * @param $direction
46+ *
47+ * @return static
48+ */
49+ public function orderBy ($ field , $ direction );
50+
4351 /**
4452 * @return static
4553 */
Original file line number Diff line number Diff line change @@ -55,7 +55,13 @@ public function clearOffset()
5555 $ this ->query ->clearOffset ();
5656 return $ this ;
5757 }
58-
58+
59+ public function orderBy ($ field , $ direction )
60+ {
61+ $ this ->query ->orderBy ($ field , $ direction );
62+ return $ this ;
63+ }
64+
5965 public function orderAscendingBy ($ field )
6066 {
6167 $ this ->query ->orderAscendingBy ($ field );
You can’t perform that action at this time.
0 commit comments