85 lines
1.8 KiB
PHP
85 lines
1.8 KiB
PHP
<?php
|
|
|
|
namespace App\Http\Controllers\Auth;
|
|
|
|
use App\Http\Controllers\Controller;
|
|
use Illuminate\Foundation\Auth\AuthenticatesUsers;
|
|
|
|
class LoginController extends Controller
|
|
{
|
|
/*
|
|
|--------------------------------------------------------------------------
|
|
| Login Controller
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
| This controller handles authenticating users for the application and
|
|
| redirecting them to your home screen. The controller uses a trait
|
|
| to conveniently provide its functionality to your applications.
|
|
|
|
|
*/
|
|
|
|
use AuthenticatesUsers{
|
|
showLoginForm as traitShowLoginForm;
|
|
}
|
|
|
|
/**
|
|
* Where to redirect users after login.
|
|
*
|
|
* @var string
|
|
*/
|
|
protected $redirectTo = '/home';
|
|
|
|
/**
|
|
* Create a new controller instance.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function __construct()
|
|
{
|
|
$this->middleware('guest')->except('logout');
|
|
}
|
|
|
|
/**
|
|
* Show the application's login form.
|
|
*
|
|
* @return \Illuminate\Http\Response
|
|
*/
|
|
public function showLoginForm()
|
|
{
|
|
// return view('auth.login');
|
|
// return $this->traitShowLoginForm();
|
|
return view('auth.login');
|
|
}
|
|
|
|
/**
|
|
* 顯示接案者的登入表單
|
|
*
|
|
* @return \Illuminate\Http\Response
|
|
*/
|
|
public function showReceiverLoginForm()
|
|
{
|
|
return $this->showLoginForm();
|
|
}
|
|
|
|
/**
|
|
* 顯示發案者的登入表單
|
|
*
|
|
* @return \Illuminate\Http\Response
|
|
*/
|
|
public function showCaseBuilderLoginForm()
|
|
{
|
|
return $this->showLoginForm();
|
|
}
|
|
|
|
/**
|
|
* 顯示網站管理者的登入表單
|
|
*
|
|
* @return \Illuminate\Http\Response
|
|
*/
|
|
public function showAdminLoginForm()
|
|
{
|
|
return $this->showLoginForm();
|
|
}
|
|
|
|
}
|