Index: lams_central/conf/language/lams/ApplicationResources.properties =================================================================== diff -u -rd36e6ae1ccdcaa702333d0dc2888aa4dfee4a078 -r4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1 --- lams_central/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision d36e6ae1ccdcaa702333d0dc2888aa4dfee4a078) +++ lams_central/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision 4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1) @@ -699,5 +699,6 @@ label.password.must.ucase =at least 1 upper case letter label.password.must.number=at least 1 number label.password.must.symbol =at least 1 symbol +label.email.send.me.a.copy=Send me a copy #======= End labels: Exported 439 labels for en AU ===== Index: lams_central/conf/language/lams/ApplicationResources_en_AU.properties =================================================================== diff -u -rd36e6ae1ccdcaa702333d0dc2888aa4dfee4a078 -r4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1 --- lams_central/conf/language/lams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision d36e6ae1ccdcaa702333d0dc2888aa4dfee4a078) +++ lams_central/conf/language/lams/ApplicationResources_en_AU.properties (.../ApplicationResources_en_AU.properties) (revision 4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1) @@ -698,6 +698,6 @@ label.password.must.ucase =at least 1 upper case letter label.password.must.number=at least 1 number label.password.must.symbol =at least 1 symbol +label.email.send.me.a.copy=Send me a copy - #======= End labels: Exported 439 labels for en AU ===== Index: lams_central/web/emailuser.jsp =================================================================== diff -u -ra13219605786fc66583d551d74725e9752c3bcd9 -r4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1 --- lams_central/web/emailuser.jsp (.../emailuser.jsp) (revision a13219605786fc66583d551d74725e9752c3bcd9) +++ lams_central/web/emailuser.jsp (.../emailuser.jsp) (revision 4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1) @@ -57,12 +57,13 @@ function closeDialog() { if (returnUrl == '') { - // if this page is in dialog, close it - if (parent.closeEmailDialog) { - parent.closeEmailDialog(); + if (window.parent.closeEmailDialog) { + window.parent.closeEmailDialog(); + } else if (closeEmailDialog) { + closeEmailDialog(); } else { // if this is a pop up, close it - window.close(); + close(); } } else { // if it is a main page, navigate away @@ -113,31 +114,25 @@ -
- + - <> - -
+ <> + + - -
+ id="cc-email-enabled" />
- + -    - - +   
@@ -148,7 +143,7 @@
-
Index: lams_central/web/includes/javascript/dialog.js =================================================================== diff -u -r59af1a95dadad5e868b288037f77bf262fdb1954 -r4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1 --- lams_central/web/includes/javascript/dialog.js (.../dialog.js) (revision 59af1a95dadad5e868b288037f77bf262fdb1954) +++ lams_central/web/includes/javascript/dialog.js (.../dialog.js) (revision 4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1) @@ -26,6 +26,7 @@ * If not, creates a new dialog with the given ID and init parameters. */ function showDialog(id, initParams, extraButtons, recreate) { + var dialog = $('#' + id); // is it open already? if (dialog.length > 0) { Index: lams_central/web/includes/javascript/main.js =================================================================== diff -u -r353fe07604639c2166ed68fbf832810959f3f3cf -r4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1 --- lams_central/web/includes/javascript/main.js (.../main.js) (revision 353fe07604639c2166ed68fbf832810959f3f3cf) +++ lams_central/web/includes/javascript/main.js (.../main.js) (revision 4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1) @@ -327,6 +327,7 @@ function showMonitorLessonDialog(lessonID) { + var id = "dialogMonitorLesson" + lessonID, dialog = showDialog(id, { 'data' : { @@ -343,7 +344,7 @@ + $(this).data('lessonID')); }, - }, true); + }, true, true); // if it was just created if (dialog) { @@ -373,7 +374,7 @@ 'data' : { 'orgID' : orgID }, - 'modal' : true, + 'modal' : false, 'height' : 740, 'width' : 'auto', 'title' : LABELS.ADD_LESSON_TITLE, @@ -427,7 +428,7 @@ 'toolID' : toolID, 'learningLibraryID' : learningLibraryID }, - 'modal' : true, + 'modal' : false, 'height' : 600, 'width' : 'auto', 'title' : LABELS.SINGLE_ACTIVITY_LESSON_TITLE, @@ -474,6 +475,7 @@ }, 'height' : 650, 'width' : 'auto', + 'modal' : false, 'title' : LABELS.EMAIL_NOTIFICATIONS_TITLE, 'open' : function() { var dialog = $(this), @@ -621,13 +623,14 @@ 'orgID' : orgID, 'height' : 650, 'width' : 'auto', + 'modal' : false, 'title' : LABELS.GRADEBOOK_COURSE_TITLE, 'open' : function() { var orgID = $(this).dialog('option', 'orgID'); // load contents after opening the dialog $('iframe', this).attr('src', LAMS_URL + 'gradebook/gradebookMonitoring.do?dispatch=courseMonitor&organisationID=' + orgID); - $(this).css("maxWidth", "850").css("margin", "auto"); + $(this).css("maxWidth", "800px").css("margin", "auto"); } }, true); } @@ -640,12 +643,13 @@ }, 'height' : 650, 'width' : 'auto', + 'modal' : false, 'title' : LABELS.GRADEBOOK_LESSON_TITLE, 'open' : function() { var lessonID = $(this).data('lessonID'); // load contents after opening the dialog $('iframe', this).attr('src', LAMS_URL + 'gradebook/gradebookMonitoring.do?lessonID=' + lessonID); - $(this).css("maxWidth", "850").css("margin", "auto"); + $(this).css("maxWidth", "800px").css("margin", "auto"); } }, true); } @@ -660,13 +664,14 @@ }, 'height' : 400, 'width' : 'auto', + 'modal' : false, 'title' : LABELS.GRADEBOOK_LEARNER_TITLE, 'open' : function() { var orgID = $(this).data('orgID'); // load contents after opening the dialog $('iframe', this).attr('src', LAMS_URL + 'gradebook/gradebookLearning.do?dispatch=courseLearner&organisationID=' + orgID); - $(this).css("maxWidth", "750").css("margin", "auto"); + $(this).css("maxWidth", "750px").css("margin", "auto"); } }, true); } @@ -679,6 +684,7 @@ }, 'height' : 750, 'width' : 'auto', + 'modal' : false, 'title' : LABELS.CONDITIONS_TITLE, 'open' : function() { var lessonID = $(this).data('lessonID'); @@ -698,6 +704,7 @@ }, 'height' : 400, 'width' : 'auto', + 'modal' : false, 'title' : LABELS.SEARCH_LESSON_TITLE, 'open' : function() { var orgID = $(this).data('orgID'); @@ -821,4 +828,35 @@ }); } } -} \ No newline at end of file +} + + +function showEmailDialog(userId, lessonId){ + + var dialog = showDialog("dialogEmail", { + 'autoOpen' : true, + 'height' : 700, + 'width' : 700, + 'modal' : true, + 'resizable' : true, + 'title' : LABELS.EMAIL_TITLE, + 'open' : function(){ + autoRefreshBlocked = true; + var dialog = $(this); + // load contents after opening the dialog + $('iframe', dialog).attr('src', + LAMS_URL + 'emailUser.do?method=composeMail&lessonID=' + lessonId + + '&userID=' + userId); + }, + 'close' : function(){ + autoRefreshBlocked = false; + $(this).remove(); + } + }, false, true); +} + + +function closeEmailDialog(){ + $('#dialogEmail').modal('hide'); +} + Index: lams_central/web/main.jsp =================================================================== diff -u -r353fe07604639c2166ed68fbf832810959f3f3cf -r4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1 --- lams_central/web/main.jsp (.../main.jsp) (revision 353fe07604639c2166ed68fbf832810959f3f3cf) +++ lams_central/web/main.jsp (.../main.jsp) (revision 4a2a1ea3d6d2248d1c4146e6a48e71259c64cee1) @@ -85,6 +85,8 @@ MY_PROFILE : '', REMOVE_ORG_FAVORITE : '', MARK_ORG_FAVORITE : '', + EMAIL_TITLE : '', + }, stateId = 1, // TODO Figure out when stateId is required to be equal 3. Old version code: stateId = tabName == 'profile' ? 3 : 1; activeOrgId = null${lastVisitedOrganisationId};