Index: lams_build/lib/lams/lams.jar =================================================================== diff -u -r63f2e6dbe3e641bd979943d367cab4bd1387aa61 -r6bab0092cf83dde3950e5626d9e832f9cfc00db0 Binary files differ Index: lams_common/src/java/org/lamsfoundation/lams/learningdesign/service/LD102Importer.java =================================================================== diff -u -rfa5eb10796d2b7d6bf2f15b0a96abac6b2fe47f1 -r6bab0092cf83dde3950e5626d9e832f9cfc00db0 --- lams_common/src/java/org/lamsfoundation/lams/learningdesign/service/LD102Importer.java (.../LD102Importer.java) (revision fa5eb10796d2b7d6bf2f15b0a96abac6b2fe47f1) +++ lams_common/src/java/org/lamsfoundation/lams/learningdesign/service/LD102Importer.java (.../LD102Importer.java) (revision 6bab0092cf83dde3950e5626d9e832f9cfc00db0) @@ -747,6 +747,11 @@ if ( activity.getTitle() == null && keyExists(taskDetails, WDDXTAGS102.TITLE)) activity.setTitle(WDDXProcessor.convertToString(taskDetails,WDDXTAGS102.TITLE)); + // define later will have already been set up for tool activities + if ( activity.getDefineLater() == null ) { + activity.setDefineLater(Boolean.FALSE); + } + activity.setXcoord(xCoOrd); activity.setYcoord(yCoOrd); activity.setHelpText(null); Index: lams_common/src/java/org/lamsfoundation/lams/tool/ToolContentImport102Manager.java =================================================================== diff -u -rfa5eb10796d2b7d6bf2f15b0a96abac6b2fe47f1 -r6bab0092cf83dde3950e5626d9e832f9cfc00db0 --- lams_common/src/java/org/lamsfoundation/lams/tool/ToolContentImport102Manager.java (.../ToolContentImport102Manager.java) (revision fa5eb10796d2b7d6bf2f15b0a96abac6b2fe47f1) +++ lams_common/src/java/org/lamsfoundation/lams/tool/ToolContentImport102Manager.java (.../ToolContentImport102Manager.java) (revision 6bab0092cf83dde3950e5626d9e832f9cfc00db0) @@ -35,8 +35,9 @@ * as supporting one of the 1.0.2 tool must implement this interface otherwise * an exception will be thrown. */ -import java.util.Map; +import java.util.Hashtable; +import org.lamsfoundation.lams.tool.exception.DataMissingException; import org.lamsfoundation.lams.tool.exception.ToolException; public interface ToolContentImport102Manager { @@ -95,7 +96,11 @@ public static final String CONTENT_URL_URL_TYPE= "resourcetype"; // see URLContent TYPE_* fields public static final String CONTENT_URL_URL_INSTRUCTION_ARRAY = "instructions"; public static final String CONTENT_URL_INSTRUCTION = "instruction"; - + + public static final String URL_RESOURCE_TYPE_WEBSITE = "internalurl"; // Uploaded website - will be missing its files. + public static final String URL_RESOURCE_TYPE_FILE = "file"; // Uploaded file - will be missing its files. + public static final String URL_RESOURCE_TYPE_URL = "externalurl"; // URL - will be okay + // message content public static final String CONTENT_MB_TERMINATION_TYPE = "terminationType"; // type string public static final String CONTENT_MB_DURATION_DAYS = "durationInDays"; // type string @@ -175,14 +180,26 @@ * So setting it in the tool data now will wreck preview as the workflow engine doesn't * set define later on the tools for preview. * + * Does not set the "reflective" fields. + * * @param toolContentId new tool content id * @param newUserId user id of the person importing the data * @param importValues map of values to import. - * @throws ToolException if any other error occurs + * @throws ToolException an error occurs */ - public void import102ToolContent(Long toolContentId, Integer newUserId, Map importValues) + public void import102ToolContent(Long toolContentId, Integer newUserId, Hashtable importValues) throws ToolException; + /** + * Set the "reflective" fields on an existing piece of content. Note: Most / All of LAMS 2.0 tools + * do not support the title entry for reflection, so any text in that field will be + * lost during the import. Only the description is kept. + * + * @param title heading to use above reflective entry box + * @param description default contents for the reflective entry box. + */ + public void setReflectiveData(Long toolContentId, String title, String description) + throws ToolException, DataMissingException; }