Proyectos de Subversion LeadersLinked - Services

Rev

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

Rev 1 Rev 60
Línea 146... Línea 146...
146
                foreach ($records as $record) {
146
                foreach ($records as $record) {
Línea 147... Línea 147...
147
 
147
 
148
                    $item = [
148
                    $item = [
149
                        'id' => $record->id,
149
                        'id' => $record->id,
150
                        'name' => $record->name,
150
                        'name' => $record->name,
151
                        'image' => $this->url()->fromRoute('storage', ['type' => 'user', 'code' => $currentUser->uuid, 'filename' => $record->image]),
151
                        'image' => $this->url()->fromRoute('storage', ['type' => 'user', 'code' => $currentUser->uuid, 'filename' => $record->image],['force_canonical' => true]),
152
                        'link_view' => $allowView ? $this->url()->fromRoute('profile/view', ['id' => $record->uuid])  : '',
152
                        'link_view' => $allowView ? $this->url()->fromRoute('profile/view', ['id' => $record->uuid])  : '',
153
                        'link_edit' => $allowEdit ? $this->url()->fromRoute('profile/my-profiles/edit', ['id' => $record->uuid])  : '',
153
                        'link_edit' => $allowEdit ? $this->url()->fromRoute('profile/my-profiles/edit', ['id' => $record->uuid])  : '',
154
                        'link_delete' => $allowDelete && $record->public == UserProfile::PUBLIC_NO ? $this->url()->fromRoute('profile/my-profiles/delete', ['id' => $record->uuid]) : '',
154
                        'link_delete' => $allowDelete && $record->public == UserProfile::PUBLIC_NO ? $this->url()->fromRoute('profile/my-profiles/delete', ['id' => $record->uuid]) : '',
Línea 1690... Línea 1690...
1690
                }
1690
                }
1691
            }
1691
            }
1692
            return new JsonModel([
1692
            return new JsonModel([
1693
                'success'   => true,
1693
                'success'   => true,
1694
                'data' => [
1694
                'data' => [
1695
                    'user' => $this->url()->fromRoute('storage', ['type' => 'user', 'code' => $currentUser->uuid, 'filename' => $currentUser->image]),
1695
                    'user' => $this->url()->fromRoute('storage', ['type' => 'user', 'code' => $currentUser->uuid, 'filename' => $currentUser->image],['force_canonical' => true]),
1696
                    'profile' => $this->url()->fromRoute('storage', ['type' => 'user-profile', 'code' => $currentUser->uuid, 'filename' => $userProfile->image]),
1696
                    'profile' => $this->url()->fromRoute('storage', ['type' => 'user-profile', 'code' => $currentUser->uuid, 'filename' => $userProfile->image],['force_canonical' => true]),
1697
                    'update_navbar' =>  $userProfile->public == UserProfile::PUBLIC_YES ? 1 : 0,
1697
                    'update_navbar' =>  $userProfile->public == UserProfile::PUBLIC_YES ? 1 : 0,
Línea 1698... Línea 1698...
1698
 
1698
 
1699
                ]
1699
                ]
1700
            ]);
1700
            ]);
Línea 1832... Línea 1832...
1832
                    ]);
1832
                    ]);
1833
                }
1833
                }
1834
            }
1834
            }
1835
            return new JsonModel([
1835
            return new JsonModel([
1836
                'success'   => true,
1836
                'success'   => true,
1837
                'data' => $this->url()->fromRoute('storage', ['type' => 'user-cover', 'code' => $currentUser->uuid, 'filename' => $userProfile->cover])
1837
                'data' => $this->url()->fromRoute('storage', ['type' => 'user-cover', 'code' => $currentUser->uuid, 'filename' => $userProfile->cover],['force_canonical' => true])
Línea 1838... Línea 1838...
1838
 
1838
 
1839
            ]);
1839
            ]);