middleware('auth'); } /** * Show the application dashboard. * * @return \Illuminate\Contracts\Support\Renderable */ public function index() { if(!Gate::allows('退货管理-查询')){ if(!Gate::allows('运输管理-运单-查询')){ return view('home');} return view("home"); } return redirect(url('rejected/index/general')); } public function home() { return view('home'); } public function help() { $filePath = base_path('文档/SystemHandBook.md'); $read = @file_get_contents($filePath); $read = str_replace(["\r","\n",'"'],["\\r",'\\n',"'"],$read); return view("help",compact("read")); } }