Remove SakaiBLTIUtil.addTIIproperties in basiclti

Description

Immediately before addTIIproperties is called, LTI2Util.addCustomToLaunch is invoked. The former copies the turnitin specific keys over verbatim while the latter copies the custom lti properties over, prefixing each key with "custom_".

Ie. addTIIproperties copies "custom_startdate" -> "custom_startdate"
LTI2Util.addCustomToLaunch copies "custom_startdate" -> "custom_custom_startdate".

To fix this, modify the code that sets up these custom properties to omit the "custom_" prefix when they're inserted into lti_content, then just trust LTI2UTIL.addCustomToLaunch to do its job

If sites have already used the Turnitin LTI integration, the following conversions will be required. Firstly, check your LTI_CONTENT table to determine if the custom column is semicolon or new line delimited (I've seen semicolon while working against Sakai 10.3, and new line while working against early 11.x):
MySql:

UPDATE LTI_CONTENT SET CUSTOM = REPLACE(CUSTOM, ';custom_', ';') WHERE tool_id in (select id from lti_tools where SITE_ID in ('!turnitin', '!turnitin_reports')); -- OR -- UPDATE LTI_CONTENT SET CUSTOM = REPLACE(CUSTOM, '\ncustom_', '\n') WHERE tool_id in (select id from lti_tools where SITE_ID in ('!turnitin', '!turnitin_reports'));

Oracle:

UPDATE LTI_CONTENT SET CUSTOM = REPLACE(LTI_CONTENT.CUSTOM, ';custom_', ';') WHERE tool_id in (select id from lti_tools where SITE_ID in ('!turnitin', '!turnitin_reports')); -- OR (untested) --- UPDATE LTI_CONTENT SET CUSTOM = REPLACE(LTI_CONTENT.CUSTOM, '\ncustom_', '\n') WHERE tool_id in (select id from lti_tools where SITE_ID in ('!turnitin', '!turnitin_reports'));

Activity

Show:

Brian J. January 19, 2017 at 3:27 PM

Git commits cebef9d, d08891f

Fixed

Details

Assignee

Reporter

Conversion Script Required

Yes

Components

Fix versions

Priority

Created January 19, 2017 at 9:57 AM
Updated January 19, 2017 at 3:27 PM
Resolved January 19, 2017 at 3:27 PM

Flag notifications