UsersAdminController
class UsersAdminController extends BaseAdminController
The UsersAdminController class is the controller that handles all actions of the users management interface.
These actions are:
- Creation of a user
- Modification of a user
- Deletion of a user
- Restoring a user after its deletion
All these actions are requested in Ajax by the Javascript Tabledit component
Properties
ControllersHelper | $helper | from BaseAdminController | |
string | $databasesDir | from BaseAdminController | |
string | $simulatorsDir | from BaseAdminController | |
string | $publicDir | from BaseAdminController | |
string | $viewsDir | from BaseAdminController |
Methods
Returns a JSON response formed with the data of a form and an error message.
Entry point for the route paths begining by /admin/users
Dispatches the index action to the appropriate processing based on the value of the crud parameter.
Creates a user with the data in the form fields.
Restores a user with the data in the form fields.
Updates a user with the data in the form fields.
Realizes the update of the user database via FOSUserBundle with the data in the form fields.
Deletes a user with the data in the form fields.
Details
in BaseAdminController at line 93
protected Response
errorResponse(array $form, string $error)
Returns a JSON response formed with the data of a form and an error message.
in BaseAdminController at line 113
protected
zip(array $contents)
Zip file creation function.
Makes zip files. Derivated from PhpMyAdmin package The $contents parameter is an array of associative array where keys are : - name: name of the zip - modtime: modification time - data: data to compress
in BaseAdminController at line 188
protected int
unix2DosTime(int $unixtime)
Converts unix time to MS DOS time
at line 70
Response
indexAction(Request $request, string|null $crud = null)
Entry point for the route paths begining by /admin/users
These route paths are :
- /admin/users
- /admin/users/{crud}
at line 86
protected Response
runIndex(Request $request, string|null $crud)
Dispatches the index action to the appropriate processing based on the value of the crud parameter.
If the crud parameter contains no value, shows the users management interface.
at line 144
protected Response
addUser(array $form)
Creates a user with the data in the form fields.
Route path : /admin/users/add
at line 158
protected Response
restoreUser(array $form)
Restores a user with the data in the form fields.
Route path : /admin/users/restore
at line 172
protected Response
updateUser(array $form)
Updates a user with the data in the form fields.
Route path : /admin/users/update
at line 190
protected Response
doUpdateUser(array $form, bool $newUser = false, bool $restore = false)
Realizes the update of the user database via FOSUserBundle with the data in the form fields.
at line 271
protected Response
deleteUser(array $form)
Deletes a user with the data in the form fields.
Route path : /admin/users/delete