add typeahead support for owner email when adding new server
closes #144 pic: http://s3.pterodactyl.io/UpPSJ.png
This commit is contained in:
parent
f9f751b7f2
commit
bef717b202
6 changed files with 55 additions and 0 deletions
|
@ -130,4 +130,12 @@ class UserController extends Controller
|
|||
return redirect()->route('admin.users.view', $user);
|
||||
}
|
||||
|
||||
public function getJson(Request $request)
|
||||
{
|
||||
foreach(User::select('email')->get() as $user) {
|
||||
$resp[] = $user->email;
|
||||
}
|
||||
return $resp;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -73,6 +73,11 @@ class AdminRoutes {
|
|||
'uses' => 'Admin\UserController@getIndex'
|
||||
]);
|
||||
|
||||
$router->get('/accounts.json', [
|
||||
'as' => 'admin.users.json',
|
||||
'uses' => 'Admin\UserController@getJson'
|
||||
]);
|
||||
|
||||
// View Specific Account
|
||||
$router->get('/view/{id}', [
|
||||
'as' => 'admin.users.view',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue