Index: lams_tool_laqa/db/sql/create_lams_tool_qa.sql
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_laqa/db/sql/create_lams_tool_qa.sql,v
diff -u -r1.25 -r1.26
--- lams_tool_laqa/db/sql/create_lams_tool_qa.sql 8 Mar 2006 15:31:08 -0000 1.25
+++ lams_tool_laqa/db/sql/create_lams_tool_qa.sql 19 Mar 2006 13:39:48 -0000 1.26
@@ -2,12 +2,12 @@
uid BIGINT(20) NOT NULL AUTO_INCREMENT
, qa_content_id BIGINT(20) NOT NULL
, title VARCHAR(250) NOT NULL DEFAULT 'Questions and Answers'
- , instructions VARCHAR(250) NOT NULL DEFAULT 'Please, take a minute to answer the following questions.'
+ , instructions VARCHAR(250) NOT NULL DEFAULT 'Please answer the following questions.'
, creation_date VARCHAR(100)
, update_date DATETIME
, questions_sequenced TINYINT(1) NOT NULL
, username_visible TINYINT(1) NOT NULL DEFAULT 0
- , monitoring_report_title VARCHAR(100) DEFAULT 'Combined Learner Results'
+ , monitoring_report_title VARCHAR(100) DEFAULT 'Learner Results'
, report_title VARCHAR(100) DEFAULT 'Report'
, created_by BIGINT(20) NOT NULL DEFAULT 0
, run_offline TINYINT(1) DEFAULT 0
Index: lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/MonitoringUtil.java
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/Attic/MonitoringUtil.java,v
diff -u -r1.24 -r1.25
--- lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/MonitoringUtil.java 19 Mar 2006 10:55:56 -0000 1.24
+++ lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/MonitoringUtil.java 19 Mar 2006 13:39:48 -0000 1.25
@@ -140,14 +140,6 @@
List sessionsList=qaService.getSessionNamesFromContent(qaContent);
logger.debug("sessionsList size is:..." + sessionsList.size());
- if (sessionsList.isEmpty())
- {
- /* inform in the Summary tab that the tool has no active sessions */
- request.getSession().setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(true).toString());
- logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to true");
- }
-
-
Map sessionsMap=QaUtils.convertToStringMap(sessionsList, "String");
logger.debug("generated sessionsMap:..." + sessionsMap);
logger.debug("sessionsMap size:..." + sessionsMap.size());
Index: lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaLearningStarterAction.java
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaLearningStarterAction.java,v
diff -u -r1.29 -r1.30
--- lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaLearningStarterAction.java 19 Mar 2006 10:55:56 -0000 1.29
+++ lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaLearningStarterAction.java 19 Mar 2006 13:39:48 -0000 1.30
@@ -508,6 +508,7 @@
* obtain and setup the current user's data
*/
+
String userID = "";
HttpSession ss = SessionManager.getSession();
logger.debug("ss: " + ss);
Index: lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringAction.java
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringAction.java,v
diff -u -r1.28 -r1.29
--- lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringAction.java 19 Mar 2006 10:55:56 -0000 1.28
+++ lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringAction.java 19 Mar 2006 13:39:48 -0000 1.29
@@ -161,15 +161,18 @@
QaContent qaContent=qaService.loadQa(toolContentId.longValue());
logger.debug("existing qaContent:" + qaContent);
- Map summaryToolSessions=MonitoringUtil.populateToolSessions(request, qaContent, qaService);
- logger.debug("summaryToolSessions: " + summaryToolSessions);
- if (summaryToolSessions.isEmpty())
+
+ if (qaService.studentActivityOccurredGlobal(qaContent))
{
- /* inform in the Summary tab that the tool has no active sessions */
+ request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(false).toString());
+ logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to false");
+ }
+ else
+ {
request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(true).toString());
logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to true");
}
-
+
refreshStatsData(request);
request.getSession().setAttribute(EDIT_RESPONSE, new Boolean(false));
@@ -217,15 +220,17 @@
QaContent qaContent=qaService.loadQa(toolContentId.longValue());
logger.debug("existing qaContent:" + qaContent);
- Map summaryToolSessions=MonitoringUtil.populateToolSessions(request, qaContent, qaService);
- logger.debug("summaryToolSessions: " + summaryToolSessions);
- if (summaryToolSessions.isEmpty())
+ if (qaService.studentActivityOccurredGlobal(qaContent))
{
- /* inform in the Summary tab that the tool has no active sessions */
+ request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(false).toString());
+ logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to false");
+ }
+ else
+ {
request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(true).toString());
logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to true");
}
-
+
refreshInstructionsData(request, qaContent);
request.getSession().setAttribute(EDIT_RESPONSE, new Boolean(false));
@@ -339,19 +344,23 @@
/* this section is related to summary tab. Starts here. */
Map summaryToolSessions=MonitoringUtil.populateToolSessions(request, qaContent, qaService);
logger.debug("summaryToolSessions: " + summaryToolSessions);
- if (summaryToolSessions.isEmpty())
- {
- /* inform in the Summary tab that the tool has no active sessions */
- request.getSession().setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(true).toString());
- logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to true");
- }
-
request.getSession().setAttribute(SUMMARY_TOOL_SESSIONS, summaryToolSessions);
logger.debug("SUMMARY_TOOL_SESSIONS: " + request.getSession().getAttribute(SUMMARY_TOOL_SESSIONS));
/* ends here. */
-
- request.getSession().setAttribute(CURRENT_MONITORING_TAB, "summary");
-
+
+
+ if (qaService.studentActivityOccurredGlobal(qaContent))
+ {
+ request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(false).toString());
+ logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to false");
+ }
+ else
+ {
+ request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(true).toString());
+ logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to true");
+ }
+
+ request.getSession().setAttribute(CURRENT_MONITORING_TAB, "summary");
return (mapping.findForward(LOAD_MONITORING));
}
@@ -705,14 +714,20 @@
/* this section is related to summary tab. Starts here. */
Map summaryToolSessions=MonitoringUtil.populateToolSessions(request, qaContent, qaService);
logger.debug("summaryToolSessions: " + summaryToolSessions);
- if (summaryToolSessions.isEmpty())
+ request.getSession().setAttribute(SUMMARY_TOOL_SESSIONS, summaryToolSessions);
+
+
+ if (qaService.studentActivityOccurredGlobal(qaContent))
{
- QaUtils.cleanUpSessionAbsolute(request);
- /* inform in the Summary tab that the tool has no active sessions */
+ request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(false).toString());
+ logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to false");
+ }
+ else
+ {
request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(true).toString());
logger.debug("USER_EXCEPTION_NO_TOOL_SESSIONS is set to true");
}
- request.getSession().setAttribute(SUMMARY_TOOL_SESSIONS, summaryToolSessions);
+
Map summaryToolSessionsId=MonitoringUtil.populateToolSessionsId(request, qaContent, qaService);
logger.debug("summaryToolSessionsId: " + summaryToolSessionsId);
Index: lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringStarterAction.java
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringStarterAction.java,v
diff -u -r1.29 -r1.30
--- lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringStarterAction.java 11 Mar 2006 22:20:23 -0000 1.29
+++ lams_tool_laqa/src/java/org/lamsfoundation/lams/tool/qa/web/QaMonitoringStarterAction.java 19 Mar 2006 13:39:48 -0000 1.30
@@ -114,6 +114,9 @@
request.getSession().setAttribute(CURRENT_MONITORING_TAB, "summary");
request.getSession().setAttribute(EDIT_RESPONSE, new Boolean(false));
+ /*by default display summary data*/
+ request.setAttribute(USER_EXCEPTION_NO_TOOL_SESSIONS, new Boolean(false).toString());
+
/*
* persist time zone information to session scope.
*/
Index: lams_tool_laqa/web/WEB-INF/struts-config.xml
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_laqa/web/WEB-INF/struts-config.xml,v
diff -u -r1.22 -r1.23
--- lams_tool_laqa/web/WEB-INF/struts-config.xml 19 Mar 2006 10:55:57 -0000 1.22
+++ lams_tool_laqa/web/WEB-INF/struts-config.xml 19 Mar 2006 13:39:48 -0000 1.23
@@ -168,7 +168,7 @@
name="QaLearningForm"
scope="session"
unknown="false"
- validate="false"
+ validate="true"
input="/learningIndex.jsp">
@@ -233,7 +233,7 @@
input="/learning/AnswersContent.jsp"
parameter="method"
unknown="false"
- validate="false">
+ validate="true">