mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-05-20 23:19:38 +00:00
Fixed shelf activity display & updated book sort operation
This commit is contained in:
parent
5910e00fb8
commit
ba09dad1fe
6 changed files with 15 additions and 16 deletions
app/Http/Controllers
|
@ -124,6 +124,7 @@ class BookshelfController extends Controller
|
|||
$this->entityContextManager->setShelfContext($shelf->id);
|
||||
|
||||
$this->setPageTitle($shelf->getShortName());
|
||||
|
||||
return view('shelves.show', [
|
||||
'shelf' => $shelf,
|
||||
'books' => $books,
|
||||
|
@ -287,6 +288,7 @@ class BookshelfController extends Controller
|
|||
// Update the cover image if in request
|
||||
if ($request->has('image')) {
|
||||
$newImage = $request->file('image');
|
||||
$this->imageRepo->destroyImage($shelf->cover);
|
||||
$image = $this->imageRepo->saveNew($newImage, 'cover_shelf', $shelf->id, 512, 512, true);
|
||||
$shelf->image_id = $image->id;
|
||||
$shelf->save();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue