黄宗昌 há 2 anos atrás
pai
commit
287dbf3b46
1 ficheiros alterados com 2 adições e 0 exclusões
  1. 2 0
      app/Http/Controllers/V1/ProductController.php

+ 2 - 0
app/Http/Controllers/V1/ProductController.php

xqd xqd
@@ -48,6 +48,7 @@ class ProductController extends Controller
           ->where('status',1)
           ->where($map)
           ->orWhere($maps)
+          ->orderByDesc("sort")
           ->get();
       $data = [];
       foreach ($list as $v){
@@ -89,6 +90,7 @@ class ProductController extends Controller
             ->where('status',1)
             ->where($map)
             ->orWhere($maps)
+            ->orderByDesc("sort")
             ->get();
         $data = [];
         foreach ($list as $v){