Index: lams_tool_task/conf/language/lams/ApplicationResources.properties =================================================================== diff -u -rbe42ba5063335619d4e04832ea235f96b82f0e53 -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision be42ba5063335619d4e04832ea235f96b82f0e53) +++ lams_tool_task/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -28,7 +28,11 @@ label.authoring.basic.description =Description label.authoring.basic.add.task =Add Task label.authoring.basic.task.isRequired =Required task -label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments/files for this task +label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments +label.authoring.basic.task.isCommentsRequired =Are comments required to complete task +label.authoring.basic.task.isFilesAllowed =Allow participants to add files +label.authoring.basic.task.isFilesRequired =Are files required to complete task +label.authoring.basic.task.isCommentsFilesAllowed =Allow participants to add comments/files for this task label.authoring.basic.task.show.only.to.monitoring =Show only to monitoring label.authoring.basic.task.show.to.all.learners =Show to all learners label.authoring.basic.task.isChildTask =Don't display until parent has been completed @@ -102,6 +106,7 @@ monitoring.label.number.learners =Number of Learners monitoring.label.user.loginname =Login name monitoring.label.user.name =Name +monitoring.label.group =Group label.monitoring.heading.access =Learners list label.monitoring.edit.activity.edit =Edit label.monitoring.summary.overall.summary =Overall Summary Index: lams_tool_task/conf/language/lams/ApplicationResources_en_AU.properties =================================================================== diff -u -rbe42ba5063335619d4e04832ea235f96b82f0e53 -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/conf/language/lams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision be42ba5063335619d4e04832ea235f96b82f0e53) +++ lams_tool_task/conf/language/lams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -24,7 +24,11 @@ label.authoring.basic.description =Description label.authoring.basic.add.task =Add Task label.authoring.basic.task.isRequired =Required task -label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments/files for this task +label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments +label.authoring.basic.task.isCommentsRequired =Are comments required to complete task +label.authoring.basic.task.isFilesAllowed =Allow participants to add files +label.authoring.basic.task.isFilesRequired =Are files required to complete task +label.authoring.basic.task.isCommentsFilesAllowed =Allow participants to add comments/files for this task label.authoring.basic.task.show.only.to.monitoring =Show only to monitoring label.authoring.basic.task.show.to.all.learners =Show to all learners label.authoring.basic.task.isChildTask =Don't display until parent has been completed @@ -87,6 +91,7 @@ monitoring.label.number.learners =Number of Learners monitoring.label.user.loginname =Login name monitoring.label.user.name =Name +monitoring.label.group =Group label.monitoring.heading.access =Learners list label.monitoring.edit.activity.cancel =Cancel label.monitoring.edit.activity.update =Update Index: lams_tool_task/conf/language/rams/ApplicationResources.properties =================================================================== diff -u -rbe42ba5063335619d4e04832ea235f96b82f0e53 -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/conf/language/rams/ApplicationResources.properties (.../ApplicationResources.properties) (revision be42ba5063335619d4e04832ea235f96b82f0e53) +++ lams_tool_task/conf/language/rams/ApplicationResources.properties (.../ApplicationResources.properties) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -28,7 +28,11 @@ label.authoring.basic.description =Description label.authoring.basic.add.task =Add Task label.authoring.basic.task.isRequired =Required task -label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments/files for this task +label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments +label.authoring.basic.task.isCommentsRequired =Are comments required to complete task +label.authoring.basic.task.isFilesAllowed =Allow participants to add files +label.authoring.basic.task.isFilesRequired =Are files required to complete task +label.authoring.basic.task.isCommentsFilesAllowed =Allow participants to add comments/files for this task label.authoring.basic.task.show.only.to.monitoring =Show only to monitoring label.authoring.basic.task.show.to.all.learners =Show to all learners label.authoring.basic.task.isChildTask =Don't display until parent has been completed @@ -102,6 +106,7 @@ monitoring.label.number.learners =Number of Learners monitoring.label.user.loginname =Login name monitoring.label.user.name =Name +monitoring.label.group =Group label.monitoring.heading.access =Learners list label.monitoring.edit.activity.edit =Edit label.monitoring.summary.overall.summary =Overall Summary Index: lams_tool_task/conf/language/rams/ApplicationResources_en_AU.properties =================================================================== diff -u -rbe42ba5063335619d4e04832ea235f96b82f0e53 -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/conf/language/rams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision be42ba5063335619d4e04832ea235f96b82f0e53) +++ lams_tool_task/conf/language/rams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -28,7 +28,11 @@ label.authoring.basic.description =Description label.authoring.basic.add.task =Add Task label.authoring.basic.task.isRequired =Required task -label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments/files for this task +label.authoring.basic.task.isCommentsAllowed =Allow participants to add comments +label.authoring.basic.task.isCommentsRequired =Are comments required to complete task +label.authoring.basic.task.isFilesAllowed =Allow participants to add files +label.authoring.basic.task.isFilesRequired =Are files required to complete task +label.authoring.basic.task.isCommentsFilesAllowed =Allow participants to add comments/files for this task label.authoring.basic.task.show.only.to.monitoring =Show only to monitoring label.authoring.basic.task.show.to.all.learners =Show to all learners label.authoring.basic.task.isChildTask =Don't display until parent has been completed @@ -102,6 +106,7 @@ monitoring.label.number.learners =Number of Learners monitoring.label.user.loginname =Login name monitoring.label.user.name =Name +monitoring.label.group =Group label.monitoring.heading.access =Learners list label.monitoring.edit.activity.edit =Edit label.monitoring.summary.overall.summary =Overall Summary Index: lams_tool_task/db/model/taskList.clay =================================================================== diff -u -rfe31f08d68bebdde45fb5597de931d532ce7aace -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/db/model/taskList.clay (.../taskList.clay) (revision fe31f08d68bebdde45fb5597de931d532ce7aace) +++ lams_tool_task/db/model/taskList.clay (.../taskList.clay) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -586,7 +586,7 @@ - + @@ -698,12 +698,36 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + Index: lams_tool_task/db/sql/create_lams_tool_taskList.sql =================================================================== diff -u -rfe31f08d68bebdde45fb5597de931d532ce7aace -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/db/sql/create_lams_tool_taskList.sql (.../create_lams_tool_taskList.sql) (revision fe31f08d68bebdde45fb5597de931d532ce7aace) +++ lams_tool_task/db/sql/create_lams_tool_taskList.sql (.../create_lams_tool_taskList.sql) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -64,6 +64,10 @@ create_by_author tinyint, is_required tinyint, is_comments_allowed tinyint, + is_comments_required tinyint, + is_files_allowed tinyint, + is_files_required tinyint, + is_comments_files_allowed tinyint, show_comments_to_all tinyint, is_child_task tinyint, parent_task_name varchar(255), @@ -146,7 +150,7 @@ `lock_when_finished`, `is_sequential_order`, `allow_contribute_tasks`, `is_monitor_verification_required`, `reflect_on_activity`) VALUES (1,NULL,NULL,NULL,'TaskList','0','Instructions ',null,null,0,0,${default_content_id},0,0,0,0,0); -INSERT INTO `tl_latask10_taskList_item` (`uid`, `sequence_id`, `description`, `init_item`, `organization_xml`, `title`, `create_by`, `create_date`, `create_by_author`, `is_required`, `is_comments_allowed`, `show_comments_to_all`, `is_child_task`, `parent_task_name`, `taskList_uid`, `session_uid`) VALUES - (1,1,NULL,NULL,NULL,'Task number 1',null,NOW(),1,0,0,0,0,NULL,1,NULL); +INSERT INTO `tl_latask10_taskList_item` (`uid`, `sequence_id`, `description`, `init_item`, `organization_xml`, `title`, `create_by`, `create_date`, `create_by_author`, `is_required`, `is_comments_allowed`, `is_comments_required`, `is_files_allowed`, `is_files_required`, `is_comments_files_allowed`, `show_comments_to_all`, `is_child_task`, `parent_task_name`, `taskList_uid`, `session_uid`) VALUES + (1,1,NULL,NULL,NULL,'Task number 1',null,NOW(),1,0,0,0,0,0,0,1,0,NULL,1,NULL); SET FOREIGN_KEY_CHECKS=1; Index: lams_tool_task/db/sql/table-schema.sql =================================================================== diff -u -ra370ee2f7fe049337ac7b342e0218bdde3f3ee68 -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/db/sql/table-schema.sql (.../table-schema.sql) (revision a370ee2f7fe049337ac7b342e0218bdde3f3ee68) +++ lams_tool_task/db/sql/table-schema.sql (.../table-schema.sql) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -28,7 +28,7 @@ create table tl_latask10_item_comment (uid bigint not null auto_increment, comment varchar(255), taskList_item_uid bigint, create_by bigint, create_date datetime, primary key (uid)); create table tl_latask10_session (uid bigint not null auto_increment, session_end_date datetime, session_start_date datetime, status integer, taskList_uid bigint, session_id bigint, session_name varchar(250), primary key (uid)); create table tl_latask10_taskList (uid bigint not null auto_increment, create_date datetime, update_date datetime, create_by bigint, title varchar(255), run_offline bit, instructions text, online_instructions text, offline_instructions text, content_in_use bit, define_later bit, content_id bigint unique, lock_when_finished bit, allow_contribute_tasks bit, is_monitor_verification_required bit, is_sequential_order bit, reflect_instructions varchar(255), reflect_on_activity bit, primary key (uid)); -create table tl_latask10_taskList_item (uid bigint not null auto_increment, description varchar(255), init_item varchar(255), organization_xml text, title varchar(255), create_by bigint, create_date datetime, create_by_author bit, sequence_id integer, is_required bit, is_comments_allowed bit, show_comments_to_all bit, is_child_task bit, parent_task_name varchar(255), taskList_uid bigint, session_uid bigint, primary key (uid)); +create table tl_latask10_taskList_item (uid bigint not null auto_increment, description varchar(255), init_item varchar(255), organization_xml text, title varchar(255), create_by bigint, create_date datetime, create_by_author bit, sequence_id integer, is_required bit, is_comments_allowed bit, is_comments_required bit, is_files_allowed bit, is_files_required bit, is_comments_files_allowed bit, show_comments_to_all bit, is_child_task bit, parent_task_name varchar(255), taskList_uid bigint, session_uid bigint, primary key (uid)); create table tl_latask10_user (uid bigint not null auto_increment, user_id bigint, last_name varchar(255), first_name varchar(255), login_name varchar(255), session_uid bigint, taskList_uid bigint, session_finished bit, is_verified_by_monitor bit, primary key (uid)); alter table tl_latask10_attachment add index FK281134C2994F51CE (taskList_uid), add constraint FK281134C2994F51CE foreign key (taskList_uid) references tl_latask10_taskList (uid); Index: lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/model/TaskListItem.java =================================================================== diff -u -r0e7e464ded505f35e6ade3811f3f74658668e13a -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/model/TaskListItem.java (.../TaskListItem.java) (revision 0e7e464ded505f35e6ade3811f3f74658668e13a) +++ lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/model/TaskListItem.java (.../TaskListItem.java) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -57,12 +57,17 @@ //general infomation private Date createDate; private TaskListUser createBy; - //advance + //advanced private boolean isRequired; private boolean isCommentsAllowed; - private boolean showCommentsToAll; + private boolean isCommentsRequired; + private boolean isFilesAllowed; + private boolean isFilesRequired; private boolean isChildTask; private String parentTaskName; + //advanced options that are not used now + private boolean isCommentsFilesAllowed; + private boolean showCommentsToAll; //Set of uploaded files private Set attachments; @@ -79,6 +84,11 @@ public TaskListItem(){ attachments = new HashSet(); comments = new HashSet(); + + // TODO doing this because it will be not visible on the authoring page. + // get rid of this when it'll be defined if it's needs or not finally. + isCommentsFilesAllowed = true; + showCommentsToAll = true; } // ********************************************************** @@ -286,19 +296,8 @@ public void setRequired(boolean isRequired) { this.isRequired = isRequired; } - + /** - * @hibernate.property column="show_comments_to_all" - * @return - */ - public boolean getShowCommentsToAll() { - return showCommentsToAll; - } - public void setShowCommentsToAll(boolean showCommentsToAll) { - this.showCommentsToAll = showCommentsToAll; - } - - /** * @hibernate.property column="is_comments_allowed" * @return */ @@ -308,6 +307,39 @@ public void setCommentsAllowed(boolean isCommentsAllowed) { this.isCommentsAllowed = isCommentsAllowed; } + + /** + * @hibernate.property column="is_comments_required" + * @return + */ + public boolean isCommentsRequired() { + return isCommentsRequired; + } + public void setCommentsRequired(boolean isCommentsRequired) { + this.isCommentsRequired = isCommentsRequired; + } + + /** + * @hibernate.property column="is_files_allowed" + * @return + */ + public boolean isFilesAllowed() { + return isFilesAllowed; + } + public void setFilesAllowed(boolean isFilesAllowed) { + this.isFilesAllowed = isFilesAllowed; + } + + /** + * @hibernate.property column="is_files_required" + * @return + */ + public boolean isFilesRequired() { + return isFilesRequired; + } + public void setFilesRequired(boolean isFilesRequired) { + this.isFilesRequired = isFilesRequired; + } /** * @hibernate.property column="is_child_task" @@ -330,8 +362,30 @@ public void setParentTaskName(String parentTaskName) { this.parentTaskName = parentTaskName; } + + /** + * @hibernate.property column="show_comments_to_all" + * @return + */ + public boolean getShowCommentsToAll() { + return showCommentsToAll; + } + public void setShowCommentsToAll(boolean showCommentsToAll) { + this.showCommentsToAll = showCommentsToAll; + } /** + * @hibernate.property column="is_comments_files_allowed" + * @return + */ + public boolean isCommentsFilesAllowed() { + return isCommentsFilesAllowed; + } + public void setCommentsFilesAllowed(boolean isCommentsFilesAllowed) { + this.isCommentsFilesAllowed = isCommentsFilesAllowed; + } + + /** * @hibernate.set lazy="true" * cascade="all" * inverse="false" Index: lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/web/action/AuthoringAction.java =================================================================== diff -u -r7dd15ff5149a5f87efd7cef5304819bf1bd0b78f -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/web/action/AuthoringAction.java (.../AuthoringAction.java) (revision 7dd15ff5149a5f87efd7cef5304819bf1bd0b78f) +++ lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/web/action/AuthoringAction.java (.../AuthoringAction.java) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -927,15 +927,14 @@ form.setItemIndex(new Integer(itemIdx).toString()); form.setRequired(item.isRequired()); form.setCommentsAllowed(item.isCommentsAllowed()); - form.setShowCommentsToAll(item.getShowCommentsToAll()); + form.setCommentsRequired(item.isCommentsRequired()); + form.setFilesAllowed(item.isFilesAllowed()); + form.setFilesRequired(item.isFilesRequired()); + //commented out for now. Waiting for the final decision -- if it's gonna be used in Authoring. +// form.setCommentsFilesAllowed(item.isCommentsFilesAllowed()); +// form.setShowCommentsToAll(item.getShowCommentsToAll()); form.setChildTask(item.isChildTask()); form.setParentTaskName(item.getParentTaskName()); - - //FOR requirment from LDEV-754 - //add extra blank line for instructions - // for(int idx=0;idx rList = new ArrayList(taskListList); item = rList.get(itemIdx); } - /* Set following fields regards to the type: - item.setFileUuid(); - item.setFileVersionId(); - item.setFileType(); - item.setFileName(); - - item.getInitialItem() - item.setImsSchema() - item.setOrganizationXml() - */ item.setTitle(itemForm.getTitle()); item.setDescription(itemForm.getDescription()); item.setCreateByAuthor(true); item.setRequired(itemForm.isRequired()); item.setCommentsAllowed(itemForm.isCommentsAllowed()); - item.setShowCommentsToAll(itemForm.getShowCommentsToAll()); + item.setCommentsRequired(itemForm.isCommentsRequired()); + item.setFilesAllowed(itemForm.isFilesAllowed()); + item.setFilesRequired(itemForm.isFilesRequired()); + //commented out for now. Waiting for the final decision -- if it's gonna be used in Authoring. +// item.setCommentsFilesAllowed(itemForm.isCommentsAllowed()); +// item.setShowCommentsToAll(itemForm.getShowCommentsToAll()); item.setChildTask(itemForm.isChildTask()); item.setParentTaskName(itemForm.getParentTaskName()); } Index: lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/web/form/TaskListItemForm.java =================================================================== diff -u -r1ef27bf016b647ea0c2803d22f2bb4d4b3cde650 -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/web/form/TaskListItemForm.java (.../TaskListItemForm.java) (revision 1ef27bf016b647ea0c2803d22f2bb4d4b3cde650) +++ lams_tool_task/src/java/org/lamsfoundation/lams/tool/taskList/web/form/TaskListItemForm.java (.../TaskListItemForm.java) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -46,9 +46,15 @@ private boolean isRequired; private boolean isCommentsAllowed; - private boolean showCommentsToAll; + private boolean isCommentsRequired; + private boolean isFilesAllowed; + private boolean isFilesRequired; private boolean isChildTask; + //commented out for now. Waiting for the final decision -- if it's gonna be used in Authoring. +// private boolean isCommentsFilesAllowed; +// private boolean showCommentsToAll; + private String parentTaskName; private FormFile uploadedFile; @@ -172,24 +178,95 @@ public void setCommentsAllowed(boolean isCommentsAllowed) { this.isCommentsAllowed = isCommentsAllowed; } + + /** + * Returns whether comments are required to complete this TaskLiskItem. + * + * @return true if comments are required to complete this TaskLiskItem, false otherwise. + */ + public boolean isCommentsRequired() { + return isCommentsRequired; + } + /** + * Sets whether comments are required to complete this TaskLiskItem. + * + * @param isCommentsAllowed true if comments are required to complete this TaskLiskItem, false otherwise. + */ + public void setCommentsRequired(boolean isCommentsRequired) { + this.isCommentsRequired = isCommentsRequired; + } + + /** + * Returns whether files are allowed in this TaskLiskItem. + * + * @return true if files are allowed in this TaskLiskItem, false otherwise. + */ + public boolean isFilesAllowed() { + return isFilesAllowed; + } + /** + * Sets whether files are allowed in this TaskLiskItem. + * + * @param isCommentsAllowed true if files are allowed in this TaskLiskItem, false otherwise. + */ + public void setFilesAllowed(boolean isFilesAllowed) { + this.isFilesAllowed = isFilesAllowed; + } + + /** - * Returns whether comments are allowed to be shown to everybody for this TaskLiskItem. + * Returns whether files are required to complete this TaskLiskItem. * - * @return true if comments are allowed to be shown to everybody for this TaskLiskItem, false otherwise. + * @return true if files are required to complete this TaskLiskItem, false otherwise. */ - public boolean getShowCommentsToAll() { - return showCommentsToAll; + public boolean isFilesRequired() { + return isFilesRequired; } /** - * Sets whether comments are allowed to be shown to everybody for this TaskLiskItem or not. + * Sets whether files are required to complete this TaskLiskItem. * - * @param showCommentsToAll true if comments are allowed to be shown to everybody for this TaskLiskItem, false otherwise. + * @param isCommentsAllowed true if files are required to complete this TaskLiskItem, false otherwise. */ - public void setShowCommentsToAll(boolean showCommentsToAll) { - this.showCommentsToAll = showCommentsToAll; + public void setFilesRequired(boolean isFilesRequired) { + this.isFilesRequired = isFilesRequired; } + //commented out for now. Waiting for the final decision -- if it's gonna be used in Authoring. +// /** +// * Returns whether comments are allowed in this TaskLiskItem. +// * +// * @return true if comments are allowed in this TaskLiskItem, false otherwise. +// */ +// public boolean isCommentsFilesAllowed() { +// return isCommentsFilesAllowed; +// } +// /** +// * Sets whether comments are allowed in this TaskLiskItem. +// * +// * @param isCommentsAllowed true if comments are allowed in this TaskLiskItem, false otherwise. +// */ +// public void setCommentsFilesAllowed(boolean isCommentsFilesAllowed) { +// this.isCommentsFilesAllowed = isCommentsFilesAllowed; +// } +// +// /** +// * Returns whether comments are allowed to be shown to everybody for this TaskLiskItem. +// * +// * @return true if comments are allowed to be shown to everybody for this TaskLiskItem, false otherwise. +// */ +// public boolean getShowCommentsToAll() { +// return showCommentsToAll; +// } +// /** +// * Sets whether comments are allowed to be shown to everybody for this TaskLiskItem or not. +// * +// * @param showCommentsToAll true if comments are allowed to be shown to everybody for this TaskLiskItem, false otherwise. +// */ +// public void setShowCommentsToAll(boolean showCommentsToAll) { +// this.showCommentsToAll = showCommentsToAll; +// } + /** * Returns whether this TaskLiskItem is a child task. * Index: lams_tool_task/web/pages/authoring/parts/addtask.jsp =================================================================== diff -u -r1ef27bf016b647ea0c2803d22f2bb4d4b3cde650 -r19d959536ea84101c37b8a6475bd9c561950b302 --- lams_tool_task/web/pages/authoring/parts/addtask.jsp (.../addtask.jsp) (revision 1ef27bf016b647ea0c2803d22f2bb4d4b3cde650) +++ lams_tool_task/web/pages/authoring/parts/addtask.jsp (.../addtask.jsp) (revision 19d959536ea84101c37b8a6475bd9c561950b302) @@ -50,15 +50,59 @@ + +
+ + + +
+
+        + + + + + +
+ +
+ + + + +
+ +
+        + + + + +
+ +<%-- +
@@ -83,7 +127,9 @@ +--%> +
${sessionMap.taskListItemDescription}

- +