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.25 -r1.26
--- lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/LearningAction.java 8 Mar 2006 23:38:52 -0000 1.25
+++ lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/LearningAction.java 16 Mar 2006 03:21:06 -0000 1.26
@@ -472,13 +472,15 @@
Forum forum = toolSession.getForum();
ForumUser currentUser = getCurrentUser(request);
ForumUser forumCreatedBy = forum.getCreatedBy();
-
- if (currentUser.getUserId().equals(forumCreatedBy.getUserId())) {
+
+ // TODO Skipping permissions for now, currently having issues with default learning designs not having an create_by field
+ // we should be looking at whether a user is a teacher and more specifically staff
+// if (currentUser.getUserId().equals(forumCreatedBy.getUserId())) {
forumService.updateMessageHideFlag(msgId, hideFlag.booleanValue());
- } else {
- log.info(currentUser + "does not have permission to hide/show postings in forum: " + forum.getUid());
- log.info("Forum created by :" + forumCreatedBy.getUid() + ", Current User is: " + currentUser.getUid());
- }
+// } else {
+// log.info(currentUser + "does not have permission to hide/show postings in forum: " + forum.getUid());
+// log.info("Forum created by :" + forumCreatedBy.getUid() + ", Current User is: " + currentUser.getUid());
+// }
// echo back this topic thread into page
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.13 -r1.14
--- lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/MonitoringAction.java 8 Mar 2006 23:42:03 -0000 1.13
+++ lams_tool_forum/src/java/org/lamsfoundation/lams/tool/forum/web/actions/MonitoringAction.java 16 Mar 2006 03:21:06 -0000 1.14
@@ -76,8 +76,8 @@
throws Exception {
String param = mapping.getParameter();
- if (param.equals("listContentUsers")) {
- return listContentUsers(mapping, form, request, response);
+ if (param.equals("init")) {
+ return init(mapping, form, request, response);
}
// ***************** Marks Functions ********************
if (param.equals("viewAllMarks")) {
@@ -96,34 +96,49 @@
return updateMark(mapping, form, request, response);
}
- // ***************** Activity and Instructions ********************
- if (param.equals("viewActivity")) {
- return viewActivity(mapping, form, request, response);
- }
- if (param.equals("editActivity")) {
- return editActivity(mapping, form, request, response);
- }
- if (param.equals("updateActivity")) {
- return updateActivity(mapping, form, request, response);
- }
- if (param.equals("viewInstructions")) {
- return viewInstructions(mapping, form, request, response);
- }
- // ***************** Statistic ********************
- if (param.equals("statistic")) {
- return statistic(mapping, form, request, response);
- }
-
// ***************** Miscellaneous ********************
if (param.equals("viewTopic")) {
return viewTopic(mapping, form, request, response);
}
return mapping.findForward("error");
}
-
+
+ /**
+ * Default ActionForward for Monitor
+ * (non-Javadoc)
+ * @see org.apache.struts.actions.DispatchAction#unspecified(org.apache.struts.action.ActionMapping, org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
+ */
+
/**
+ * The initial method for monitoring
+ */
+ private ActionForward init(ActionMapping mapping, ActionForm form,
+ HttpServletRequest request, HttpServletResponse response) {
+ // read in parameters and set session attributes.
+ Long toolContentID = new Long(WebUtil.readLongParam(request,
+ AttributeNames.PARAM_TOOL_CONTENT_ID));
+ request.getSession().setAttribute(AttributeNames.PARAM_TOOL_CONTENT_ID,
+ toolContentID);
+ request.getSession().setAttribute(AttributeNames.PARAM_MODE,
+ ToolAccessMode.TEACHER);
+
+ // perform the actions for all the tabs.
+ doTabs(mapping, form, request, response);
+
+ return mapping.findForward("load");
+ }
+
+ private ActionForward doTabs(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) {
+ this.listContentUsers(mapping, form, request, response);
+ this.viewInstructions(mapping, form, request, response);
+ this.viewActivity(mapping, form, request, response);
+ this.statistic(mapping, form, request, response);
+ return mapping.findForward("load");
+ }
+
+ /**
* The initial method for monitoring. List all users according to given
- * Content ID.
+ * Content ID.
*
* @param mapping
* @param form
@@ -134,14 +149,7 @@
private ActionForward listContentUsers(ActionMapping mapping,
ActionForm form, HttpServletRequest request,
HttpServletResponse response) {
- Long toolContentID = new Long(WebUtil.readLongParam(request,
- AttributeNames.PARAM_TOOL_CONTENT_ID));
- request.getSession().setAttribute(AttributeNames.PARAM_TOOL_CONTENT_ID,
- toolContentID);
-
- request.getSession().setAttribute(AttributeNames.PARAM_MODE, ToolAccessMode.TEACHER);
-
- return userList(mapping, request);
+ return userList(mapping, request);
}
/**
@@ -164,7 +172,7 @@
Map topicsByUser = getTopicsSortedByAuthor(topicList);
request.setAttribute(AttributeNames.PARAM_TOOL_SESSION_ID, sessionID);
request.setAttribute("report", topicsByUser);
-
+
return mapping.findForward("success");
}
@@ -302,7 +310,7 @@
* @param response
* @return
*/
- private ActionForward viewUserMark(ActionMapping mapping, ActionForm form,
+ public ActionForward viewUserMark(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response) {
Long userUid = new Long(WebUtil.readLongParam(request,
ForumConstants.USER_UID));
@@ -429,7 +437,9 @@
}
String title = forum.getTitle();
String instruction = forum.getInstructions();
-
+
+ boolean isForumEditable = ForumWebUtils.isForumEditable(forum);
+ request.setAttribute(ForumConstants.PAGE_EDITABLE, new Boolean(isForumEditable));
request.setAttribute("title", title);
request.setAttribute("instruction", instruction);
return mapping.findForward("success");
@@ -508,8 +518,9 @@
"error.fail.get.forum"));
}
if (StringUtils.isEmpty(title)) {
- errors.add("activity.title", new ActionMessage(
- "error.title.empty"));
+ errors
+ .add("activity.title", new ActionMessage(
+ "error.title.empty"));
}
// echo back to screen
request.setAttribute("title", title);
Index: lams_tool_forum/web/includes/header.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/includes/Attic/header.jsp,v
diff -u -r1.9 -r1.10
--- lams_tool_forum/web/includes/header.jsp 5 Mar 2006 22:58:24 -0000 1.9
+++ lams_tool_forum/web/includes/header.jsp 16 Mar 2006 03:23:10 -0000 1.10
@@ -1,17 +1,55 @@
-<%@ include file="/includes/taglibs.jsp" %>
+<%@ include file="/includes/taglibs.jsp"%>
-
-
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
-
-
+ function doSubmit(method, tabId) {
+// if(tabId != null)
+// document.forumMonitoringForm.currentTab.value=tabId;
+// document.forumMonitoringForm.method.value=method;
+ document.forumMonitoringForm.submit();
+ }
+ //]]>
+
+
+
Index: lams_tool_forum/web/includes/layout.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/includes/layout.jsp,v
diff -u -r1.7 -r1.8
--- lams_tool_forum/web/includes/layout.jsp 5 Mar 2006 22:58:16 -0000 1.7
+++ lams_tool_forum/web/includes/layout.jsp 16 Mar 2006 03:23:10 -0000 1.8
@@ -1,21 +1,21 @@
+
+
<%@ include file="/includes/taglibs.jsp"%>
<%@ taglib uri="tags-tiles" prefix="tiles"%>
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
Index: lams_tool_forum/web/includes/tablayout.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/includes/tablayout.jsp,v
diff -u -r1.2 -r1.3
--- lams_tool_forum/web/includes/tablayout.jsp 8 Mar 2006 23:53:58 -0000 1.2
+++ lams_tool_forum/web/includes/tablayout.jsp 16 Mar 2006 03:23:10 -0000 1.3
@@ -1,23 +1,18 @@
+
+
<%@ include file="/includes/taglibs.jsp"%>
<%@ taglib uri="tags-tiles" prefix="tiles"%>
-
+
-
-
-
+
-
+
+
+
Index: lams_tool_forum/web/includes/taglibs.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/includes/Attic/taglibs.jsp,v
diff -u -r1.9 -r1.10
--- lams_tool_forum/web/includes/taglibs.jsp 5 Mar 2006 22:58:24 -0000 1.9
+++ lams_tool_forum/web/includes/taglibs.jsp 16 Mar 2006 03:23:10 -0000 1.10
@@ -6,5 +6,5 @@
<%@ taglib uri="tags-core" prefix="c"%>
<%@ taglib uri="tags-fmt" prefix="fmt"%>
<%@ taglib uri="tags-lams" prefix="lams" %>
-<%@ taglib uri="tags-fck-editor" prefix="FCK"%>
+<%@ taglib uri="fck-editor" prefix="FCK"%>
Index: lams_tool_forum/web/jsps/monitoring/contentuserlist.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/Attic/contentuserlist.jsp,v
diff -u -r1.8 -r1.9
--- lams_tool_forum/web/jsps/monitoring/contentuserlist.jsp 8 Mar 2006 23:46:57 -0000 1.8
+++ lams_tool_forum/web/jsps/monitoring/contentuserlist.jsp 16 Mar 2006 03:23:54 -0000 1.9
@@ -1,36 +1,26 @@
<%@ include file="/includes/taglibs.jsp"%>
-
-
-
+
-
-
-
-
-
-
-
-
-
-
+
-
Index: lams_tool_forum/web/jsps/monitoring/definelater.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/Attic/definelater.jsp,v
diff -u -r1.1 -r1.2
--- lams_tool_forum/web/jsps/monitoring/definelater.jsp 14 Dec 2005 03:34:47 -0000 1.1
+++ lams_tool_forum/web/jsps/monitoring/definelater.jsp 16 Mar 2006 03:23:54 -0000 1.2
@@ -1,5 +1,4 @@
<%@ include file="/includes/taglibs.jsp" %>
-<%@ taglib uri="tags-fck-editor" prefix="FCK"%>
Index: lams_tool_forum/web/jsps/monitoring/editactivity.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/editactivity.jsp,v
diff -u -r1.8 -r1.9
--- lams_tool_forum/web/jsps/monitoring/editactivity.jsp 6 Mar 2006 03:34:56 -0000 1.8
+++ lams_tool_forum/web/jsps/monitoring/editactivity.jsp 16 Mar 2006 03:23:54 -0000 1.9
@@ -1,40 +1,45 @@
<%@ include file="/includes/taglibs.jsp"%>
+
-
-
-
-
- :
- |
-
-
- |
-
+
+
+
+
+
+ :
+ |
+
+
+ |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
Index: lams_tool_forum/web/jsps/monitoring/instructions.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/Attic/instructions.jsp,v
diff -u -r1.5 -r1.6
--- lams_tool_forum/web/jsps/monitoring/instructions.jsp 16 Jan 2006 00:00:49 -0000 1.5
+++ lams_tool_forum/web/jsps/monitoring/instructions.jsp 16 Mar 2006 03:23:54 -0000 1.6
@@ -1,91 +1,102 @@
-<%@ include file="/includes/taglibs.jsp" %>
+<%@ include file="/includes/taglibs.jsp"%>
+
+
-
-
\ No newline at end of file
+
+
+
Index: lams_tool_forum/web/jsps/monitoring/monitoring.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/monitoring.jsp,v
diff -u
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ lams_tool_forum/web/jsps/monitoring/monitoring.jsp 16 Mar 2006 03:23:54 -0000 1.1
@@ -0,0 +1,16 @@
+<%@ include file="/includes/taglibs.jsp"%>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Index: lams_tool_forum/web/jsps/monitoring/statistic.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/statistic.jsp,v
diff -u -r1.5 -r1.6
--- lams_tool_forum/web/jsps/monitoring/statistic.jsp 6 Mar 2006 05:23:14 -0000 1.5
+++ lams_tool_forum/web/jsps/monitoring/statistic.jsp 16 Mar 2006 03:23:54 -0000 1.6
@@ -1,65 +1,82 @@
-<%@ include file="/includes/taglibs.jsp" %>
-
+<%@ include file="/includes/taglibs.jsp"%>
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ :
+
+
+
+
+
+
+ |
+
+
+
+
+
+
+ |
+
+
+
+ |
+
+
+
+
+ |
+
+
+ |
+
+
-
-
-
-
-
-
- :
-
-
-
-
-
-
- |
-
-
-
-
|
-
|
-
-
- |
- |
-
-
-
-
+
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.6 -r1.7
--- lams_tool_forum/web/jsps/monitoring/updatemarks.jsp 6 Mar 2006 05:23:14 -0000 1.6
+++ lams_tool_forum/web/jsps/monitoring/updatemarks.jsp 16 Mar 2006 03:23:54 -0000 1.7
@@ -2,7 +2,7 @@
-" />
+" />
,
Index: lams_tool_forum/web/jsps/monitoring/viewactivity.jsp
===================================================================
RCS file: /usr/local/cvsroot/lams_tool_forum/web/jsps/monitoring/viewactivity.jsp,v
diff -u -r1.5 -r1.6
--- lams_tool_forum/web/jsps/monitoring/viewactivity.jsp 6 Mar 2006 03:39:13 -0000 1.5
+++ lams_tool_forum/web/jsps/monitoring/viewactivity.jsp 16 Mar 2006 03:23:54 -0000 1.6
@@ -1,37 +1,38 @@
<%@ include file="/includes/taglibs.jsp"%>
-
\ No newline at end of file
+
+
+