BookStack icon indicating copy to clipboard operation
BookStack copied to clipboard

Allow manual book order sorting

Open davidPilkington opened this issue 9 years ago • 9 comments

Desired Feature: Allow Book order sorting, similar to how this works within books for chapters/pages

davidPilkington avatar Sep 08 '16 02:09 davidPilkington

This is related with https://github.com/BookStackApp/BookStack/issues/126

patoroco avatar Feb 09 '17 16:02 patoroco

I would like to see this as well, I just noticed that a chapter I just created is at the bottom of a book.

auswade avatar Aug 31 '18 03:08 auswade

I would also like to see this added.

DonnaScriptTechs avatar Oct 08 '18 20:10 DonnaScriptTechs

how about being able to choose "Specific Shelf" for the application homepage? that would be a great compromise then you could have one shelf and set it to the home page I'd imagine that's fairly easy to implement, and the dropdown is already there so no clunkiness and it wouldn't break existing use-cases

agent4125 avatar Jun 23 '22 14:06 agent4125

@agent4125 Related to #1519 and #2315

ssddanbrown avatar Jun 23 '22 14:06 ssddanbrown

Setting manually the default order when editing the shelf is perfect for me, but in case someone would like to set the default order to something else : just edit app/Entities/Controllers/BookshelfController.php file and move/remove/comment the line below. It will set the default sort order to the top line option, here name (as it will be the first on the list).


        $listOptions = SimpleListOptions::fromRequest($request, 'shelf_books')->withSortOptions([
-            'default' => trans('common.sort_default'),
            'name' => trans('common.sort_name'),
            'created_at' => trans('common.sort_created_at'),
            'updated_at' => trans('common.sort_updated_at'),
        ]);

PS: to set the default order in the shelves view, edit the order following the line $listOptions = SimpleListOptions::fromRequest($request, 'bookshelves')->withSortOptions([

Twix53791 avatar Jul 20 '23 10:07 Twix53791