]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/CoreBundle/Controller/EntryController.php
Added translations and tweak parameters
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Controller / EntryController.php
index ff90957b9917661f879472a5186d28dea6ab26a1..5407d06578780227fe4a18eacc8b69463955e057 100644 (file)
@@ -532,9 +532,9 @@ class EntryController extends Controller
         $searchTerm = (isset($request->get('search_entry')['term']) ? $request->get('search_entry')['term'] : '');
         $currentRoute = (null !== $request->query->get('currentRoute') ? $request->query->get('currentRoute') : '');
 
-        $sortBy = 'id';
-        if (in_array($request->get('sort', 'id'), ['id', 'created_at', 'title', 'updated_at'], true)) {
-            $sortBy = $request->get('sort', 'id');
+        $sortBy = 'createdAt';
+        if (in_array($request->get('sort', 'createdAt'), ['id', 'createdAt', 'title', 'updatedAt'], true)) {
+            $sortBy = $request->get('sort', 'createdAt');
         }
 
         $direction = 'DESC' === $request->get('direction') ? 'DESC' : 'ASC';