mirror of
https://github.com/Karaka-Management/oms-Draw.git
synced 2026-01-30 14:58:40 +00:00
Type and cs fixes
This commit is contained in:
parent
4ca0f4d7cd
commit
f8e49e241f
|
|
@ -103,16 +103,16 @@ final class ApiController extends Controller
|
|||
$this->createLocalFile($fullPath, (string) $request->getData('image'));
|
||||
|
||||
$status = [
|
||||
'path' => $path,
|
||||
'filename' => $filename,
|
||||
'name' => (string) $request->getData('title'),
|
||||
'size' => File::size($fullPath),
|
||||
'path' => $path,
|
||||
'filename' => $filename,
|
||||
'name' => (string) $request->getData('title'),
|
||||
'size' => File::size($fullPath),
|
||||
'extension' => $extension,
|
||||
'status' => UploadStatus::OK,
|
||||
'status' => UploadStatus::OK,
|
||||
];
|
||||
|
||||
$media = MediaController::createDbEntry($status, $request->getHeader()->getAccount());
|
||||
$draw = DrawImage::fromMedia($media);
|
||||
$draw = $media !== null ? DrawImage::fromMedia($media) : null;
|
||||
|
||||
$this->createModel($request->getHeader()->getAccount(), $draw, DrawImageMapper::class, 'draw');
|
||||
$this->fillJsonResponse($request, $response, NotificationLevel::OK, 'Draw', 'Draw successfully created.', $draw);
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ final class DrawImageMapper extends DataMapperAbstract
|
|||
/**
|
||||
* Has one relation.
|
||||
*
|
||||
* @var array<string, array{mapper:string, self:string, by?:string}>
|
||||
* @var array<string, array{mapper:string, self:string, by?:string, column?:string}>
|
||||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $ownsOne = [
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user