Explorar o código

add log after PaliSearch::search

visuddhinanda %!s(int64=2) %!d(string=hai) anos
pai
achega
6e61002abd
Modificáronse 1 ficheiros con 7 adicións e 0 borrados
  1. 7 0
      app/Http/Controllers/SearchController.php

+ 7 - 0
app/Http/Controllers/SearchController.php

@@ -190,6 +190,13 @@ class SearchController extends Controller
         $offset = $request->get('offset',0);
         $matchMode = $request->get('match','case');
         $result = PaliSearch::search($key,$bookId,$matchMode,$offset,$limit);
+        Log::debug('search tulip total='.$result['total'],[
+            'key'=>$request->get('key'),
+            'bookId'=>$bookId,
+            'matchMode'=>$matchMode,
+            'offset'=>$offset,
+            'limit'=>$limit,
+        ]);
         return $this->ok(["rows"=>SearchResource::collection(collect($result['rows'])),"count"=>$result['total']]);
     }