Index: lams_tool_lamc/web/learning/AnswersContent.jsp =================================================================== diff -u -r732f77a31113c5838d0704829b99418d90053471 -rc048314fbc71e9f6125f8298849b394f45ff6c55 --- lams_tool_lamc/web/learning/AnswersContent.jsp (.../AnswersContent.jsp) (revision 732f77a31113c5838d0704829b99418d90053471) +++ lams_tool_lamc/web/learning/AnswersContent.jsp (.../AnswersContent.jsp) (revision c048314fbc71e9f6125f8298849b394f45ff6c55) @@ -1,164 +1,181 @@ - - + <%@ include file="/common/taglibs.jsp"%> - - - - - - - - - - + + + + + + <fmt:message key="activity.title" /> - - +div.growlUI { + background: url(check48.png) no-repeat 10px 10px +} + +div.growlUI h1, div.growlUI h2 { + color: white; + padding: 5px 5px 5px 0px; + text-align: center; +} + + - + + + function submitAllAnswers() { + document.McLearningForm.continueOptionsCombined.value = 1; + doSubmit(); + } + + function doSubmit() { + if (verifyAllQuestionsAnswered()) { + disableContinueButton(); + document.McLearningForm.submit(); + } + } + + function verifyAllQuestionsAnswered() { + // in case oneQuestionPerPage option is ON user has to select 1 answer, and all answers otherwise + var isOneQuestionPerPage = ${mcGeneralLearnerFlowDTO.questionListingMode == 'questionListingModeSequential'}; + var answersRequiredNumber = (isOneQuestionPerPage) ? 1 : ${fn:length(requestScope.learnerAnswersDTOList)}; + + //check each question is answered + if ($(':radio:checked').length == answersRequiredNumber) { + return true; + + } else { + var msg = ""; + alert(msg); + return false; + } + } + + function disableContinueButton() { + var elem = document.getElementById("continueButton"); + if (elem != null) { + elem.disabled = true; + } + } + + if (${!hasEditRight && mode != "teacher"}) { + setInterval("checkLeaderProgress();",60000);// Auto-Refresh every 1 minute for non-leaders + } + + function checkLeaderProgress() { + + $.ajax({ + async: false, + url: '', + data: 'method=checkLeaderProgress&toolSessionID=' + $("#tool-session-id").val(), + dataType: 'json', + type: 'post', + success: function (json) { + if (json.isLeaderResponseFinalized) { + location.reload(); + } + } + }); + } + + -
+ -

- -

+
+ +
- - - - - - - - - - - - <%@ include file="/common/messages.jsp"%> - - -

- - ${sessionMap.groupLeader.fullname} + + + + + + + -

+
- - - - - - - - - -
-
- + + + ( ) + + + +
+ + + + + + + + + + + + <%@ include file="/common/messages.jsp"%> + + +

+ + ${sessionMap.groupLeader.fullname} + +

+
+ + + + + + + + + +
+
+
- +