Index: lams_tool_scribe/conf/language/ApplicationResources.properties =================================================================== diff -u -rf3cf63705869db99a14402a308bd97570e0fd36d -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/conf/language/ApplicationResources.properties (.../ApplicationResources.properties) (revision f3cf63705869db99a14402a308bd97570e0fd36d) +++ lams_tool_scribe/conf/language/ApplicationResources.properties (.../ApplicationResources.properties) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -67,7 +67,7 @@ button.done =Done button.save =Save button.finish =Finish -button.reflect = Continue +button.continue = Continue button.next =Next label.save =Save label.cancel =Cancel @@ -112,6 +112,5 @@ message.voteStatistics = {0} out of {1} agree - - - +message.scribeInstructions = You, {0} are the scribe for your group class. In this window you need to summarise your group's responses to the headings as they discuss them in the chat room. The members of your group will click agree when they agree with what you have written. When everyone (including you) agrees your responses will be submitted.
Every time you update the text in the report (by clicking the "Update Report" button), everyone is set back to not being in agreement.
If the whole group cannot come to an agreement on the report, then you can force the activity to end by clicking "Force end". There must be the minimum amount agreed before this can happen. The minimum percentage is shown on the bar graph.
Warning: When you click "Agree", any changes you have made since the last "Update Report" are discarded. So if you make a change to the text, click "Update Report" and then "Agree". +message.learnerInstructions = You are about to enter a group chat and report. You should discuss the headings in the chat room with the rest of your group, class, and your scribe, {0} , will enter the groups findings.
If you agree with what is written, click on the agree button.
Once everyone has agreed, the text will be submitted and can no longer be changed. Index: lams_tool_scribe/db/sql/create_lams_tool_scribe.sql =================================================================== diff -u -r4b4b0d35dcce611d0cb85cab458f2e9687858ef0 -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/db/sql/create_lams_tool_scribe.sql (.../create_lams_tool_scribe.sql) (revision 4b4b0d35dcce611d0cb85cab458f2e9687858ef0) +++ lams_tool_scribe/db/sql/create_lams_tool_scribe.sql (.../create_lams_tool_scribe.sql) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -12,7 +12,7 @@ create table tl_lascrb11_report_entry (uid bigint not null auto_increment, entry_text text, scribe_heading_uid bigint, scribe_session_uid bigint, primary key (uid)); create table tl_lascrb11_scribe (uid bigint not null auto_increment, create_date datetime, update_date datetime, create_by bigint, title varchar(255), instructions text, run_offline bit, lock_on_finished bit, auto_select_scribe bit, reflect_on_activity bit, reflect_instructions text, online_instructions text, offline_instructions text, content_in_use bit, define_later bit, tool_content_id bigint, primary key (uid)); create table tl_lascrb11_session (uid bigint not null auto_increment, session_end_date datetime, session_start_date datetime, status integer, session_id bigint, session_name varchar(250), scribe_uid bigint, appointed_scribe_uid bigint, force_complete bit, primary key (uid)); -create table tl_lascrb11_user (uid bigint not null auto_increment, user_id bigint, last_name varchar(255), login_name varchar(255), first_name varchar(255), finishedActivity bit, scribe_session_uid bigint, report_approved bit, primary key (uid)); +create table tl_lascrb11_user (uid bigint not null auto_increment, user_id bigint, last_name varchar(255), login_name varchar(255), first_name varchar(255), finishedActivity bit, scribe_session_uid bigint, report_approved bit, started_activity bit, primary key (uid)); alter table tl_lascrb11_attachment add index FK57953706B3FA1495 (scribe_uid), add constraint FK57953706B3FA1495 foreign key (scribe_uid) references tl_lascrb11_scribe (uid); alter table tl_lascrb11_heading add index FK428A22FFB3FA1495 (scribe_uid), add constraint FK428A22FFB3FA1495 foreign key (scribe_uid) references tl_lascrb11_scribe (uid); alter table tl_lascrb11_report_entry add index FK5439FACAEA50D086 (scribe_heading_uid), add constraint FK5439FACAEA50D086 foreign key (scribe_heading_uid) references tl_lascrb11_heading (uid); Index: lams_tool_scribe/db/sql/table-schema.sql =================================================================== diff -u -r4b4b0d35dcce611d0cb85cab458f2e9687858ef0 -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/db/sql/table-schema.sql (.../table-schema.sql) (revision 4b4b0d35dcce611d0cb85cab458f2e9687858ef0) +++ lams_tool_scribe/db/sql/table-schema.sql (.../table-schema.sql) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -16,7 +16,7 @@ create table tl_lascrb11_report_entry (uid bigint not null auto_increment, entry_text text, scribe_heading_uid bigint, scribe_session_uid bigint, primary key (uid)); create table tl_lascrb11_scribe (uid bigint not null auto_increment, create_date datetime, update_date datetime, create_by bigint, title varchar(255), instructions text, run_offline bit, lock_on_finished bit, auto_select_scribe bit, reflect_on_activity bit, reflect_instructions text, online_instructions text, offline_instructions text, content_in_use bit, define_later bit, tool_content_id bigint, primary key (uid)); create table tl_lascrb11_session (uid bigint not null auto_increment, session_end_date datetime, session_start_date datetime, status integer, session_id bigint, session_name varchar(250), scribe_uid bigint, appointed_scribe_uid bigint, force_complete bit, primary key (uid)); -create table tl_lascrb11_user (uid bigint not null auto_increment, user_id bigint, last_name varchar(255), login_name varchar(255), first_name varchar(255), finishedActivity bit, scribe_session_uid bigint, report_approved bit, primary key (uid)); +create table tl_lascrb11_user (uid bigint not null auto_increment, user_id bigint, last_name varchar(255), login_name varchar(255), first_name varchar(255), finishedActivity bit, scribe_session_uid bigint, report_approved bit, started_activity bit, primary key (uid)); alter table tl_lascrb11_attachment add index FK57953706B3FA1495 (scribe_uid), add constraint FK57953706B3FA1495 foreign key (scribe_uid) references tl_lascrb11_scribe (uid); alter table tl_lascrb11_heading add index FK428A22FFB3FA1495 (scribe_uid), add constraint FK428A22FFB3FA1495 foreign key (scribe_uid) references tl_lascrb11_scribe (uid); alter table tl_lascrb11_report_entry add index FK5439FACAEA50D086 (scribe_heading_uid), add constraint FK5439FACAEA50D086 foreign key (scribe_heading_uid) references tl_lascrb11_heading (uid); Index: lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/model/ScribeUser.java =================================================================== diff -u -r84283f3449a27ed45130e07c53d2cefc451ba537 -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/model/ScribeUser.java (.../ScribeUser.java) (revision 84283f3449a27ed45130e07c53d2cefc451ba537) +++ lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/model/ScribeUser.java (.../ScribeUser.java) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -59,6 +59,8 @@ private boolean reportApproved; + private boolean startedActivity; + // Constructors /** default constructor */ @@ -72,6 +74,7 @@ this.loginName = user.getLogin(); this.scribeSession = scribeSession; this.finishedActivity = false; + this.startedActivity = false; } /** full constructor */ @@ -178,6 +181,17 @@ } /** + * @hibernate.property column="started_activity" + */ + public boolean isStartedActivity() { + return startedActivity; + } + + public void setStartedActivity(boolean startedActivity) { + this.startedActivity = startedActivity; + } + + /** * toString * * @return String Index: lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/web/actions/LearningAction.java =================================================================== diff -u -r4b4b0d35dcce611d0cb85cab458f2e9687858ef0 -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/web/actions/LearningAction.java (.../LearningAction.java) (revision 4b4b0d35dcce611d0cb85cab458f2e9687858ef0) +++ lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/web/actions/LearningAction.java (.../LearningAction.java) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -73,6 +73,7 @@ * @struts.action-forward name="notebook" path="tiles:/learning/notebook" * @struts.action-forward name="voteDisplay" path="/pages/parts/voteDisplay.jsp" * @struts.action-forward name="report" path="tiles:/learning/report" + * @struts.action-forward name="instructions" path="tiles:/learning/instructions" */ public class LearningAction extends LamsDispatchAction { @@ -114,7 +115,7 @@ // Retrieve the current user ScribeUser scribeUser = getCurrentUser(toolSessionID); - + // check whether scribe has been appointed ScribeUser appointedScribe = scribeSession.getAppointedScribe(); if (appointedScribe == null) { @@ -129,7 +130,8 @@ scribeService.saveOrUpdateScribeSession(scribeSession); } } - + + // setup dto's forms and attributes. ((LearningForm)form).setToolSessionID(scribeSession.getSessionId()); request.setAttribute("MODE", mode.toString()); setupDTOs(request, scribeSession, scribeUser); @@ -145,11 +147,22 @@ return mapping.findForward("runOffline"); } + // check force complete if (scribeSession.isForceComplete()) { // go to report page return mapping.findForward("report"); } + // check if user has started activity + if (!scribeUser.isStartedActivity()) { + if (scribeSession.getAppointedScribe().getUid() == scribeUser.getUid()) { + request.setAttribute("role", "scribe"); + } else { + request.setAttribute("role", "learner"); + } + return mapping.findForward("instructions"); + } + // check if current user is the scribe. if (scribeSession.getAppointedScribe().getUid() == scribeUser.getUid()) { return mapping.findForward("scribe"); @@ -159,23 +172,48 @@ } - private ScribeUser getCurrentUser(Long toolSessionId) { + private ScribeUser getCurrentUser(Long toolSessionID) { UserDTO user = (UserDTO) SessionManager.getSession().getAttribute( AttributeNames.USER); - // attempt to retrieve user using userId and toolSessionId + // attempt to retrieve user using userId and toolSessionID ScribeUser scribeUser = scribeService.getUserByUserIdAndSessionId( - new Long(user.getUserID().intValue()), toolSessionId); + new Long(user.getUserID().intValue()), toolSessionID); if (scribeUser == null) { ScribeSession scribeSession = scribeService - .getSessionBySessionId(toolSessionId); + .getSessionBySessionId(toolSessionID); scribeUser = scribeService.createScribeUser(user, scribeSession); } return scribeUser; } + public ActionForward startActivity(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) { + + LearningForm lrnForm = (LearningForm)form; + Long toolSessionID = lrnForm.getToolSessionID(); + + ScribeSession scribeSession = scribeService.getSessionBySessionId(toolSessionID); + ScribeUser scribeUser = getCurrentUser(toolSessionID); + + // setup dto's, forms and attributes. + lrnForm.setToolSessionID(scribeSession.getSessionId()); + request.setAttribute("MODE", lrnForm.getMode()); + setupDTOs(request, scribeSession, scribeUser); + + // update scribe user and go to instructions page + scribeUser.setStartedActivity(true); + scribeService.saveOrUpdateScribeUser(scribeUser); + + // check if current user is the scribe. + if (scribeSession.getAppointedScribe().getUid() == scribeUser.getUid()) { + return mapping.findForward("scribe"); + } + + return mapping.findForward("learning"); + } + public ActionForward finishActivity(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) { Index: lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/web/actions/MonitoringAction.java =================================================================== diff -u -r06c2af4dcb52885a46843b1addc693af52754c95 -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/web/actions/MonitoringAction.java (.../MonitoringAction.java) (revision 06c2af4dcb52885a46843b1addc693af52754c95) +++ lams_tool_scribe/src/java/org/lamsfoundation/lams/tool/scribe/web/actions/MonitoringAction.java (.../MonitoringAction.java) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -178,17 +178,17 @@ } - private ScribeUser getCurrentUser(Long toolSessionId) { + private ScribeUser getCurrentUser(Long toolSessionID) { UserDTO user = (UserDTO) SessionManager.getSession().getAttribute( AttributeNames.USER); - // attempt to retrieve user using userId and toolSessionId + // attempt to retrieve user using userId and toolSessionID ScribeUser scribeUser = scribeService.getUserByUserIdAndSessionId(new Long( - user.getUserID().intValue()), toolSessionId); + user.getUserID().intValue()), toolSessionID); if (scribeUser == null) { ScribeSession scribeSession = scribeService - .getSessionBySessionId(toolSessionId); + .getSessionBySessionId(toolSessionID); scribeUser = scribeService.createScribeUser(user, scribeSession); } Index: lams_tool_scribe/web/WEB-INF/struts/tiles-defs.xml =================================================================== diff -u -r4b4b0d35dcce611d0cb85cab458f2e9687858ef0 -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/web/WEB-INF/struts/tiles-defs.xml (.../tiles-defs.xml) (revision 4b4b0d35dcce611d0cb85cab458f2e9687858ef0) +++ lams_tool_scribe/web/WEB-INF/struts/tiles-defs.xml (.../tiles-defs.xml) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -126,6 +126,10 @@ + + + + Index: lams_tool_scribe/web/pages/learning/instructions.jsp =================================================================== diff -u --- lams_tool_scribe/web/pages/learning/instructions.jsp (revision 0) +++ lams_tool_scribe/web/pages/learning/instructions.jsp (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -0,0 +1,38 @@ +<%@ include file="/common/taglibs.jsp"%> + +
+

+ +

+ + +

+ + + +

+
+ + +

+ + + +

+
+ + +

+ + + + + + +

+
+ +
+
+ + Index: lams_tool_scribe/web/pages/learning/parts/finishButton.jsp =================================================================== diff -u -r676776bec1c35957910e6911d9f7d280f646d28d -r0697c7a71301d7d5d468f4051de6761cf5904606 --- lams_tool_scribe/web/pages/learning/parts/finishButton.jsp (.../finishButton.jsp) (revision 676776bec1c35957910e6911d9f7d280f646d28d) +++ lams_tool_scribe/web/pages/learning/parts/finishButton.jsp (.../finishButton.jsp) (revision 0697c7a71301d7d5d468f4051de6761cf5904606) @@ -7,7 +7,7 @@ - +