Index: lams_central/conf/language/lams/ApplicationResources_en_AU.properties =================================================================== RCS file: /usr/local/cvsroot/lams_central/conf/language/lams/ApplicationResources_en_AU.properties,v diff -u -r1.111.2.35 -r1.111.2.36 --- lams_central/conf/language/lams/ApplicationResources_en_AU.properties 12 May 2017 14:28:11 -0000 1.111.2.35 +++ lams_central/conf/language/lams/ApplicationResources_en_AU.properties 15 May 2017 20:09:00 -0000 1.111.2.36 @@ -755,5 +755,7 @@ label.save.as.course.grouping =Save as a Course Grouping label.enter.course.grouping.name =Please enter name for the new course grouping label.course.groups.name.not.unique =Course grouping with such name already exists. Please enter another one. +label.save.as.course.grouping.hint =You can save the groups as "Course groupings" so it can be used in other lessons as well. If the groups are just specifically for this lesson, you might not want to do this. Otherwise, click the button to give them a name and reuse them later. +label.advanced.settings =Advanced settings #======= End labels: Exported 744 labels for en AU ===== Index: lams_central/src/java/org/lamsfoundation/lams/web/OrganisationGroupAction.java =================================================================== RCS file: /usr/local/cvsroot/lams_central/src/java/org/lamsfoundation/lams/web/OrganisationGroupAction.java,v diff -u -r1.9.2.16 -r1.9.2.17 --- lams_central/src/java/org/lamsfoundation/lams/web/OrganisationGroupAction.java 15 May 2017 18:10:50 -0000 1.9.2.16 +++ lams_central/src/java/org/lamsfoundation/lams/web/OrganisationGroupAction.java 15 May 2017 20:09:00 -0000 1.9.2.17 @@ -127,12 +127,16 @@ response.sendError(HttpServletResponse.SC_FORBIDDEN, "User is not a participant in the organisation"); return null; } - + + List orgGroupings = getUserManagementService().findByProperty(OrganisationGrouping.class, + "organisationId", organisationId); Grouping grouping = getLessonGrouping(activityID); + + // show groups page if this is a lesson mode and user have already chosen a grouping or there is no organisation + // groupings available boolean lessonGroupsExist = (grouping != null) && (grouping.getGroups() != null) && !grouping.getGroups().isEmpty() && !isDefaultChosenGrouping(grouping); - if (lessonGroupsExist) { - // this is lesson mode and user have already chosen a grouping before, so show it + if (lessonGroupsExist || (activityID!= null &&orgGroupings.isEmpty())) { return viewGroups(mapping, form, request, response); } @@ -168,8 +172,6 @@ request.setAttribute("canEdit", isGroupSuperuser || (activityID != null)); Set orgGroupingDTOs = new TreeSet(); - List orgGroupings = getUserManagementService().findByProperty(OrganisationGrouping.class, - "organisationId", organisationId); for (OrganisationGrouping orgGrouping : orgGroupings) { orgGroupingDTOs.add(new OrganisationGroupingDTO(orgGrouping)); } Index: lams_central/web/orgGroup.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_central/web/orgGroup.jsp,v diff -u -r1.4.2.12 -r1.4.2.13 --- lams_central/web/orgGroup.jsp 15 May 2017 18:10:50 -0000 1.4.2.12 +++ lams_central/web/orgGroup.jsp 15 May 2017 20:09:00 -0000 1.4.2.13 @@ -59,15 +59,6 @@ - -
- -
-
- @@ -151,6 +142,21 @@
+ + + + +
+ + +
+ +
+
+
Index: lams_central/web/css/orgGroup.css =================================================================== RCS file: /usr/local/cvsroot/lams_central/web/css/orgGroup.css,v diff -u -r1.3.2.4 -r1.3.2.5 --- lams_central/web/css/orgGroup.css 12 May 2017 14:28:11 -0000 1.3.2.4 +++ lams_central/web/css/orgGroup.css 15 May 2017 20:09:00 -0000 1.3.2.5 @@ -28,7 +28,7 @@ border-bottom: thin dotted #2E6E9E; } table#groupsTable { - height: calc(100% - 80px); + height: calc(100% - 110px); } table#groupsTable td { vertical-align: top; @@ -122,11 +122,18 @@ color: white !important; } -#save-course-grouping-container { +#course-grouping-advanced-settings { display: inline-block; width: 100%; - margin-bottom: -7px; + padding: 10px; } +#save-course-grouping-button { + margin-top: 10px; +} +#accordionAdvanced { + margin-bottom: 0px; + margin-top: 20px; +} .dialogContainer { display: none; -webkit-overflow-scrolling: touch !important; Index: lams_central/web/includes/javascript/orgGroup.js =================================================================== RCS file: /usr/local/cvsroot/lams_central/web/includes/javascript/orgGroup.js,v diff -u -r1.6.2.7 -r1.6.2.8 --- lams_central/web/includes/javascript/orgGroup.js 15 May 2017 18:10:50 -0000 1.6.2.7 +++ lams_central/web/includes/javascript/orgGroup.js 15 May 2017 20:09:00 -0000 1.6.2.8 @@ -623,5 +623,10 @@ $("#span-tooltip", saveAsCourseGroupingDialog).removeClass("alert-danger").text(LABELS.ENTER_COURSE_GROUPING_NAME_LABEL); $('#dialog-course-grouping-name', saveAsCourseGroupingDialog).removeClass("alert alert-danger"); } + + //scroll to the botom of the page on opening Advanced settings + $('#accordionAdvanced').on('shown.bs.collapse', function () { + $("html, body").animate({ scrollTop: 170 }, 1000); + }); }); \ No newline at end of file