Index: lams_tool_doku/conf/language/lams/ApplicationResources.properties
===================================================================
diff -u -rb812eb010aa5c6d01ef10b19d6325900b7ae5963 -r4c8a81c2d65a0fd8be399d6e7e13935b7e796401
--- lams_tool_doku/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision b812eb010aa5c6d01ef10b19d6325900b7ae5963)
+++ lams_tool_doku/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision 4c8a81c2d65a0fd8be399d6e7e13935b7e796401)
@@ -179,3 +179,6 @@
label.cancel = Cancel
label.rating.textarea.tip = Leave a comment...
label.minimum.number.words = Minimum number of words in a comment {0}
+label.monitoring.ai.review = AI review
+label.monitoring.ai.review.all = AI review all
+label.monitoring.ai.review.tooltip = Have AI compare the given task and students' submissions.
\ No newline at end of file
Index: lams_tool_doku/src/java/org/lamsfoundation/lams/tool/dokumaran/web/controller/MonitoringController.java
===================================================================
diff -u -r52a6369ce66a2ea70d38bfa2e627dfcde6354b10 -r4c8a81c2d65a0fd8be399d6e7e13935b7e796401
--- lams_tool_doku/src/java/org/lamsfoundation/lams/tool/dokumaran/web/controller/MonitoringController.java (.../MonitoringController.java) (revision 52a6369ce66a2ea70d38bfa2e627dfcde6354b10)
+++ lams_tool_doku/src/java/org/lamsfoundation/lams/tool/dokumaran/web/controller/MonitoringController.java (.../MonitoringController.java) (revision 4c8a81c2d65a0fd8be399d6e7e13935b7e796401)
@@ -187,6 +187,9 @@
dokumaranService.createEtherpadCookieForMonitor(user, contentId, response);
}
+ boolean isAiEnabled = Configuration.isLamsModuleAvailable(Configuration.AI_MODULE_CLASS);
+ request.setAttribute("isAiEnabled", isAiEnabled);
+
return "pages/monitoring/monitoring";
}
Index: lams_tool_doku/web/pages/monitoring/summary.jsp
===================================================================
diff -u -r52a6369ce66a2ea70d38bfa2e627dfcde6354b10 -r4c8a81c2d65a0fd8be399d6e7e13935b7e796401
--- lams_tool_doku/web/pages/monitoring/summary.jsp (.../summary.jsp) (revision 52a6369ce66a2ea70d38bfa2e627dfcde6354b10)
+++ lams_tool_doku/web/pages/monitoring/summary.jsp (.../summary.jsp) (revision 4c8a81c2d65a0fd8be399d6e7e13935b7e796401)
@@ -152,9 +152,9 @@
COUNT_RATED_ITEMS = true,
ALLOW_RERATE = false;
- $(document).ready(function(){
+ $(document).ready(function () {
// show etherpads only on Group expand
- $('#doku-monitoring-summary-${sessionMap.toolContentID} .etherpad-collapse').on('show.bs.collapse', function(){
+ $('#doku-monitoring-summary-${sessionMap.toolContentID} .etherpad-collapse').on('show.bs.collapse', function () {
var etherpad = $('.etherpad-container', this);
if (!etherpad.hasClass('initialised')) {
var id = etherpad.attr('id'),
@@ -163,7 +163,7 @@
}
});
- $("#doku-monitoring-summary-${sessionMap.toolContentID} .fix-faulty-pad").click(function() {
+ $("#doku-monitoring-summary-${sessionMap.toolContentID} .fix-faulty-pad").click(function () {
var toolSessionId = $(this).data("session-id");
var button = $(this);
@@ -178,7 +178,7 @@
backgroundColor: '#000',
'-webkit-border-radius': '10px',
'-moz-border-radius': '10px',
- opacity: .98 ,
+ opacity: .98,
left: "0px",
width: "360px"
},
@@ -190,7 +190,7 @@
$.ajax({
async: true,
url: '',
- data : 'toolSessionID=' + toolSessionId,
+ data: 'toolSessionID=' + toolSessionId,
type: 'post',
success: function (response) {
button.parent().html('');
@@ -209,42 +209,42 @@
// intialise tablesorter tables
tablesorters.tablesorter({
theme: 'bootstrap',
- headerTemplate : '{content} {icon}',
+ headerTemplate: '{content} {icon}',
sortInitialOrder: 'asc',
sortList: [[0]],
- widgets: [ "uitheme", "resizable", "editable" ],
- headers: { 0: { sorter: true}, 1: { sorter: true} },
- sortList : [[0,1]],
+ widgets: ["uitheme", "resizable", "editable"],
+ headers: {0: {sorter: true}, 1: {sorter: true}},
+ sortList: [[0, 1]],
showProcessing: false,
widgetOptions: {
resizable: true,
// only marks is editable
- editable_columns : [1],
- editable_enterToAccept : true, // press enter to accept content, or click outside if false
- editable_autoAccept : false, // accepts any changes made to the table cell automatically
- editable_autoResort : false, // auto resort after the content has changed.
- editable_validate : function (text, original, columnIndex) {
+ editable_columns: [1],
+ editable_enterToAccept: true, // press enter to accept content, or click outside if false
+ editable_autoAccept: false, // accepts any changes made to the table cell automatically
+ editable_autoResort: false, // auto resort after the content has changed.
+ editable_validate: function (text, original, columnIndex) {
// removing all text produces " ", so get rid of it
text = text ? text.replace(/ /g, '').trim() : null;
// acceptable values are empty text or a number
return !text || !isNaN(text) ? text : original;
},
- editable_selectAll : function(txt, columnIndex, $element) {
+ editable_selectAll: function (txt, columnIndex, $element) {
// note $element is the div inside of the table cell, so use $element.closest('td') to get the cell
// only select everthing within the element when the content starts with the letter "B"
return true;
},
- editable_wrapContent : '
', // wrap all editable cell content... makes this widget work in IE, and with autocomplete
- editable_trimContent : true, // trim content ( removes outer tabs & carriage returns )
- editable_editComplete : 'editComplete' // event fired after the table content has been edited
+ editable_wrapContent: '
', // wrap all editable cell content... makes this widget work in IE, and with autocomplete
+ editable_trimContent: true, // trim content ( removes outer tabs & carriage returns )
+ editable_editComplete: 'editComplete' // event fired after the table content has been edited
}
});
// update mark on edit
- tablesorters.each(function(){
+ tablesorters.each(function () {
// config event variable new in v2.17.6
- $(this).children('tbody').on('editComplete', 'td', function(event, config) {
+ $(this).children('tbody').on('editComplete', 'td', function (event, config) {
var $this = $(this),
mark = $this.text() ? +$this.text() : null,
toolSessionId = +$this.closest('.tablesorter').attr('toolSessionId'),
@@ -258,14 +258,14 @@
$.ajax({
async: true,
url: '',
- data : {
- 'toolSessionId' : toolSessionId,
- 'userId' : userId,
- 'mark' : mark,
- '' : ''
+ data: {
+ 'toolSessionId': toolSessionId,
+ 'userId': userId,
+ 'mark': mark,
+ '': ''
},
type: 'post',
- success : function (){
+ success: function () {
$this.closest('.marks-container').find('.copy-mark-button')
.data('mark', mark).show()
.find('.copy-mark-value').text(mark);
@@ -279,7 +279,7 @@
});
// pager processing
- tablesorters.each(function() {
+ tablesorters.each(function () {
var toolSessionId = $(this).attr('toolSessionId');
$(this).tablesorterPager({
@@ -293,28 +293,28 @@
cssPageDisplay: '.pagedisplay',
cssPageSize: '.pagesize',
cssDisabled: 'disabled',
- ajaxUrl : "" + toolSessionId,
+ ajaxUrl: "" + toolSessionId,
ajaxProcessing: function (data, table) {
if (data && data.hasOwnProperty('rows')) {
var rows = [],
json = {};
- for (i = 0; i < data.rows.length; i++){
+ for (i = 0; i < data.rows.length; i++) {
var userData = data.rows[i],
isLeader = userData['isLeader'];
rows += '