This commit is contained in:
F4ilji
2026-04-07 17:54:26 +05:00
parent 04adba6682
commit 936b1fb5b0
468 changed files with 43498 additions and 4176 deletions
@@ -0,0 +1,24 @@
<?php
namespace App\Containers\Dashboard\Tasks\Sliders;
use Illuminate\Http\UploadedFile;
use Illuminate\Support\Str;
class UploadSlideImageTask
{
public function run(UploadedFile $file): array
{
$filename = Str::uuid() . '.' . $file->getClientOriginalExtension();
$path = $file->storeAs('slides', $filename, 'public');
// Сохраняем только путь файла (как Filament)
return [
'url' => $path,
'path' => $path,
'name' => $file->getClientOriginalName(),
'size' => $file->getSize(),
'mime' => $file->getMimeType(),
];
}
}