Index: lams_central/web/css/newLesson.css =================================================================== diff -u -r9f10527fbd99d9480673e9c8c43b8ef66cdb83db -r7abac347cede2ecdc3059eb0ca5855b6679f72bd --- lams_central/web/css/newLesson.css (.../newLesson.css) (revision 9f10527fbd99d9480673e9c8c43b8ef66cdb83db) +++ lams_central/web/css/newLesson.css (.../newLesson.css) (revision 7abac347cede2ecdc3059eb0ca5855b6679f72bd) @@ -1,10 +1,10 @@ div#tabs { - width: 578px; - height: 450px; + width: 768px; + height: 574px; } div.tabContent { - height: 417px; + height: 543px; overflow: auto; } @@ -45,7 +45,7 @@ } table.tabTable { - height: 390px; + height: 517px; table-layout: fixed; border-top: thin dotted #2E6E9E; } @@ -70,13 +70,13 @@ td#learningDesignTreeCell { padding: 2px 2px 0px 5px; vertical-align: top; - width: 30%; + width: 35%; border-right: thin dotted #2E6E9E; } div#learningDesignTree { overflow: auto; - height: 384px; + height: 510px; } .ygtv-highlight1, .ygtv-highlight1 .ygtvlabel { @@ -99,15 +99,15 @@ div#canvasDiv { overflow: auto; - height: 327px; + height: 452px; } .ldChoiceDependentCanvasElement { display: none; } img#ldScreenshotLoading, div#ldNotChosenError { - padding-top: 140px; + padding-top: 200px; } td#lessonNameCell { @@ -116,7 +116,7 @@ } #lessonNameInput { - width: 250px; + width:370px; margin-left: 10px; } @@ -127,7 +127,7 @@ } td.userConainterTransferCell { - height: 69px; + height: 100px; width: 16px; padding: 18px 3px 8px 3px; vertical-align: top; @@ -147,7 +147,7 @@ } .userContainer { - height: 150px; + height: 210px; overflow: auto; border: thin solid black; padding : 5px; @@ -184,7 +184,7 @@ } input[type="checkbox"] { - margin: 5px 5px 0px 0px; + margin: 10px 5px 0px 0px; border: none; } @@ -198,33 +198,25 @@ padding: 10px 0px 10px 0px; } -table#introDescriptionTable { - padding-left: 30px; +div#introDescriptionDiv { + padding: 0px 10px 0px 30px; } +div#introDescriptionLabelDiv { + padding: 5px 0px 15px 0px; +} + textarea#introDescription { display: none; } -table#introDescriptionTable td { - padding: 0px; -} - -td#introDescriptionLabelCell { - width: 80px; -} - -.cke_resizer { - height: 10px !important; - margin-top: 0px !important; -} - #introImageField { - margin-top: 8px; + margin-top: 20px; } table#splitLearnersTable { height: 40px; + display: none; } td#splitLearnersCell { @@ -242,20 +234,26 @@ span#splitLearnersDescription { font-style: italic; - display: none; } +#schedulingEnableField { + margin-bottom: 15px; +} + #schedulingDatetimeField { margin: 0px 0px 10px 50px; + display: none; } #precedingLessonIdField { margin: 0px 0px 0px 70px; + display: none; } div#timeLimitDiv { padding: 10px 0px 0px 30px; + display: none; } #timeLimitDaysField { Index: lams_central/web/includes/javascript/newLesson.js =================================================================== diff -u -r9f10527fbd99d9480673e9c8c43b8ef66cdb83db -r7abac347cede2ecdc3059eb0ca5855b6679f72bd --- lams_central/web/includes/javascript/newLesson.js (.../newLesson.js) (revision 9f10527fbd99d9480673e9c8c43b8ef66cdb83db) +++ lams_central/web/includes/javascript/newLesson.js (.../newLesson.js) (revision 7abac347cede2ecdc3059eb0ca5855b6679f72bd) @@ -11,7 +11,7 @@ // show the thumbnail $('#ldScreenshotAuthor').css('display', 'inline'); // resize if needed - var resized = resizeImage('ldScreenshotAuthor', 383, null); + var resized = resizeImage('ldScreenshotAuthor', 477, null); toggleCanvasResize(resized ? CANVAS_RESIZE_OPTION_FIT : CANVAS_RESIZE_OPTION_NONE); }); @@ -147,41 +147,31 @@ function initAdvancedTab(){ CKEDITOR.on('instanceReady', function(e){ - // disable by default - e.editor.setReadOnly(true); + // CKEditor needs to load first, then only hide the whole div to prevent errors + $('#introDescriptionDiv').hide(); }); $('#splitLearnersCountField').spinner({ - 'disabled' : true, 'incremental' : false, 'min' : 1, 'max' : users.selectedLearners ? users.selectedLearners.length : 1, 'stop' : updateSplitLearnersFields }).spinner('value', 1); $('#splitLearnersField').change(function(){ - updateSplitLearnersFields(); + if ($(this).is(':checked')) { + $('#splitLearnersTable').show('slow'); + updateSplitLearnersFields(); + } else { + $('#splitLearnersTable').hide('slow'); + } }); $('#introEnableField').change(function(){ - var checked = $(this).is(':checked'); - $('#introImageField').prop('disabled', !checked); - - // show/hide full CKEditor - var editor = CKEDITOR.instances['introDescription']; - var collapsed = $('.cke_toolbox_collapser_min').length > 0; - if (checked) { - editor.setReadOnly(false); - if (collapsed) { - $('.cke_toolbox_collapser').trigger('click'); - } - editor.resize(420, 250); + if ($(this).is(':checked')) { + $('#introDescriptionDiv').show('slow'); } else { - editor.setReadOnly(true); - if (!collapsed) { - $('.cke_toolbox_collapser').trigger('click'); - } - editor.resize(50, 20); + $('#introDescriptionDiv').hide('slow'); } }); @@ -190,7 +180,11 @@ }); $('#schedulingEnableField').change(function(){ - $('#schedulingDatetimeField').val(null).prop('disabled', !$(this).is(':checked')); + if ($(this).is(':checked')) { + $('#schedulingDatetimeField').show('slow'); + } else { + $('#schedulingDatetimeField').hide('slow'); + } }); $('#startMonitorField').change(function(){ @@ -213,18 +207,24 @@ function initConditionsTab(){ $('#precedingLessonEnableField').change(function(){ - $('#precedingLessonIdField').prop('disabled', !$(this).is(':checked')); + if ($(this).is(':checked')) { + $('#precedingLessonIdField').show('slow'); + } else { + $('#precedingLessonIdField').hide('slow'); + } }); $('#timeLimitDaysField').spinner({ - 'disabled' : true, 'min' : 0, 'max' : 180 }).spinner('value', 30); $('#timeLimitEnableField').change(function(){ - $('#timeLimitDaysField').spinner($(this).is(':checked') ? 'enable' : 'disable'); - $('#timeLimitIndividualField').prop('disabled', !$(this).is(':checked')); + if ($(this).is(':checked')) { + $('#timeLimitDiv').show('slow'); + } else { + $('#timeLimitDiv').hide('slow'); + } }); } @@ -322,7 +322,7 @@ toggleCanvasResize(CANVAS_RESIZE_OPTION_FULL) }); toggleCanvasResizeLink.css('display', 'inline'); - resizeImage('ldScreenshotAuthor', 383, null); + resizeImage('ldScreenshotAuthor', 477, null); break; case CANVAS_RESIZE_OPTION_FULL: toggleCanvasResizeLink.html(CANVAS_RESIZE_LABEL_FIT).one('click', @@ -484,20 +484,14 @@ // ********** ADVANCED TAB FUNCTIONS ********** function updateSplitLearnersFields(){ - var splitEnabled = $('#splitLearnersField').is(':checked'); - if (splitEnabled) { - $('#splitLearnersCountField').spinner('enable'); - + if ($('#splitLearnersField').is(':checked')) { // put users into groups var maxLearnerCount = $('#selected-learners div.draggableUser').length; var learnerCount = $('#splitLearnersCountField').spinner('option', 'max', maxLearnerCount < 1 ? 1 : maxLearnerCount) .spinner('value'); var instances = Math.ceil(maxLearnerCount/learnerCount); learnerCount = Math.ceil(maxLearnerCount/instances); var description = SPLIT_LEARNERS_DESCRIPTION.replace('[0]', instances).replace('[1]', learnerCount); - $('#splitLearnersDescription').html(description).show(); - } else { - $('#splitLearnersCountField').spinner('disable'); - $('#splitLearnersDescription').hide(); + $('#splitLearnersDescription').html(description); } } \ No newline at end of file Index: lams_central/web/main.jsp =================================================================== diff -u -r4ab52d60ee545b9b76bcc65f75c5a400f6105c30 -r7abac347cede2ecdc3059eb0ca5855b6679f72bd --- lams_central/web/main.jsp (.../main.jsp) (revision 4ab52d60ee545b9b76bcc65f75c5a400f6105c30) +++ lams_central/web/main.jsp (.../main.jsp) (revision 7abac347cede2ecdc3059eb0ca5855b6679f72bd) @@ -101,8 +101,8 @@ // initialise lesson dialog var dialog = $('#addLessonDialog').dialog({ 'autoOpen' : false, - 'height' : 480, - 'width' : 610, + 'height' : 600, + 'width' : 800, 'modal' : true, 'resizable' : false, 'show' : 'fold', Index: lams_central/web/newLesson.jsp =================================================================== diff -u -r9f10527fbd99d9480673e9c8c43b8ef66cdb83db -r7abac347cede2ecdc3059eb0ca5855b6679f72bd --- lams_central/web/newLesson.jsp (.../newLesson.jsp) (revision 9f10527fbd99d9480673e9c8c43b8ef66cdb83db) +++ lams_central/web/newLesson.jsp (.../newLesson.jsp) (revision 7abac347cede2ecdc3059eb0ca5855b6679f72bd) @@ -170,26 +170,17 @@
- |
-
- |
-
- |
-