| Línea 624... |
Línea 624... |
| 624 |
|
624 |
|
| 625 |
$source_filename = $storage->getTmpFilename();
|
625 |
$source_filename = $storage->getTmpFilename();
|
| 626 |
$filename = 'group-image-' . uniqid() . '.png';
|
626 |
$filename = 'group-image-' . uniqid() . '.png';
|
| Línea 627... |
Línea 627... |
| 627 |
$target_filename = $storage->composePathToFilename(Storage::TYPE_GROUP, $group->uuid, $filename);
|
627 |
$target_filename = $storage->composePathToFilename(Storage::TYPE_GROUP, $group->uuid, $filename);
|
| Línea 628... |
Línea 628... |
| 628 |
|
628 |
|
| 629 |
if ($storage->uploadImageCrop($source_filename, $target_filename, $target_width, $target_height)) {
|
629 |
if ($storage->uploadImageResize($source_filename, $target_filename, $target_width, $target_height)) {
|
| 630 |
|
630 |
|
| 631 |
if ($group->image) {
|
631 |
if ($group->image) {
|
| Línea 764... |
Línea 764... |
| 764 |
|
764 |
|
| 765 |
$source_filename = $storage->getTmpFilename();
|
765 |
$source_filename = $storage->getTmpFilename();
|
| 766 |
$filename = 'group-cover-' . uniqid() . '.png';
|
766 |
$filename = 'group-cover-' . uniqid() . '.png';
|
| Línea 767... |
Línea 767... |
| 767 |
$target_filename = $storage->composePathToFilename(Storage::TYPE_GROUP, $group->uuid, $filename);
|
767 |
$target_filename = $storage->composePathToFilename(Storage::TYPE_GROUP, $group->uuid, $filename);
|
| 768 |
|
768 |
|
| 769 |
if ($storage->uploadImageCrop($source_filename, $target_filename, $target_width, $target_height)) {
|
769 |
if ($storage->uploadImageResize($source_filename, $target_filename, $target_width, $target_height)) {
|
| 770 |
if ($group->cover) {
|
770 |
if ($group->cover) {
|
| 771 |
if (!$storage->deleteFile($target_path, $group->uuid, $group->cover)) {
|
771 |
if (!$storage->deleteFile($target_path, $group->uuid, $group->cover)) {
|
| 772 |
return new JsonModel([
|
772 |
return new JsonModel([
|