entryComponents: [
ModalContentComponent
]
他们的实施:
Route::get('dashboard', 'MainController@dashboard')->name('dashboard');
Route::get('dashboardExtCall/{name}', 'MainController@dashboardExtCall');
问题是当我使用class MainController extends Controller
{
public function __construct()
{
$this->middleware('auth');
}
public function dashboardExtCall($name)
{
Session::put('activeUrl', $name);
return $this->dashboard();
}
public function dashboard()
{
$user = Auth::user();
//SETTING VARIABLES IN SESSION
if (!Session::has('activeUrl')) {
Session::put('activeUrl', 'appList');
}
$info = Session::get('info');
Session::forget('info');
$creditsNumber = Credits::GetCreditsNumber();
return view('dashboard\dashboard')->with([
'user' => $user,
'creditsNumber' => $creditsNumber,
'info' => $info,
]);
}
}
时,我在资源(例如图片)上收到错误405和404.
如果我改变此路线并致电dashboardExtCall/userPage
- 一切正常!
dashboardExtCall
我做错了什么?