This commit is contained in:
2024-05-23 16:54:06 +02:00
parent fc2b66528b
commit 3f26df05b5
26 changed files with 1193 additions and 0 deletions

View File

@@ -0,0 +1,68 @@
<?php
namespace App\Http\Controllers;
use App\Http\Requests\StoreImageRequest;
use App\Http\Requests\UpdateImageRequest;
use App\Models\Image;
use Illuminate\Support\Facades\Storage;
use Symfony\Component\HttpFoundation\BinaryFileResponse;
class ImageController extends Controller
{
/**
* Display a listing of the resource.
*/
public function index()
{
//
}
/**
* Show the form for creating a new resource.
*/
public function create()
{
//
}
/**
* Store a newly created resource in storage.
*/
public function store(StoreImageRequest $request)
{
//
}
/**
* Display the specified resource.
*/
public function show(Image $image) : BinaryFileResponse
{
return response()->file(Storage::disk('images')->path($image->album->id . '/original/' . $image->id));
}
/**
* Show the form for editing the specified resource.
*/
public function edit(Image $image)
{
//
}
/**
* Update the specified resource in storage.
*/
public function update(UpdateImageRequest $request, Image $image)
{
//
}
/**
* Remove the specified resource from storage.
*/
public function destroy(Image $image)
{
//
}
}