]> BookStack Code Mirror - bookstack/blobdiff - app/Http/Controllers/PageController.php
Updated all application urls to allow path prefix.
[bookstack] / app / Http / Controllers / PageController.php
index 373e49de762a2a113793cc20a96b9c195ea0d9cc..1509ace9563b7aee65fe3b8c167f5e07117bacf6 100644 (file)
@@ -412,7 +412,7 @@ class PageController extends Controller
      */
     public function showRecentlyCreated()
     {
-        $pages = $this->pageRepo->getRecentlyCreatedPaginated(20);
+        $pages = $this->pageRepo->getRecentlyCreatedPaginated(20)->setPath(baseUrl('/pages/recently-created'));
         return view('pages/detailed-listing', [
             'title' => 'Recently Created Pages',
             'pages' => $pages
@@ -425,7 +425,7 @@ class PageController extends Controller
      */
     public function showRecentlyUpdated()
     {
-        $pages = $this->pageRepo->getRecentlyUpdatedPaginated(20);
+        $pages = $this->pageRepo->getRecentlyUpdatedPaginated(20)->setPath(baseUrl('/pages/recently-updated'));
         return view('pages/detailed-listing', [
             'title' => 'Recently Updated Pages',
             'pages' => $pages
@@ -468,6 +468,14 @@ class PageController extends Controller
         ]);
     }
 
+    /**
+     * Does the action of moving the location of a page
+     * @param $bookSlug
+     * @param $pageSlug
+     * @param Request $request
+     * @return mixed
+     * @throws NotFoundException
+     */
     public function move($bookSlug, $pageSlug, Request $request)
     {
         $book = $this->bookRepo->getBySlug($bookSlug);