We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 771952c commit af36f93Copy full SHA for af36f93
routes/web.php
@@ -1,10 +1,17 @@
1
<?php
2
3
+use Illuminate\Support\Facades\Route;
4
+use Illuminate\Support\Facades\Storage;
5
+
6
Route::get('filament-excel/{path}', function (string $path) {
7
+ $filename = substr($path, 37);
8
+ $path = Storage::disk('filament-excel')->path($path);
9
10
return
11
response()
- ->download(Storage::disk('filament-excel')->path($path), substr($path, 37))
12
+ ->download($path, $filename)
13
->deleteFileAfterSend();
14
})
15
+ ->middleware(['web', 'signed'])
16
->where('path', '.*')
17
->name('filament-excel-download');
0 commit comments