Owl\Services\UserService::getCurrentUser PHP Метод

getCurrentUser() публичный Метод

public getCurrentUser ( ) : stdclass
Результат stdclass | bool
    public function getCurrentUser()
    {
        if (\Session::has('User')) {
            $user = \Session::get('User');
            return $user[0];
        }
        return false;
    }

Usage Example

Пример #1
0
 /**
  * Configに合わせてメール通知HTMLコンポーネントを返す
  *
  * @return View | null
  */
 protected function renderHtml()
 {
     if ($this->notifyEnable) {
         $notifyFlags = $this->mailNotifyService->getSettings($this->userService->getCurrentUser()->id);
         return view('user.edit._mail-notify', compact('notifyFlags'))->render();
     }
     return null;
 }
All Usage Examples Of Owl\Services\UserService::getCurrentUser