|
|
@@ -10,7 +10,7 @@ class StationController extends Controller
|
|
|
/**
|
|
|
* Display a listing of the resource.
|
|
|
*
|
|
|
- * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Http\Response|\Illuminate\View\View
|
|
|
+ * @return void
|
|
|
*/
|
|
|
public function index()
|
|
|
{
|
|
|
@@ -18,7 +18,9 @@ class StationController extends Controller
|
|
|
}
|
|
|
public function monitorIndex()
|
|
|
{
|
|
|
- $stations = Station::query()->paginate(100);
|
|
|
+ $stations = Station::query()->with('type:name','parent:name')->whereHas('type',function($query){
|
|
|
+ $query->where('name','料箱监视器');
|
|
|
+ })->paginate(100);
|
|
|
return view('station.monitor.index',compact('stations'));
|
|
|
}
|
|
|
|
|
|
@@ -43,16 +45,14 @@ class StationController extends Controller
|
|
|
//
|
|
|
}
|
|
|
|
|
|
- /**
|
|
|
- * Display the specified resource.
|
|
|
- *
|
|
|
- * @param \App\Station $station
|
|
|
- * @return \Illuminate\Http\Response
|
|
|
- */
|
|
|
public function show(Station $station)
|
|
|
{
|
|
|
//
|
|
|
}
|
|
|
+ public function monitorShow(Station $station)
|
|
|
+ {
|
|
|
+ return view('station.monitor.show',compact('station'));
|
|
|
+ }
|
|
|
|
|
|
/**
|
|
|
* Show the form for editing the specified resource.
|