Users that have Spanish configured on their Moodle site have reported that the CV launch and the EULA redirect page doesn't open in Spanish, but English instead. Upon further examination, it looks like Moodle Integrity doesn't currently have support for Spanish and many other languages like French, Swedish, Chinese, etc. This is what's causing the CV to launch in English even if the Moodle site is set to a different language.
The redirect to the EULA disclaimer is a static html page. Ex: https://static.turnitin.com/eula/v1beta/en-us/eula.html
This is returned by the plugin making a call to TCA's /api/v1/eula/latest endpoint which returns the url above. This url gets stored in the site's config to be referenced again and again to avoid making multiple calls to the endpoint.
The original design to accommodate other languages includes a query parameter (ex:?lang=es-MX) gets attached to the end of the url; however this does not work.
Issue:
Moodle Integrity Plugin doesn't launch the CV in the same language that a user has selected on the Moodle site. The plugin also is missing many other language codes for multiple language support.
TCA's url response for the static EULA page that gets stored is the English page, and attaching a language query parameter to this url does not work as intended. The query parameter is being attached to the wrong place. It is being attached to the returning url rather than the endpoint making the TCA request.
Solution:
CV Launch: Added all supported language codes per Product Team's request
EULA Redirect: Updated the call to TCA to accommodate a different language so that the url repsonse from TCA is respective to the language use in the Moodle site. Ex: if Moodle site is in Spanish (es-MX), the static url is https://static.turnitin.com/eula/v1beta/es-mx/eula.html.
The updated endpoint now includes a language query parameter which will return the proper static EULA page in the corresponding language.
Background info:
Users that have Spanish configured on their Moodle site have reported that the CV launch and the EULA redirect page doesn't open in Spanish, but English instead. Upon further examination, it looks like Moodle Integrity doesn't currently have support for Spanish and many other languages like French, Swedish, Chinese, etc. This is what's causing the CV to launch in English even if the Moodle site is set to a different language.
The redirect to the EULA disclaimer is a static html page. Ex:
https://static.turnitin.com/eula/v1beta/en-us/eula.html
This is returned by the plugin making a call to TCA's/api/v1/eula/latest
endpoint which returns the url above. This url gets stored in the site's config to be referenced again and again to avoid making multiple calls to the endpoint. The original design to accommodate other languages includes a query parameter (ex:?lang=es-MX
) gets attached to the end of the url; however this does not work.Issue:
Moodle Integrity Plugin doesn't launch the CV in the same language that a user has selected on the Moodle site. The plugin also is missing many other language codes for multiple language support.
TCA's url response for the static EULA page that gets stored is the English page, and attaching a language query parameter to this url does not work as intended. The query parameter is being attached to the wrong place. It is being attached to the returning url rather than the endpoint making the TCA request.
Solution:
CV Launch: Added all supported language codes per Product Team's request
EULA Redirect: Updated the call to TCA to accommodate a different language so that the url repsonse from TCA is respective to the language use in the Moodle site. Ex: if Moodle site is in Spanish (es-MX), the static url is
https://static.turnitin.com/eula/v1beta/es-mx/eula.html
. The updated endpoint now includes a language query parameter which will return the proper static EULA page in the corresponding language.