Proyectos de Subversion LeadersLinked - Backend

Rev

Rev 12327 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 12327 Rev 15351
Línea 80... Línea 80...
80
 
80
 
81
        
81
        
82
        $currentUserPlugin = $this->plugin('currentUserPlugin');
82
        $currentUserPlugin = $this->plugin('currentUserPlugin');
-
 
83
        $currentUser = $currentUserPlugin->getUser();
-
 
84
        $currentCompany = $currentUserPlugin->getCompany();
-
 
85
        
-
 
86
        
-
 
87
        $currentNetworkPlugin = $this->plugin('currentNetworkPlugin');
83
        $currentUser = $currentUserPlugin->getUser();
88
        $network = $currentNetworkPlugin->getNetwork();
84
        $currentCompany = $currentUserPlugin->getCompany();
89
        
Línea 85... Línea 90...
85
        $group_uuid =  $this->params()->fromRoute('group_id');
90
        $group_uuid =  $this->params()->fromRoute('group_id');
Línea 195... Línea 200...
195
                
200
                
Línea 196... Línea 201...
196
                $items = [];
201
                $items = [];
Línea 197... Línea -...
197
            
-
 
198
                $records = $paginator->getCurrentItems();
-
 
199
               
-
 
200
 
-
 
201
                $sandbox = $this->config['leaderslinked.runmode.sandbox'];
-
 
202
                if($sandbox) {
-
 
203
                    $company_profile_url = $this->config['leaderslinked.frontend.sandbox_company_profile'];
-
 
204
                    $user_profile_url = $this->config['leaderslinked.frontend.sandbox_user_profile'];
-
 
205
                    
-
 
206
                } else {
-
 
Línea 207... Línea 202...
207
                    $company_profile_url = $this->config['leaderslinked.frontend.production_company_profile'];
202
            
208
                    $user_profile_url = $this->config['leaderslinked.frontend.production_user_profile'];
203
                $records = $paginator->getCurrentItems();
Línea 226... Línea 221...
226
                    $dt = \DateTime::createFromFormat('Y-m-d H:i:s', $record->added_on);
221
                    $dt = \DateTime::createFromFormat('Y-m-d H:i:s', $record->added_on);
227
                    $item = [
222
                    $item = [
228
                        'title' => $record->title,
223
                        'title' => $record->title,
229
                        'author' => [
224
                        'author' => [
230
                            'user_name' => $user->first_name . ' ' . $user->last_name,
225
                            'user_name' => $user->first_name . ' ' . $user->last_name,
231
                            'user_url' =>  str_replace('[uuid]', $user->uuid, $user_profile_url),
226
                            'user_url' => 'https://'. $network->main_hostname . '/profile/view/' . $user->uuid, 
232
                            'user_image' => $this->url()->fromRoute('storage', ['code' => $user->uuid, 'type' => 'user', 'filename' => $user->image]),
227
                            'user_image' => $this->url()->fromRoute('storage', ['code' => $user->uuid, 'type' => 'user', 'filename' => $user->image]),
233
                        ],
228
                        ],
234
                        'added_on'=> $dt->format('d/m/Y'),
229
                        'added_on'=> $dt->format('d/m/Y'),
235
                        'actions' => [
230
                        'actions' => [
236
                            'link_edit' => $allowEdit ? $this->url()->fromRoute('high-performance-teams/groups/view/foro/categories/articles/edit', ['group_id' => $group_uuid,'category_id' => $category_uuid, 'article_id' => $record->uuid]) : '',
231
                            'link_edit' => $allowEdit ? $this->url()->fromRoute('high-performance-teams/groups/view/foro/categories/articles/edit', ['group_id' => $group_uuid,'category_id' => $category_uuid, 'article_id' => $record->uuid]) : '',