From 4b158f08a80c89c15c2d5433ec7a4bb6e3556bc0 Mon Sep 17 00:00:00 2001 From: cp6 Date: Mon, 21 Feb 2022 11:57:04 +1100 Subject: [PATCH] Updated IPs controller Updated IPs controller --- app/Http/Controllers/IPsController.php | 41 +++++--------------------- 1 file changed, 8 insertions(+), 33 deletions(-) diff --git a/app/Http/Controllers/IPsController.php b/app/Http/Controllers/IPsController.php index 810d407..e9d59c1 100644 --- a/app/Http/Controllers/IPsController.php +++ b/app/Http/Controllers/IPsController.php @@ -3,6 +3,9 @@ namespace App\Http\Controllers; use App\Models\IPs; +use App\Models\Reseller; +use App\Models\Server; +use App\Models\Shared; use Illuminate\Http\Request; use Illuminate\Support\Facades\DB; @@ -11,65 +14,37 @@ class IPsController extends Controller public function index() { $ips = IPs::all(); - return view('ips.index', compact('ips')); + return view('ips.index', compact(['ips'])); } public function create() { - return view('ips.create'); + $Servers = Server::all(); + $Shareds = Shared::all(); + $Resellers = Reseller::all(); + return view('ips.create', compact(['Servers', 'Shareds', 'Resellers'])); } - /** - * Store a newly created resource in storage. - * - * @param \Illuminate\Http\Request $request - * @return \Illuminate\Http\Response - */ public function store(Request $request) { // } - /** - * Display the specified resource. - * - * @param int $id - * @return \Illuminate\Http\Response - */ public function show($id) { // } - /** - * Show the form for editing the specified resource. - * - * @param int $id - * @return \Illuminate\Http\Response - */ public function edit($id) { // } - /** - * Update the specified resource in storage. - * - * @param \Illuminate\Http\Request $request - * @param int $id - * @return \Illuminate\Http\Response - */ public function update(Request $request, $id) { // } - /** - * Remove the specified resource from storage. - * - * @param int $id - * @return \Illuminate\Http\Response - */ public function destroy($id) { //