Explorar el Código

添加分页status

chenxiqiang hace 6 años
padre
commit
02f8ff440d
Se han modificado 1 ficheros con 4 adiciones y 1 borrados
  1. 4
    1
      manage-server/app/Http/Controllers/ProductController.php

+ 4
- 1
manage-server/app/Http/Controllers/ProductController.php Ver fichero

@@ -57,6 +57,9 @@ class ProductController extends Controller
57 57
      */
58 58
     public function list(Request $request)
59 59
     {
60
-        return Product::paginate(20);
60
+
61
+        $json = Product::paginate(20);
62
+        $json->status = 0;
63
+        return $json;
61 64
     }
62 65
 }

Loading…
Cancelar
Guardar