Index: lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/McAppConstants.java
===================================================================
diff -u -r96f6dc3128419969060b654301ffa0ad632f2863 -r8bb8d77a378de6ee1231195294e2b078248598c9
--- lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/McAppConstants.java (.../McAppConstants.java) (revision 96f6dc3128419969060b654301ffa0ad632f2863)
+++ lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/McAppConstants.java (.../McAppConstants.java) (revision 8bb8d77a378de6ee1231195294e2b078248598c9)
@@ -96,7 +96,9 @@
public static final String LOAD_QUESTIONS ="load";
public static final String LOAD_STARTER ="starter";
public static final String LOAD_LEARNER ="loadLearner";
+ public static final String INDIVIDUAL_REPORT ="individualReport";
+
public static final String ALL_INSTRUCTIONS ="allInstructions";
public static final String EDIT_OPTS_CONTENT ="editOptsContent";
public static final String ADD_OPTS_CONTENT ="addOptsContent";
Index: lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/web/McAction.java
===================================================================
diff -u -r434092d51899472f987f50d982a6c151874f93d5 -r8bb8d77a378de6ee1231195294e2b078248598c9
--- lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/web/McAction.java (.../McAction.java) (revision 434092d51899472f987f50d982a6c151874f93d5)
+++ lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/web/McAction.java (.../McAction.java) (revision 8bb8d77a378de6ee1231195294e2b078248598c9)
@@ -2114,17 +2114,12 @@
McContent mcContent=mcService.retrieveMc(toolContentID);
logger.debug("mcContent: " + mcContent);
- String totalQuestionCount= (String) request.getSession().getAttribute(TOTAL_QUESTION_COUNT);
- int totalQCount= new Integer(totalQuestionCount).intValue();
- logger.debug("totalQCount: " +totalQCount);
-
-
/*
* fetch question content from content
*/
logger.debug("newQuestionIndex: " + newQuestionIndex);
Iterator contentIterator=mcContent.getMcQueContents().iterator();
- boolean lastQuestion=false;
+ boolean questionFound=false;
while (contentIterator.hasNext())
{
McQueContent mcQueContent=(McQueContent)contentIterator.next();
@@ -2145,33 +2140,25 @@
Map mapOptionsContent=McUtils.generateOptionsMap(listMcOptions);
request.getSession().setAttribute(MAP_OPTIONS_CONTENT, mapOptionsContent);
logger.debug("updated Options Map: " + request.getSession().getAttribute(MAP_OPTIONS_CONTENT));
+ questionFound=true;
}
-
- if (totalQCount == newQuestionIndex)
- {
- logger.debug("this is the last question... ");
- lastQuestion=true;
- }
-
}
}
+
+ if (questionFound == false)
+ {
+ logger.debug("no more questions... ");
+ return (mapping.findForward(INDIVIDUAL_REPORT));
+ }
+ else
+ {
+ logger.debug("go back to have more answers...");
+ return (mapping.findForward(LOAD_LEARNER));
+ }
}
-
- return (mapping.findForward(LOAD_LEARNER));
- }
+ return (mapping.findForward(LOAD_LEARNER));
+ }
+
+
+}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-}
\ No newline at end of file
Index: lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/web/McLearningStarterAction.java
===================================================================
diff -u -r434092d51899472f987f50d982a6c151874f93d5 -r8bb8d77a378de6ee1231195294e2b078248598c9
--- lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/web/McLearningStarterAction.java (.../McLearningStarterAction.java) (revision 434092d51899472f987f50d982a6c151874f93d5)
+++ lams_tool_lamc/src/java/org/lamsfoundation/lams/tool/mc/web/McLearningStarterAction.java (.../McLearningStarterAction.java) (revision 8bb8d77a378de6ee1231195294e2b078248598c9)
@@ -247,6 +247,15 @@
logger.debug("final Options Map for the first question: " + request.getSession().getAttribute(MAP_OPTIONS_CONTENT));
+ /*also prepare for combined answers view */
+ Map mapGeneralOptionsContent= new TreeMap(new McComparator());
+ logger.debug("current mapGeneralOptionsContent: " + mapGeneralOptionsContent);
+ request.getSession().setAttribute(MAP_GENERAL_OPTIONS_CONTENT, mapGeneralOptionsContent);
+
+
+
+
+
return (mapping.findForward(LOAD_LEARNER));
}
Index: lams_tool_lamc/web/CombinedAnswersContent.jsp
===================================================================
diff -u -r434092d51899472f987f50d982a6c151874f93d5 -r8bb8d77a378de6ee1231195294e2b078248598c9
--- lams_tool_lamc/web/CombinedAnswersContent.jsp (.../CombinedAnswersContent.jsp) (revision 434092d51899472f987f50d982a6c151874f93d5)
+++ lams_tool_lamc/web/CombinedAnswersContent.jsp (.../CombinedAnswersContent.jsp) (revision 8bb8d77a378de6ee1231195294e2b078248598c9)
@@ -4,30 +4,77 @@
<%@ taglib uri="/WEB-INF/c.tld" prefix="c" %>
<%@ taglib uri="/WEB-INF/fmt.tld" prefix="fmt" %>
-
-
+
+
Index: lams_tool_lamc/web/IndividualReport.jsp
===================================================================
diff -u
--- lams_tool_lamc/web/IndividualReport.jsp (revision 0)
+++ lams_tool_lamc/web/IndividualReport.jsp (revision 8bb8d77a378de6ee1231195294e2b078248598c9)
@@ -0,0 +1,33 @@
+<%@ taglib uri="/WEB-INF/struts-html-el.tld" prefix="html" %>
+<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
+<%@ taglib uri="/WEB-INF/struts-logic-el.tld" prefix="logic-el" %>
+<%@ taglib uri="/WEB-INF/c.tld" prefix="c" %>
+<%@ taglib uri="/WEB-INF/fmt.tld" prefix="fmt" %>
+<%@ taglib uri="fck-editor" prefix="FCK" %>
+
+<%
+String protocol = request.getProtocol();
+if(protocol.startsWith("HTTPS")){
+ protocol = "https://";
+}else{
+ protocol = "http://";
+}
+String root = protocol+request.getServerName()+":"+request.getServerPort()+request.getContextPath()+"/";
+String pathToLams = protocol+request.getServerName()+":"+request.getServerPort()+request.getContextPath()+"/../..";
+%>
+
+
+
+
+
+Tool
+
+
+
+INDIVIDUAL REPORT
+
+
+
+
+
+
Index: lams_tool_lamc/web/SequentialAnswersContent.jsp
===================================================================
diff -u -r434092d51899472f987f50d982a6c151874f93d5 -r8bb8d77a378de6ee1231195294e2b078248598c9
--- lams_tool_lamc/web/SequentialAnswersContent.jsp (.../SequentialAnswersContent.jsp) (revision 434092d51899472f987f50d982a6c151874f93d5)
+++ lams_tool_lamc/web/SequentialAnswersContent.jsp (.../SequentialAnswersContent.jsp) (revision 8bb8d77a378de6ee1231195294e2b078248598c9)
@@ -41,7 +41,7 @@
-
+ |
Index: lams_tool_lamc/web/WEB-INF/struts-config.xml
===================================================================
diff -u -r434092d51899472f987f50d982a6c151874f93d5 -r8bb8d77a378de6ee1231195294e2b078248598c9
--- lams_tool_lamc/web/WEB-INF/struts-config.xml (.../struts-config.xml) (revision 434092d51899472f987f50d982a6c151874f93d5)
+++ lams_tool_lamc/web/WEB-INF/struts-config.xml (.../struts-config.xml) (revision 8bb8d77a378de6ee1231195294e2b078248598c9)
@@ -134,8 +134,14 @@
path=".answers"
redirect="true"
/>
-
+
+
+
+
+
+
+
+
\ No newline at end of file
| |