コード例 #1
0
ファイル: Core.php プロジェクト: Nessworthy/buan
 /**
  * Returns the application login View (/core/app-login) so the user can
  * potentially gain core admin access.
  *
  * @param string $referrerUrl After a successful login, the user will be redirected here
  * @return View
  */
 public static function getLoginView($referrerUrl = null)
 {
     // Create the view
     $command = UrlCommand::create('/core/app-login');
     $view = $command->execute();
     $view->refererUrl = $referrerUrl;
     // Result
     return $view;
 }
コード例 #2
0
ファイル: View.php プロジェクト: Nessworthy/buan
 /**
  * Executes the "/global-view" UrlCommand, stores the resulting View in the
  * cached self::$globalView property and returns it.
  *
  * @return View
  */
 public static function getGlobalView()
 {
     if (self::$globalView === null) {
         $gvCommand = UrlCommand::create('/global-view');
         self::$globalView = $gvCommand->execute();
     }
     return self::$globalView;
 }