Put files download in public
This commit is contained in:
parent
52117734b7
commit
c616686fd6
2 changed files with 6 additions and 5 deletions
|
|
@ -207,7 +207,7 @@ class SyncController extends Controller
|
|||
$exists = Storage::disk('public')->exists('docs/' . $doc['uuid'] . '.' . $doc['type']);
|
||||
if ($exists) {
|
||||
array_push($attach, URL::temporarySignedRoute(
|
||||
'bo.docs.download',
|
||||
'docs.download',
|
||||
now()->addDays(30),
|
||||
['uuid' => $doc['uuid']]
|
||||
));
|
||||
|
|
|
|||
|
|
@ -23,10 +23,6 @@ Route::prefix('bo')->name('bo.')->middleware(['admin-secure'])->group(function (
|
|||
]);
|
||||
});
|
||||
|
||||
Route::get('/docs/{uuid}/download', [DocumentController::class, 'download'])
|
||||
->name('docs.download')
|
||||
->middleware('signed');
|
||||
|
||||
Route::middleware('auth:backend')->group(function () {
|
||||
Route::get('/', [DashboardController::class, 'index'])->name('dashboard');
|
||||
|
||||
|
|
@ -72,3 +68,8 @@ Route::prefix('bo')->name('bo.')->middleware(['admin-secure'])->group(function (
|
|||
Route::get('/', function () {
|
||||
return redirect()->route('bo.dashboard');
|
||||
});
|
||||
|
||||
// * Public files download
|
||||
Route::get('/docs/{uuid}/download', [DocumentController::class, 'download'])
|
||||
->name('docs.download')
|
||||
->middleware('signed');
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue