Process CSV file with users data, this will create/update users, enrol them into courses, etc.
More...
|
| __construct (\csv_import_reader $cir, string $progresstrackerclass=null) |
| process constructor.
|
|
| get_bulk () |
| Setting to select for bulk actions (not available in CLI)
|
|
| get_file_columns () |
| Returns the list of columns in the file.
|
|
| get_stats () |
| Summary about the whole process (how many users created, skipped, updated, etc)
|
|
| process () |
| Process the CSV file.
|
|
| process_line (array $line) |
| Process one line from CSV file.
|
|
| set_form_data (\stdClass $formdata) |
| Set data from the form (or from CLI options)
|
|
|
profile_field_base[] | $allprofilefields = [] |
|
array | $ccache = [] |
| course cache - do not fetch all courses here, we will not probably use them all anyway
|
|
csv_import_reader | $cir |
|
array | $cohorts = [] |
|
int | $deleteerrors = 0 |
|
int | $deletes = 0 |
|
array | $filecolumns = null |
|
stdClass | $formdata |
|
array | $manualcache = [] |
| cache of used manual enrol plugins in each course
|
|
enrol_plugin null | $manualenrol = null |
|
array | $profilefields = [] |
|
string uu_progress_tracker null | $progresstrackerclass = null |
|
int | $renameerrors = 0 |
|
int | $renames = 0 |
|
array | $rolecache = [] |
| Course roles lookup cache.
|
|
array | $standardfields = [] |
|
array | $supportedauths = [] |
| officially supported plugins that are enabled
|
|
array | $sysrolecache = [] |
| System roles lookup cache.
|
|
int | $today |
|
uu_progress_tracker | $upt |
|
int | $userserrors = 0 |
|
int | $usersnew = 0 |
|
int | $usersskipped = 0 |
|
int | $usersupdated = 0 |
|
int | $usersuptodate = 0 |
| /not printed yet anywhere
|
|
int | $weakpasswords = 0 |
|
Process CSV file with users data, this will create/update users, enrol them into courses, etc.
- Copyright
- 2020 Moodle
- License
- http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
◆ __construct()
tool_uploaduser\process::__construct |
( |
\csv_import_reader | $cir, |
|
|
string | $progresstrackerclass = null ) |
process constructor.
- Parameters
-
- Exceptions
-
◆ get_allow_deletes()
tool_uploaduser\process::get_allow_deletes |
( |
| ) |
|
|
protected |
Setting to allow deletes.
- Return values
-
◆ get_allow_email_duplicates()
tool_uploaduser\process::get_allow_email_duplicates |
( |
| ) |
|
|
protected |
Setting to allow email duplicates.
- Return values
-
◆ get_allow_renames()
tool_uploaduser\process::get_allow_renames |
( |
| ) |
|
|
protected |
Setting to allow deletes.
- Return values
-
◆ get_allow_suspends()
tool_uploaduser\process::get_allow_suspends |
( |
| ) |
|
|
protected |
Setting to allow suspends.
- Return values
-
◆ get_bulk()
tool_uploaduser\process::get_bulk |
( |
| ) |
|
Setting to select for bulk actions (not available in CLI)
- Return values
-
◆ get_create_paswords()
tool_uploaduser\process::get_create_paswords |
( |
| ) |
|
|
protected |
Setting to allow create passwords.
- Return values
-
◆ get_file_columns()
tool_uploaduser\process::get_file_columns |
( |
| ) |
|
Returns the list of columns in the file.
- Return values
-
◆ get_match_on_email()
tool_uploaduser\process::get_match_on_email |
( |
| ) |
|
|
protected |
Setting to allow matching user accounts on email.
- Return values
-
◆ get_normalise_user_names()
tool_uploaduser\process::get_normalise_user_names |
( |
| ) |
|
|
protected |
Setting to normalise user names.
- Return values
-
◆ get_operation_type()
tool_uploaduser\process::get_operation_type |
( |
| ) |
|
|
protected |
Operation type.
- Return values
-
◆ get_reset_passwords()
tool_uploaduser\process::get_reset_passwords |
( |
| ) |
|
|
protected |
Setting for reset password.
- Return values
-
int | UU_PWRESET_NONE, UU_PWRESET_WEAK, UU_PWRESET_ALL |
◆ get_stats()
tool_uploaduser\process::get_stats |
( |
| ) |
|
Summary about the whole process (how many users created, skipped, updated, etc)
- Return values
-
◆ get_string_yes_no()
tool_uploaduser\process::get_string_yes_no |
( |
| $value | ) |
|
|
protected |
Helper method to return Yes/No string.
- Parameters
-
- Return values
-
◆ get_update_passwords()
tool_uploaduser\process::get_update_passwords |
( |
| ) |
|
|
protected |
Setting to allow update passwords.
- Return values
-
◆ get_update_type()
tool_uploaduser\process::get_update_type |
( |
| ) |
|
|
protected |
Setting for update type.
- Return values
-
◆ prepare_user_record()
tool_uploaduser\process::prepare_user_record |
( |
array | $line | ) |
|
|
protected |
Prepare one line from CSV file as a user record.
- Parameters
-
- Return values
-
◆ process_line()
tool_uploaduser\process::process_line |
( |
array | $line | ) |
|
Process one line from CSV file.
- Parameters
-
- Exceptions
-
◆ set_form_data()
tool_uploaduser\process::set_form_data |
( |
\stdClass | $formdata | ) |
|
Set data from the form (or from CLI options)
- Parameters
-
The documentation for this class was generated from the following file:
- admin/tool/uploaduser/classes/process.php