Index: lams_central/conf/language/lams/ApplicationResources_en_AU.properties =================================================================== diff -u -re0265c3507ca12f61524934309a32092296fe601 -r0751e64daecb64ee15d7c004a66b3ad5c8b6e26a --- lams_central/conf/language/lams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision e0265c3507ca12f61524934309a32092296fe601) +++ lams_central/conf/language/lams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision 0751e64daecb64ee15d7c004a66b3ad5c8b6e26a) @@ -893,4 +893,6 @@ authoring.tbl.delete.mcq.prompt=Do you want to delete the RAT Question {0}? authoring.application.exercise.allow.multiple.responses =Allow Multiple Responses authoring.application.exercise.allow.multiple.responses.tooltip =When learners are allowed to select multiple answers the grade is the sum of the grade for all correct responses selected. +message.teacher.role.not.recognized =Please wait for a teacher to start the lesson. (You were logged in as a learner, as your current role does not conform LTI specification). + #======= End labels: Exported 872 labels for en AU ===== Index: lams_central/src/java/org/lamsfoundation/lams/web/controller/LtiController.java =================================================================== diff -u -r39c16d5d248419593b4012a0b9adb0adca43970d -r0751e64daecb64ee15d7c004a66b3ad5c8b6e26a --- lams_central/src/java/org/lamsfoundation/lams/web/controller/LtiController.java (.../LtiController.java) (revision 39c16d5d248419593b4012a0b9adb0adca43970d) +++ lams_central/src/java/org/lamsfoundation/lams/web/controller/LtiController.java (.../LtiController.java) (revision 0751e64daecb64ee15d7c004a66b3ad5c8b6e26a) @@ -148,12 +148,13 @@ //check if learner tries to access the link that hasn't been authored by teacher yet String method = request.getParameter("_" + LoginRequestDispatcher.PARAM_METHOD); if (LoginRequestDispatcher.METHOD_LEARNER_STRICT_AUTHENTICATION.equals(method) && extLessonMap == null) { - String errorMsg = "Learner tries to access the link that hasn't been authored by teacher yet. resource_link_id: " - + tcGradebookId; - log.debug(errorMsg); - request.setAttribute("error", errorMsg); - request.setAttribute("javax.servlet.error.exception", new UserAccessDeniedException(errorMsg)); - return "error"; + String roles = request.getParameter(BasicLTIConstants.ROLES); + //try to detect monitor with custom roles not supported by LTI specification + String messageKey = roles.contains("Instructor") || roles.contains("Admin") ? "message.teacher.role.not.recognized" + : "message.lesson.not.started.cannot.participate"; + + request.setAttribute("messageKey", messageKey); + return "msgContent"; } //determine whether to show author or learnerMonitor pages