Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

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

Rev 3335 Rev 3349
Línea 256... Línea 256...
256
            $currentUserPlugin = $this->plugin('currentUserPlugin');
256
            $currentUserPlugin = $this->plugin('currentUserPlugin');
257
            $currentUser = $currentUserPlugin->getUser();
257
            $currentUser = $currentUserPlugin->getUser();
Línea 258... Línea 258...
258
            
258
            
259
            $code = $this->params()->fromRoute('code');
259
            $code = $this->params()->fromRoute('code');
-
 
260
            $type = $this->params()->fromRoute('type');
-
 
261
            $user = $this->params()->fromQuery('user');
-
 
262
            
-
 
263
            if(!$user) {
-
 
264
                $response = [
-
 
265
                    'success' => false,
-
 
266
                    'data' => 'ERROR_UNAUTHORIZED'
-
 
267
                ];
-
 
268
                
-
 
269
                return new JsonModel($response);
Línea 260... Línea 270...
260
            $type = $this->params()->fromRoute('type');
270
            }
Línea 337... Línea 347...
337
                        
347
                        
Línea -... Línea 348...
-
 
348
                        
-
 
349
                        
-
 
350
                    }
-
 
351
                  
-
 
352
                } else {
-
 
353
                    
-
 
354
                    if($currentUserPlugin->hasIdentity()) {
-
 
355
                        $this->layout()->setTemplate('layout/layout.phtml');
-
 
356
                    } else {
-
 
357
                        $this->layout()->setTemplate('layout/share.phtml');
338
                        
358
                    }
Línea 339... Línea 359...
339
                        
359
                    $viewModel = new ViewModel();
Línea 376... Línea 396...
376
                        } else {
396
                        } else {
377
                            $share_image =  $base_share_image . '/images/post/' . $post->uuid . '/' . $post->image;
397
                            $share_image =  $base_share_image . '/images/post/' . $post->uuid . '/' . $post->image;
Línea 378... Línea 398...
378
                            
398
                            
379
                        }
399
                        }
-
 
400
                    }
-
 
401
                } else {
-
 
402
                    
-
 
403
                    if($currentUserPlugin->hasIdentity()) {
-
 
404
                        $this->layout()->setTemplate('layout/layout.phtml');
-
 
405
                    } else {
-
 
406
                        $this->layout()->setTemplate('layout/share.phtml');
-
 
407
                    }
-
 
408
                    $viewModel = new ViewModel();
-
 
409
                    $viewModel->setTemplate('leaders-linked/error/404.phtml');
380
                    }
410
                    return $viewModel;            
381
                }
411
                }
Línea 382... Línea 412...
382
            }
412
            }
Línea 383... Línea -...
383
           
-
 
384
            $share_url = $this->url()->fromRoute('share-callback', ['type' => $type, 'code' => $code ], ['force_canonical' => true, 'query' => ['user' => $currentUser->uuid]]);
-
 
Línea -... Línea 413...
-
 
413
           
-
 
414
            $share_url = $this->url()->fromRoute('share-callback', ['type' => $type, 'code' => $code ], ['force_canonical' => true, 'query' => ['user' => $currentUser->uuid]]);
-
 
415
            
385
            
416
            
-
 
417
            
386
            
418
            if($currentUserPlugin->hasIdentity()) {
387
 
419
                $this->layout()->setTemplate('layout/layout.phtml');
388
            
420
            } else {
389
            
421
                $this->layout()->setTemplate('layout/share.phtml');
390
            $this->layout()->setTemplate('layout/share.phtml');
422
            }
391
            $viewModel = new ViewModel();
423
            $viewModel = new ViewModel();
392
            $viewModel->setTemplate('leaders-linked/home/share.phtml');
424
            $viewModel->setTemplate('leaders-linked/home/share.phtml');
393
            $viewModel->setVariables([
-
 
-
 
425
            $viewModel->setVariables([
394
                'share_image' => $share_image,
426
                'share_image' => $share_image,
Línea 395... Línea 427...
395
                'share_url' => $share_url,
427
                'share_url' => $share_url,
Línea 421... Línea 453...
421
            $currentUserPlugin = $this->plugin('currentUserPlugin');
453
            $currentUserPlugin = $this->plugin('currentUserPlugin');
Línea 422... Línea 454...
422
           
454
           
423
            
455
            
424
            $code = $this->params()->fromRoute('code');
-
 
-
 
456
            $code = $this->params()->fromRoute('code');
Línea 425... Línea 457...
425
            $type = $this->params()->fromRoute('type');
457
            $type = $this->params()->fromRoute('type');
426
            $user = $this->params()->fromQuery('user');
458