Preparing Moodle 20/es
| Languages |
[[::Preparing Moodle 20/es|English]] |
This document applies to Joomdle Release 2.0.0
Nota: Este documento se aplica a la preparación de Joomdle con Moodle 2.0+ Si estás instalando Joomdle para Moodle 1.9+ por favor consulta este documento Preparando Moodle 1.9+ para Joomdle
Requisitos previos de Moodle 2
Si estás instalando Moodle por primera vez, éste comprobará si la extensión XML-RPC para PHP está habilitada. Por favor, asegurate de que está instalada.
Para obtener más información sobre PHP XML-RPC, consulta PHP XML-RPC Prerequisites
.
Configurando los Servicios Web de Moodle
Moodle 2.0 usa un nuevo sistema para la integración con aplicaciones externas, como Joomdle. Así, a partir de Moodle 2.0, deberás completar los pasos siguientes para integrar Joomdle con Moodle.
Para hacerlo más fácil, Moodle 2 tiene una lista de pasos que debes seguir para configurar los servicios web de Moodle. Puedes acceder aqui:
Site Administration->Plugins->Web services->Overview.
.
Activar servicios web
Enable Web Services. Cambiar estado a Sí.
.
Activar protocolos: XMLRPC
Joomdle usa XMLRPC para conectar con Moodle. Debes seleccionar el paso 2. Enable Protocols, de la lista y activa XMLRPC. Necesitarás asegurarte de que tu servidor dispone de soporte XMLRPC. Consulta Requisitos previos PHP para obtener más información.
.
Crea un usuario específico
Los servicios web de Moodle requieren de un usuario para la conexión con Joomdle.
Para configurar los servicios web de Moodle, es necesario definir un usuario específico, al que daremos los permisos adecuados para conectar con Moodle.
Idealmente, este usuario debe ser usado unicamente para conectar Joomla con Moodle. No debe usarse como usuario en Joomla o Moodle, ni debe ser un usuario administrador. Por ejemplo, nosotros creamos un usuario llamado joomdle connector.
.
Check user capability
Check user permissions
For Joomdle to connect to Moodle using Web services, a specific user must be created in Moodle, as defined above. Once defined this user must be given the appropriate access to the Web services protocol being used, XML-RPC. This is done by defining a role, assigning the user to that role and then granting that role access to the Web services. In this section, we show you how to:
- Check the permissions of existing users
- Create a new role
- Assign a specific user, eg. Joomdle Connector, to a given role
From the table click on 4. Check user capability. Select the user who you have created to be the Web services user and press the Show this user's permissions button.
Scroll down until you see XML-RPC and ensure this is set to yes. The background colour will have changed as well. In this case the background colour is light blue/green indicating it is set to yes in comparison to pink for no.
If it is not set to Yes you will need to do one or more of the following:
- Create a new role
- Assign the user to the specific role
.
Define a new role, to manage access to Joomdle Web services
To define a new role, go to Site Administration->Users->Permissions->Define roles, and click the 'Add a new role' button. Then enter a unique name, short name and description. These should be something that you will recognise relating to Joomdle services.
Then, check 'System' as Context types where this role may be assigned.
Scroll down looking through the Capability table and Allow (check):
- Use XML-RPC protocol
- View discussions
.
Assign the user to the new role
After you have created the new role, you will need to add your Joomdle Web services user (eg. joomdle connector) to this role.
Go to Users->Permissions->Assign System roles, and select the new role.
.
Add a new service
Next we must add a new "service" for Joomdle. This "service" will allow you to define what Joomdle can do inside Moodle. For example pulling course details information from Moodle or creating a new user in Moodle. This task is split into two tasks:
- Create a new service
- Defining what functions this new service can perform (See the next section)
This is done in Site Administration->Plugins->Web services->External services
Add functions to service
Normally, this would be the first time you are setting up Joomdle on this webserver. Therefore, it is assumed the Joomdle for Moodle has not been installed and you will not be able to perform this task at this time. Instead, this activity will be completed as part of the Installing Joomdle in Moodle 2.0 task.
If Joomdle has already been installed, you can perform this task now. The details of this task can be found here Add Functions to Service
.
Add user as authorized user for the service
Now that we have created a new service and added the appropriate functions (All Joomdle functions), we need to authorise / grant the Joomdle Web services 'user' to the newly created service. This is done in:
Site Administration->Plugins->Web services->External services
Click on Authorized users for the new service and add the Joomdle Web services user we created before.
.
Create token
The final step is to create a token which will be entered in Joomdle configuration page in the Joomdle Joomla component. Without this token, even if everything is configured in Moodle, Joomla and Joomdle correctly, Joomdle will not be able to connect with Moodle.
In the Moodle Administration menu:
Site Administration->Plugins->Web services->Manage tokens, click on Add.
Select the user and the service we created, and Save.
You will get a new token, to enter in Joomdle's component configuration in Joomla. Refer to this page for entering the token in Joomdle.





