class UserController extends Controller

Traits

AuthorizesRequests
ValidatesRequests

Methods

bool
isAutomatedRequest(Request $request = null)

Determines if the request was done by an automated script (with API token or ajax).

RedirectResponse
fuzzyRedirect()

Redirects to the _redirect URL, to a route or else back.

__construct()

Creates a new UserController instance.

Collection
find(string $pattern)

Finds all users with firstnames or lastnames like $pattern.

Collection
index(Request $request)

Shows a list of all users.

show(int $id)

Shows the specified user.

showOwn(Request $request)

Shows the requesting user.

RedirectResponse|null
update(UpdateUser $request)

Updates the attributes of the specified user.

RedirectResponse|null
updateOwn(UpdateOwnUser $request)

Updates the attributes of the own user.

User|RedirectResponse
store(StoreUser $request)

Creates a new user.

RedirectResponse|null
destroy(DestroyUser $request)

Removes the specified user.

RedirectResponse|null
destroyOwn(DestroyOwnUser $request)

Removes the own user.

Details

in Controller at line 21
bool isAutomatedRequest(Request $request = null)

Determines if the request was done by an automated script (with API token or ajax).

Parameters

Request $request

Return Value

bool

in Controller at line 15
protected RedirectResponse fuzzyRedirect()

Redirects to the _redirect URL, to a route or else back.

Return Value

RedirectResponse

at line 21
__construct()

Creates a new UserController instance.

at line 62
Collection find(string $pattern)

Finds all users with firstnames or lastnames like $pattern.

Returns the first 10 results.

Parameters

string $pattern

Return Value

Collection

at line 103
Collection index(Request $request)

Shows a list of all users.

Parameters

Request $request

Return Value

Collection

at line 137
User show(int $id)

Shows the specified user.

Parameters

int $id

Return Value

User

at line 173
User showOwn(Request $request)

Shows the requesting user.

Parameters

Request $request

Return Value

User

at line 209
RedirectResponse|null update(UpdateUser $request)

Updates the attributes of the specified user.

Parameters

UpdateUser $request

Return Value

RedirectResponse|null

at line 270
RedirectResponse|null updateOwn(UpdateOwnUser $request)

Updates the attributes of the own user.

Parameters

UpdateOwnUser $request

Return Value

RedirectResponse|null

at line 333
User|RedirectResponse store(StoreUser $request)

Creates a new user.

Parameters

StoreUser $request

Return Value

User|RedirectResponse

at line 380
RedirectResponse|null destroy(DestroyUser $request)

Removes the specified user.

Parameters

DestroyUser $request

Return Value

RedirectResponse|null

at line 409
RedirectResponse|null destroyOwn(DestroyOwnUser $request)

Removes the own user.

Parameters

DestroyOwnUser $request

Return Value

RedirectResponse|null