Proyectos de Subversion LeadersLinked - Services

Rev

Rev 577 | Rev 668 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 577 Rev 665
Línea 723... Línea 723...
723
            $target_path = $storage->getPathGroup();
723
            $target_path = $storage->getPathGroup();
Línea 724... Línea 724...
724
 
724
 
725
 
725
 
726
            if ($operation == 'delete') {
726
            if ($operation == 'delete') {
727
                if ($group->cover) {
727
                if ($group->cover) {
728
                    if (!$storage->delete($target_path, $group->uuid, $group->cover)) {
728
                    if (!$storage->deleteFile($target_path, $group->uuid, $group->cover)) {
729
                        return new JsonModel([
729
                        return new JsonModel([
730
                            'success'   => false,
730
                            'success'   => false,
731
                            'data'   =>  'ERROR_THERE_WAS_AN_ERROR'
731
                            'data'   =>  'ERROR_THERE_WAS_AN_ERROR'
Línea 769... Línea 769...
769
                    $filename           = 'group-cover-' . uniqid() . '.png';
769
                    $filename           = 'group-cover-' . uniqid() . '.png';
770
                    $target_filename    = $storage->composePathToFilename(Storage::TYPE_GROUP, $group->uuid, $filename);
770
                    $target_filename    = $storage->composePathToFilename(Storage::TYPE_GROUP, $group->uuid, $filename);
Línea 771... Línea 771...
771
 
771
 
772
                    if ($storage->uploadImageCrop($source_filename, $target_filename, $target_width, $target_height)) {
772
                    if ($storage->uploadImageCrop($source_filename, $target_filename, $target_width, $target_height)) {
773
                        if ($group->cover) {
773
                        if ($group->cover) {
774
                            if (!$storage->delete($target_path, $group->uuid, $group->cover)) {
774
                            if (!$storage->deleteFile($target_path, $group->uuid, $group->cover)) {
775
                                return new JsonModel([
775
                                return new JsonModel([
776
                                    'success'   => false,
776
                                    'success'   => false,
777
                                    'data'   =>  'ERROR_THERE_WAS_AN_ERROR'
777
                                    'data'   =>  'ERROR_THERE_WAS_AN_ERROR'
778
                                ]);
778
                                ]);