1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-07-30 04:23:11 +03:00

Fixed some mis-refactoring and split search service

Search service broken into index and runner tools.
This commit is contained in:
Dan Brown
2020-11-22 00:17:45 +00:00
parent c7a2d568bf
commit ef1b98019a
108 changed files with 399 additions and 379 deletions

View File

@ -1,10 +1,8 @@
<?php namespace BookStack\Http\Controllers\Api;
use BookStack\Actions\ActivityType;
use BookStack\Entities\Book;
use BookStack\Entities\Models\Book;
use BookStack\Entities\Repos\BookRepo;
use BookStack\Exceptions\NotifyException;
use BookStack\Facades\Activity;
use Illuminate\Contracts\Container\BindingResolutionException;
use Illuminate\Http\Request;
use Illuminate\Validation\ValidationException;
@ -27,9 +25,6 @@ class BookApiController extends ApiController
],
];
/**
* BooksApiController constructor.
*/
public function __construct(BookRepo $bookRepo)
{
$this->bookRepo = $bookRepo;
@ -85,8 +80,7 @@ class BookApiController extends ApiController
/**
* Delete a single book from the system.
* @throws NotifyException
* @throws BindingResolutionException
* @throws \Exception
*/
public function delete(string $id)
{

View File

@ -1,7 +1,7 @@
<?php namespace BookStack\Http\Controllers\Api;
use BookStack\Entities\Book;
use BookStack\Entities\ExportService;
use BookStack\Entities\Models\Book;
use BookStack\Entities\Tools\ExportFormatter;
use BookStack\Entities\Repos\BookRepo;
use Throwable;
@ -13,7 +13,7 @@ class BookExportApiController extends ApiController
/**
* BookExportController constructor.
*/
public function __construct(BookRepo $bookRepo, ExportService $exportService)
public function __construct(BookRepo $bookRepo, ExportFormatter $exportService)
{
$this->bookRepo = $bookRepo;
$this->exportService = $exportService;

View File

@ -1,7 +1,7 @@
<?php namespace BookStack\Http\Controllers\Api;
use BookStack\Entities\Repos\BookshelfRepo;
use BookStack\Entities\Bookshelf;
use BookStack\Entities\Models\Bookshelf;
use Exception;
use Illuminate\Database\Eloquent\Relations\BelongsToMany;
use Illuminate\Http\Request;

View File

@ -1,8 +1,8 @@
<?php namespace BookStack\Http\Controllers\Api;
use BookStack\Actions\ActivityType;
use BookStack\Entities\Book;
use BookStack\Entities\Chapter;
use BookStack\Entities\Models\Book;
use BookStack\Entities\Models\Chapter;
use BookStack\Entities\Repos\ChapterRepo;
use BookStack\Facades\Activity;
use Illuminate\Database\Eloquent\Relations\HasMany;

View File

@ -1,7 +1,7 @@
<?php namespace BookStack\Http\Controllers\Api;
use BookStack\Entities\Chapter;
use BookStack\Entities\ExportService;
use BookStack\Entities\Models\Chapter;
use BookStack\Entities\Tools\ExportFormatter;
use BookStack\Entities\Repos\BookRepo;
use Throwable;
@ -13,7 +13,7 @@ class ChapterExportApiController extends ApiController
/**
* ChapterExportController constructor.
*/
public function __construct(BookRepo $chapterRepo, ExportService $exportService)
public function __construct(BookRepo $chapterRepo, ExportFormatter $exportService)
{
$this->chapterRepo = $chapterRepo;
$this->exportService = $exportService;