user pane on admin dashboard
This commit is contained in:
@@ -100,24 +100,6 @@ class AdminController extends Controller
|
|||||||
array_push($userArr, $tempUser);
|
array_push($userArr, $tempUser);
|
||||||
}
|
}
|
||||||
|
|
||||||
//Get the users from the database to allow a selection of users for various parts of the webpage
|
|
||||||
$users = User::pluck('name')->all();
|
|
||||||
//Get the available permissions from the database to allow a selection of permissions
|
|
||||||
$permissions = AvailableUserPermission::pluck('permission')->all();
|
|
||||||
|
|
||||||
foreach($users as $key => $value) {
|
|
||||||
$user[$value] = $value;
|
|
||||||
}
|
|
||||||
//Create the permission key value pairs
|
|
||||||
foreach($permissions as $key => $value) {
|
|
||||||
$permission[$value] = $value;
|
|
||||||
}
|
|
||||||
//Create the data array
|
|
||||||
$data = [
|
|
||||||
'users' => $user,
|
|
||||||
'permissions' => $permission,
|
|
||||||
];
|
|
||||||
|
|
||||||
/** Entities for allowed logins */
|
/** Entities for allowed logins */
|
||||||
$legacys = AllowedLogin::where(['login_type' => 'Legacy'])->pluck('entity_name')->toArray();
|
$legacys = AllowedLogin::where(['login_type' => 'Legacy'])->pluck('entity_name')->toArray();
|
||||||
$renters = AllowedLogin::where(['login_type' => 'Renter'])->pluck('entity_name')->toArray();
|
$renters = AllowedLogin::where(['login_type' => 'Renter'])->pluck('entity_name')->toArray();
|
||||||
@@ -129,8 +111,7 @@ class AdminController extends Controller
|
|||||||
$entities[] = $renter;
|
$entities[] = $renter;
|
||||||
}
|
}
|
||||||
|
|
||||||
return view('admin.dashboard')->with('data', $data)
|
return view('admin.dashboard')->with('userArr', $userArr)
|
||||||
->with('userArr', $userArr)
|
|
||||||
->with('pis', $pis)
|
->with('pis', $pis)
|
||||||
->with('industrys', $industrys)
|
->with('industrys', $industrys)
|
||||||
->with('offices', $offices)
|
->with('offices', $offices)
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
</ul>
|
</ul>
|
||||||
<br>
|
<br>
|
||||||
<div class="tab-content">
|
<div class="tab-content">
|
||||||
<div id="user" class="tab-pane fade">
|
<div id="user" class="tab-pane active">
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
|
|||||||
Reference in New Issue
Block a user