Subir cursos
Nota: Pendiente de Traducir. ¡Anímese a traducir esta página!. ( y otras páginas pendientes)
Moodle 2.6
Un administrador puede subir múltiples cursos empleando un archivo de texto.
Hay muchas cosas que pueden hacerse empleando esta herramienta; no solamente crear cursos, también actualizarlos o eliminarlos. usted también puede actualizar los métodos para inscripción al curso o importar el contenido de otro curso.
Subir el archivo
Usted puede subir el archivo al navegar hacia Administración > Administración del sitio > Cursos > Subir cursos y allí puede arrastrar y colocar el archivo CSV o elegir el botón para subirlo desde el selector de archivos.
Nota: también es posible utilizar la herramienta por línea de comando admin/tool/uploadcourse/cli/uploadcourse.php.
Al usar la interfase web, use el botón para Vista previa para ver si se detectaron errores en las filas pre-visualizadas. Si Usted continúa con la subida y hubiera algún error detectado dentro de un curso, será ignorado.
Crear el archivo de texto
The text file to upload courses must be a CSV file. It accepts the following columns which are divided in two categories, the course information, and the course actions.
Campos de información del curso
Most of those settings are available on the settings page of a course. Please refer to Course settings for more information.
- shortname
- The shortname
- fullname
- The full name
- idnumber
- The ID number
- category
- The ID of the category to place the course in. This takes precedence over category_idnumber and category_path.
- category_idnumber
- The ID number of the category to place the course in. This takes precedence over category_path.
- category_path
- The path of the category to place the course in. If you want to place the course in a category named "Science-Fiction" which is located under the category "Movies", the value to provide is:
Movies > Science-Fiction
. Note that the separator must be[space]>[space]
. Also note that the category MUST exist, it will not be created. - visible
- 1 if the course is visible, 0 if hidden
- startdate
- The time at which the course starts. Please note that this value is passed to the PHP function strtotime to generate a timestamp.
- summary
- The summary of the course
- format
- The course format to use, this must be a valid course format plugin name. E.g. weeks, topics.
- theme
- The theme to use
- lang
- The language to use
- newsitems
- The number of news items
- showgrades
- 1 to show the gradebook to students, 0 to hide it.
- showreports
- 1 to show the activity reports, 0 to hide it.
- legacyfiles
- 1 to enable the legacy course files, 0 not to.
- maxbytes
- The maximum upload size of the course in bytes. Use 0 for the site limit.
- groupmode
- 0 for No groups, 1 for Separate groups and 2 for Visible groups.
- groupmodeforce
- 1 to force the group mode, otherwise enter 0.
- enablecompletion
- 1 to enable the activity completion, 0 not to.
Campos de inscripción
Some fields can be constructed to enable and configure enrolment methods. The fields must be named enrolment_[number] for the enrolment method name, and enrolment_[number]_property for its properties.
- enrolment_[number]
- The name of the enrolment method
- enrolment_[number]_delete
- 1 to delete this enrolment method from the course, if set to 1 all the other properties will be ignored.
- enrolment_[number]_disable
- 1 to disable this enrolment method from the course, if set to 1 all the other properties will be ignored.
- enrolment_[number]_startdate
- The enrolment start date. This value is passed to the PHP function strtotime().
- enrolment_[number]_enddate
- The enrolment start date. This value is passed to the PHP function strtotime().
- enrolment_[number]_enrolperiod
- Number of seconds, or if not a value understood by strtotime() such as "4 days".
- enrolment_[number]_role
- The role short name
- enrolment_[number]_[property]
- Where property is understood by the specified enrolment method
Example
enrolment_1: manual enrolment_1_role: student enrolment_1_enrolperiod: 1 month enrolment_2: self enrolment_2_startdate: 2013-01-30
Renombrar roles
To rename some roles, using the following pattern:
- role_[shortname]
- The new name of the role [shortname].
Example
role_student: Apprentice role_teacher: Master role_mycustomrole: Jedi
Campos de acción del curso
Those settings take precedence over the Course process parameters.
- delete
- 1 to delete the course
- rename
- The shortname to rename the course to
- backupfile
- An absolute path to a backup file (.mbz) to import in the course
- templatecourse
- The short name of a course to import the content from
- reset
- 1 to reset the course
Campos obligatorios
- shortname
- This field is mandatory for every operation, with the only exception of creating new courses. See details on the course process parameter Shortname template for more information.
- fullname
- Required when creating a new course.
- category, category_idnumber, category_path
- One of these is required when creating a course.
Opciones para importar
To prevent unexpected behaviours, you have to specify what you want the tool to be able to do.
- Upload mode
- This allows you to specify if courses can be created and/or updated.
- Update mode
- If you allow courses to be updated, you also have to tell the tool what to update the courses with.
- Allow deletes
- Whether the delete field is accepted or not
- Allow renames
- Whether the rename field is accepted or not
- Allow resets
- Whether the reset field is accepted or not
Proceso del curso
This allows you to specify actions to be taken on every single courses uploaded.
- Shortname template
- If you are creating courses without a shortname, you can use this field to automatically generate a shortname. This field accepts two placeholders: %i for the ID number, %f for the summary.
- Restore file
- A backup file (.mbz) to import in the course after create/update.
- Restore from course
- The shortname of a course to import content from after create/update.
- Reset after upload
- Whether to reset the course after creating/updating it.
Valores por defecto del curso
Those are values that can be set in the web interface for all the fields that are not specified in the CSV file. Note that they are always used when creating a course, but only when specified during update (see Update mode).
Aumentar velocidad
When importing the content of a backup file, or another course, you are adviced to enable the setting keeptempdirectoriesonbackup. This will considerably speed up the process of the upload if you are importing multiple times from the same source.