Index: lams_tool_forum/conf/language/lams/ApplicationResources.properties =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/conf/language/lams/ApplicationResources.properties,v diff -u -r1.13 -r1.14 --- lams_tool_forum/conf/language/lams/ApplicationResources.properties 2 May 2008 05:57:41 -0000 1.13 +++ lams_tool_forum/conf/language/lams/ApplicationResources.properties 7 May 2008 06:33:58 -0000 1.14 @@ -173,6 +173,6 @@ label.back.to.forum =Back to Topic List label.responses.locked.reminder =The instructor has set this activity not to allow postings after you have finished it. As you are returning to this Forum again, you are able to see all threads but not allow to post anymore. label.authoring.advance.number.reply =Number of posts per learner +monitoring.marked.question=Marked? - #======= End labels: Exported 167 labels for en AU ===== Index: lams_tool_forum/conf/language/lams/ApplicationResources_en_AU.properties =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/conf/language/lams/ApplicationResources_en_AU.properties,v diff -u -r1.12 -r1.13 --- lams_tool_forum/conf/language/lams/ApplicationResources_en_AU.properties 2 May 2008 05:57:41 -0000 1.12 +++ lams_tool_forum/conf/language/lams/ApplicationResources_en_AU.properties 7 May 2008 06:33:58 -0000 1.13 @@ -173,6 +173,6 @@ label.back.to.forum =Back to Topic List label.responses.locked.reminder =The instructor has set this activity not to allow postings after you have finished it. As you are returning to this Forum again, you are able to see all threads but not allow to post anymore. label.authoring.advance.number.reply =Number of posts per learner +monitoring.marked.question=Marked? - #======= End labels: Exported 167 labels for en AU ===== Index: lams_tool_forum/conf/xdoclet/struts-actions.xml =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/conf/xdoclet/struts-actions.xml,v diff -u -r1.44 -r1.45 --- lams_tool_forum/conf/xdoclet/struts-actions.xml 20 Nov 2006 05:29:11 -0000 1.44 +++ lams_tool_forum/conf/xdoclet/struts-actions.xml 7 May 2008 06:34:07 -0000 1.45 @@ -239,6 +239,8 @@ Index: lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/dto/UserDTO.java =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/dto/UserDTO.java,v diff -u -r1.1 -r1.2 --- lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/dto/UserDTO.java 30 Aug 2006 06:37:40 -0000 1.1 +++ lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/dto/UserDTO.java 7 May 2008 06:33:45 -0000 1.2 @@ -12,6 +12,7 @@ private String reflectInstrctions; private boolean finishReflection; private String reflect; + private boolean anyPostsMarked; public UserDTO(){ } @@ -74,4 +75,12 @@ public void setFinishReflection(boolean finishReflection) { this.finishReflection = finishReflection; } + + public boolean isAnyPostsMarked() { + return anyPostsMarked; + } + + public void setAnyPostsMarked(boolean anyPostsMarked) { + this.anyPostsMarked = anyPostsMarked; + } } Index: lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/util/ForumConstants.java =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/util/ForumConstants.java,v diff -u -r1.47 -r1.48 --- lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/util/ForumConstants.java 1 May 2008 05:45:43 -0000 1.47 +++ lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/util/ForumConstants.java 7 May 2008 06:33:46 -0000 1.48 @@ -119,6 +119,7 @@ public static final String MARK_UPDATE_FROM_USER = "listMarks"; public static final String MARK_UPDATE_FROM_FORUM = "viewForum"; + public static final String ATTR_HIDE_REFLECTION = "hideReflection"; Index: lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/LearningAction.java =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/LearningAction.java,v diff -u -r1.60 -r1.61 --- lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/LearningAction.java 1 May 2008 05:46:42 -0000 1.60 +++ lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/LearningAction.java 7 May 2008 06:33:44 -0000 1.61 @@ -197,15 +197,6 @@ Boolean allowRichEditor = new Boolean(forum.isAllowRichEditor()); int allowNumber = forum.isLimitedInput() || forum.isAllowRichEditor() ? forum.getLimitedChar() : 0; - // get notebook entry - String entryText = new String(); - NotebookEntry notebookEntry = forumService.getEntry(sessionId, CoreNotebookConstants.NOTEBOOK_TOOL, - ForumConstants.TOOL_SIGNATURE, forumUser.getUserId().intValue()); - - if (notebookEntry != null) { - entryText = notebookEntry.getEntry(); - } - sessionMap.put(ForumConstants.FORUM_ID, forumId); sessionMap.put(AttributeNames.ATTR_MODE, mode); sessionMap.put(ForumConstants.ATTR_FINISHED_LOCK, new Boolean(lock)); @@ -216,13 +207,30 @@ sessionMap.put(ForumConstants.ATTR_ALLOW_NEW_TOPICS,forum.isAllowNewTopic()); sessionMap.put(ForumConstants.ATTR_ALLOW_RICH_EDITOR,allowRichEditor); sessionMap.put(ForumConstants.ATTR_LIMITED_CHARS,new Integer(allowNumber)); - sessionMap.put(ForumConstants.ATTR_REFLECTION_ON,forum.isReflectOnActivity()); - sessionMap.put(ForumConstants.ATTR_REFLECTION_INSTRUCTION,forum.getReflectInstructions()); - sessionMap.put(ForumConstants.ATTR_REFLECTION_ENTRY, entryText); sessionMap.put(AttributeNames.PARAM_TOOL_SESSION_ID, sessionId); sessionMap.put(ForumConstants.ATTR_FORUM_TITLE,forum.getTitle()); sessionMap.put(ForumConstants.ATTR_FORUM_INSTRCUTION,forum.getInstructions()); - + + // Should we show the reflection or not? We shouldn't show it when the screen is accessed + // from the Monitoring Summary screen, but we should when accessed from the Learner Progress screen. + // Need to constantly past this value on, rather than hiding just the once, as the View Forum + // screen has a refresh button. + boolean hideReflection = WebUtil.readBooleanParam(request, ForumConstants.ATTR_HIDE_REFLECTION, false); + sessionMap.put(ForumConstants.ATTR_HIDE_REFLECTION, hideReflection); + + if ( hideReflection ) { + sessionMap.put(ForumConstants.ATTR_REFLECTION_ON,false); + sessionMap.put(ForumConstants.ATTR_REFLECTION_INSTRUCTION,""); + sessionMap.put(ForumConstants.ATTR_REFLECTION_ENTRY, ""); + } else { + sessionMap.put(ForumConstants.ATTR_REFLECTION_ON,forum.isReflectOnActivity()); + sessionMap.put(ForumConstants.ATTR_REFLECTION_INSTRUCTION,forum.getReflectInstructions()); + + NotebookEntry notebookEntry = forumService.getEntry(sessionId, CoreNotebookConstants.NOTEBOOK_TOOL, + ForumConstants.TOOL_SIGNATURE, forumUser.getUserId().intValue()); + sessionMap.put(ForumConstants.ATTR_REFLECTION_ENTRY, notebookEntry != null ? notebookEntry.getEntry() : ""); + } + //add define later support if(forum.isDefineLater()){ return mapping.findForward("defineLater"); @@ -406,6 +414,14 @@ //transfer SessionMapID as well request.setAttribute(ForumConstants.ATTR_SESSION_MAP_ID, sessionMapID); + // Should we show the reflection or not? We shouldn't show it when the View Forum screen is accessed + // from the Monitoring Summary screen, but we should when accessed from the Learner Progress screen. + // Need to constantly past this value on, rather than hiding just the once, as the View Forum + // screen has a refresh button. Need to pass it through the view topic screen and dependent screens + // as it has a link from the view topic screen back to View Forum screen. + boolean hideReflection = WebUtil.readBooleanParam(request, ForumConstants.ATTR_HIDE_REFLECTION, false); + sessionMap.put(ForumConstants.ATTR_HIDE_REFLECTION, hideReflection); + return mapping.findForward("success"); } @@ -509,7 +525,14 @@ SessionMap sessionMap = getSessionMap(request, msgForm); sessionMap.put(ForumConstants.ATTR_PARENT_TOPIC_ID, parentId); - + // Should we show the reflection or not? We shouldn't show it when the View Forum screen is accessed + // from the Monitoring Summary screen, but we should when accessed from the Learner Progress screen. + // Need to constantly past this value on, rather than hiding just the once, as the View Forum + // screen has a refresh button. Need to pass it through the view topic screen and dependent screens + // as it has a link from the view topic screen back to View Forum screen. + boolean hideReflection = WebUtil.readBooleanParam(request, ForumConstants.ATTR_HIDE_REFLECTION, false); + sessionMap.put(ForumConstants.ATTR_HIDE_REFLECTION, hideReflection); + return mapping.findForward("success"); } @@ -598,6 +621,14 @@ SessionMap sessionMap = getSessionMap(request, msgForm); sessionMap.put(ForumConstants.ATTR_TOPIC_ID, topicId); + // Should we show the reflection or not? We shouldn't show it when the View Forum screen is accessed + // from the Monitoring Summary screen, but we should when accessed from the Learner Progress screen. + // Need to constantly past this value on, rather than hiding just the once, as the View Forum + // screen has a refresh button. Need to pass it through the view topic screen and dependent screens + // as it has a link from the view topic screen back to View Forum screen. + boolean hideReflection = WebUtil.readBooleanParam(request, ForumConstants.ATTR_HIDE_REFLECTION, false); + sessionMap.put(ForumConstants.ATTR_HIDE_REFLECTION, hideReflection); + return mapping.findForward("success"); } /** Index: lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/MonitoringAction.java =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/MonitoringAction.java,v diff -u -r1.33 -r1.34 --- lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/MonitoringAction.java 2 May 2008 04:55:07 -0000 1.33 +++ lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/MonitoringAction.java 7 May 2008 06:33:45 -0000 1.34 @@ -182,11 +182,19 @@ } private ActionForward doTabs(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) { + //set back tool content ID + String contentFolderID = WebUtil.readStrParam(request,AttributeNames.PARAM_CONTENT_FOLDER_ID); + request.setAttribute(AttributeNames.PARAM_CONTENT_FOLDER_ID, contentFolderID); + + Long toolContentID = new Long(WebUtil.readLongParam(request,AttributeNames.PARAM_TOOL_CONTENT_ID)); + request.setAttribute(AttributeNames.PARAM_TOOL_CONTENT_ID, toolContentID); + + request.setAttribute("initialTabId", WebUtil.readLongParam(request, AttributeNames.PARAM_CURRENT_TAB,true)); + this.summary(mapping, form, request, response); this.viewInstructions(mapping, form, request, response); - this.viewActivity(mapping, form, request, response); + this.viewActivity(mapping, form, request, response, toolContentID); this.statistic(mapping, form, request, response); - request.setAttribute("initialTabId", WebUtil.readLongParam(request, AttributeNames.PARAM_CURRENT_TAB,true)); return mapping.findForward("load"); } @@ -221,18 +229,36 @@ List userList = forumService.getUsersBySessionId(fts.getSessionId()); //sort and create DTO list + List topicList = forumService.getAllTopicsFromSession(fts.getSessionId()); + Map topicsByUser = getTopicsSortedByAuthor(topicList); + Set dtoList = new TreeSet(this.new UserDTOComparator()); Iterator iter = userList.iterator(); while(iter.hasNext()){ ForumUser user = (ForumUser) iter.next(); UserDTO userDTO = new UserDTO(user); userDTO.setHasRefection(hasReflection); + + userDTO.setAnyPostsMarked(false); + userDTO.setNoOfPosts(0); + + List messages = (List) topicsByUser.get(user); + if ( messages != null && messages.size() > 0 ) { + userDTO.setNoOfPosts(messages.size()); + for ( MessageDTO message : messages ) { + if ( message.getMark() != null ) { + userDTO.setAnyPostsMarked(true); + break; + } + } + } dtoList.add(userDTO); - //userDTO.setNoOfPosts(noOfPosts) } + sessionUsersMap.put(sessionDto, dtoList); } + // request.setAttribute(AttributeNames.PARAM_TOOL_SESSION_ID,sessionID); request.setAttribute("sessionUserMap", sessionUsersMap); return mapping.findForward("success"); @@ -384,11 +410,7 @@ * @return */ private ActionForward viewActivity(ActionMapping mapping, ActionForm form, - HttpServletRequest request, HttpServletResponse response) { - Long toolContentID = new Long(WebUtil.readLongParam(request,AttributeNames.PARAM_TOOL_CONTENT_ID)); - //set back tool content ID - String contentFolderID = WebUtil.readStrParam(request,AttributeNames.PARAM_CONTENT_FOLDER_ID); - request.setAttribute(AttributeNames.PARAM_CONTENT_FOLDER_ID, contentFolderID); + HttpServletRequest request, HttpServletResponse response, Long toolContentID) { forumService = getForumService(); Forum forum = forumService.getForumByContentId(toolContentID); @@ -405,7 +427,6 @@ boolean isForumEditable = ForumWebUtils.isForumEditable(forum); request.setAttribute(ForumConstants.PAGE_EDITABLE, new Boolean(isForumEditable)); - request.setAttribute(AttributeNames.PARAM_TOOL_CONTENT_ID, toolContentID); request.setAttribute("title", title); request.setAttribute("instruction", instruction); return mapping.findForward("success"); @@ -709,6 +730,14 @@ request.setAttribute(ForumConstants.ATTR_TOPIC, MessageDTO.getMessageDTO(msg)); request.setAttribute(ForumConstants.ATTR_USER, user); + // Should we show the reflection or not? We shouldn't show it when the View Forum screen is accessed + // from the Monitoring Summary screen, but we should when accessed from the Learner Progress screen. + // Need to constantly past this value on, rather than hiding just the once, as the View Forum + // screen has a refresh button. Need to pass it through the view topic screen and dependent screens + // as it has a link from the view topic screen back to View Forum screen. + boolean hideReflection = WebUtil.readBooleanParam(request, ForumConstants.ATTR_HIDE_REFLECTION, false); + sessionMap.put(ForumConstants.ATTR_HIDE_REFLECTION, hideReflection); + return mapping.findForward("success"); } Index: lams_tool_forum/web/WEB-INF/struts-config.xml =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/WEB-INF/Attic/struts-config.xml,v diff -u -r1.49 -r1.50 --- lams_tool_forum/web/WEB-INF/struts-config.xml 9 May 2007 00:57:17 -0000 1.49 +++ lams_tool_forum/web/WEB-INF/struts-config.xml 7 May 2008 06:34:30 -0000 1.50 @@ -271,6 +271,8 @@ Index: lams_tool_forum/web/common/header.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/common/header.jsp,v diff -u -r1.10 -r1.11 --- lams_tool_forum/web/common/header.jsp 8 Jun 2007 01:35:34 -0000 1.10 +++ lams_tool_forum/web/common/header.jsp 7 May 2008 06:34:29 -0000 1.11 @@ -24,3 +24,11 @@ <%@ include file="/common/fckeditorheader.jsp"%> + + + Index: lams_tool_forum/web/jsps/learning/viewforum.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/learning/viewforum.jsp,v diff -u -r1.25 -r1.26 --- lams_tool_forum/web/jsps/learning/viewforum.jsp 6 May 2008 02:35:19 -0000 1.25 +++ lams_tool_forum/web/jsps/learning/viewforum.jsp 7 May 2008 06:34:30 -0000 1.26 @@ -38,7 +38,7 @@ + page="/learning/viewForum.do?mode=${sessionMap.mode}&toolSessionID=${sessionMap.toolSessionID}&sessionMapID=${sessionMapID}&hideReflection=${sessionMap.hideReflection}" /> @@ -72,7 +72,7 @@ - +

${sessionMap.reflectInstructions} @@ -91,11 +91,13 @@ - - - + + + + +

Index: lams_tool_forum/web/jsps/learning/viewtopic.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/learning/viewtopic.jsp,v diff -u -r1.15 -r1.16 --- lams_tool_forum/web/jsps/learning/viewtopic.jsp 6 Nov 2006 04:13:22 -0000 1.15 +++ lams_tool_forum/web/jsps/learning/viewtopic.jsp 7 May 2008 06:34:30 -0000 1.16 @@ -4,7 +4,7 @@ @@ -18,7 +18,7 @@
+ page="/learning/viewForum.do?mode=${sessionMap.mode}&sessionMapID=${sessionMapID}&toolSessionID=${sessionMap.toolSessionID}&hideReflection=${sessionMap.hideReflection}" /> + page="/learning/viewForum.do?mode=${sessionMap.mode}&sessionMapID=${sessionMapID}&toolSessionID=${sessionMap.toolSessionID}&hideReflection=${sessionMap.hideReflection}" /> - + Index: lams_tool_forum/web/jsps/learning/message/topicform.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/learning/message/topicform.jsp,v diff -u -r1.13 -r1.14 --- lams_tool_forum/web/jsps/learning/message/topicform.jsp 14 Dec 2006 04:31:09 -0000 1.13 +++ lams_tool_forum/web/jsps/learning/message/topicform.jsp 7 May 2008 06:34:30 -0000 1.14 @@ -32,7 +32,7 @@ - + Index: lams_tool_forum/web/jsps/learning/message/topiclist.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/learning/message/topiclist.jsp,v diff -u -r1.12 -r1.13 --- lams_tool_forum/web/jsps/learning/message/topiclist.jsp 5 May 2008 06:51:21 -0000 1.12 +++ lams_tool_forum/web/jsps/learning/message/topiclist.jsp 7 May 2008 06:34:30 -0000 1.13 @@ -20,7 +20,7 @@ - + Index: lams_tool_forum/web/jsps/learning/message/topicreplyform.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/learning/message/topicreplyform.jsp,v diff -u -r1.13 -r1.14 --- lams_tool_forum/web/jsps/learning/message/topicreplyform.jsp 25 Oct 2006 05:36:27 -0000 1.13 +++ lams_tool_forum/web/jsps/learning/message/topicreplyform.jsp 7 May 2008 06:34:29 -0000 1.14 @@ -31,7 +31,7 @@ + page="/learning/viewTopic.do?sessionMapID=${sessionMapID}&topicID=${sessionMap.rootUid}&create=${message.created.time}&hideReflection=${sessionMap.hideReflection}" /> + page="/monitoring/editMark.do?sessionMapID=${sessionMapID}&topicID=${msgDto.message.uid}&updateMode=viewForum&hideReflection=${sessionMap.hideReflection}" /> @@ -138,7 +138,7 @@ test='${(sessionMap.mode == "teacher") || (msgDto.isAuthor && not sessionMap.finishedLock && sessionMap.allowEdit && (empty msgDto.mark))}'> + page="/learning/editTopic.do?sessionMapID=${sessionMapID}&topicID=${msgDto.message.uid}&rootUid=${sessinoMap.rootUid}&create=${msgDto.message.created.time}&hideReflection=${sessionMap.hideReflection}" /> @@ -150,7 +150,7 @@ test="${(not sessionMap.finishedLock) && (not sessionMap.noMorePosts)}"> + page="/learning/newReplyTopic.do?sessionMapID=${sessionMapID}&parentID=${msgDto.message.uid}&rootUid=${sessionMap.rootUid}&hideReflection=${sessionMap.hideReflection}" /> Index: lams_tool_forum/web/jsps/monitoring/summary.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/summary.jsp,v diff -u -r1.8 -r1.9 --- lams_tool_forum/web/jsps/monitoring/summary.jsp 2 Nov 2006 06:15:51 -0000 1.8 +++ lams_tool_forum/web/jsps/monitoring/summary.jsp 7 May 2008 06:34:29 -0000 1.9 @@ -78,6 +78,9 @@ + + +   @@ -99,6 +102,16 @@ + + + tick + + + cross + + + + @@ -125,6 +138,7 @@ + @@ -153,6 +167,15 @@
+
+ + + + + + + +
Index: lams_tool_forum/web/jsps/monitoring/updatemarks.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/updatemarks.jsp,v diff -u -r1.19 -r1.20 --- lams_tool_forum/web/jsps/monitoring/updatemarks.jsp 2 Nov 2006 06:15:51 -0000 1.19 +++ lams_tool_forum/web/jsps/monitoring/updatemarks.jsp 7 May 2008 06:34:29 -0000 1.20 @@ -7,6 +7,7 @@ + @@ -22,7 +23,7 @@
- + @@ -88,7 +89,7 @@ - ?sessionMapID=${formBean.sessionMapID}&topicID=${sessionMap.rootUid} + ?sessionMapID=${formBean.sessionMapID}&topicID=${sessionMap.rootUid}&hideReflection=${sessionMap.hideReflection} "> Index: lams_tool_forum/web/jsps/monitoring/viewmarks.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/viewmarks.jsp,v diff -u -r1.5 -r1.6 --- lams_tool_forum/web/jsps/monitoring/viewmarks.jsp 2 Nov 2006 06:15:51 -0000 1.5 +++ lams_tool_forum/web/jsps/monitoring/viewmarks.jsp 7 May 2008 06:34:29 -0000 1.6 @@ -38,7 +38,7 @@
- + @@ -110,7 +110,7 @@
- +