Implement file upload and viewing functionality; refactor letter migrations and models to use UUIDs
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use App\Models\FileUpload;
|
||||
|
||||
class FileViewController extends Controller
|
||||
{
|
||||
public function show($id)
|
||||
{
|
||||
$file = FileUpload::findOrFail($id);
|
||||
return response()->file(storage_path('app/public/' . $file->file_path));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user