Index: lams_build/lib/lams/lams-central.jar =================================================================== RCS file: /usr/local/cvsroot/lams_build/lib/lams/lams-central.jar,v diff -u -r1.63 -r1.64 Binary files differ Index: lams_central/conf/xdoclet/struts-actions.xml =================================================================== RCS file: /usr/local/cvsroot/lams_central/conf/xdoclet/struts-actions.xml,v diff -u -r1.2 -r1.3 --- lams_central/conf/xdoclet/struts-actions.xml 21 Aug 2011 07:02:53 -0000 1.2 +++ lams_central/conf/xdoclet/struts-actions.xml 1 Sep 2011 15:00:36 -0000 1.3 @@ -25,8 +25,8 @@ redirect="false" /> + \ No newline at end of file Index: lams_central/src/java/org/lamsfoundation/lams/webservice/xml/LessonManagerServlet.java =================================================================== RCS file: /usr/local/cvsroot/lams_central/src/java/org/lamsfoundation/lams/webservice/xml/LessonManagerServlet.java,v diff -u -r1.32 -r1.33 --- lams_central/src/java/org/lamsfoundation/lams/webservice/xml/LessonManagerServlet.java 21 Aug 2011 07:02:53 -0000 1.32 +++ lams_central/src/java/org/lamsfoundation/lams/webservice/xml/LessonManagerServlet.java 1 Sep 2011 15:00:36 -0000 1.33 @@ -56,6 +56,7 @@ import org.lamsfoundation.lams.usermanagement.Organisation; import org.lamsfoundation.lams.usermanagement.Role; import org.lamsfoundation.lams.usermanagement.User; +import org.lamsfoundation.lams.usermanagement.UserOrganisation; import org.lamsfoundation.lams.usermanagement.service.IUserManagementService; import org.lamsfoundation.lams.util.CentralConstants; import org.lamsfoundation.lams.util.DateUtil; @@ -165,7 +166,7 @@ if (method.equals(CentralConstants.METHOD_START)) { ldId = new Long(ldIdStr); Long lessonId = startLesson(serverId, datetime, hashValue, username, ldId, courseId, title, desc, - country, lang, customCSV); + country, lang, customCSV, isMindapp); element = document.createElement(CentralConstants.ELEM_LESSON); element.setAttribute(CentralConstants.ATTR_LESSON_ID, lessonId.toString()); @@ -296,26 +297,37 @@ } public Long startLesson(String serverId, String datetime, String hashValue, String username, long ldId, - String courseId, String title, String desc, String countryIsoCode, String langIsoCode, String customCSV) - throws RemoteException { + String courseId, String title, String desc, String countryIsoCode, String langIsoCode, String customCSV, + String isMindapp) throws RemoteException { try { - ExtServerOrgMap serverMap = LessonManagerServlet.integrationService.getExtServerOrgMap(serverId); - Authenticator.authenticate(serverMap, datetime, username, hashValue); - ExtUserUseridMap userMap = LessonManagerServlet.integrationService.getExtUserUseridMap(serverMap, username); - ExtCourseClassMap orgMap = LessonManagerServlet.integrationService.getExtCourseClassMap(serverMap, userMap, - courseId, countryIsoCode, langIsoCode, null, LoginRequestDispatcher.METHOD_MONITOR); + User user = null; + Organisation organisation = null; + ExtServerOrgMap serverMap = null; + if (isMindapp == null) { + serverMap = LessonManagerServlet.integrationService.getExtServerOrgMap(serverId); + Authenticator.authenticate(serverMap, datetime, username, hashValue); + ExtUserUseridMap userMap = LessonManagerServlet.integrationService.getExtUserUseridMap(serverMap, + username); + ExtCourseClassMap orgMap = LessonManagerServlet.integrationService.getExtCourseClassMap(serverMap, + userMap, courseId, countryIsoCode, langIsoCode, null, LoginRequestDispatcher.METHOD_MONITOR); + user = userMap.getUser(); + organisation = orgMap.getOrganisation(); + } else { + user = userManagementService.getUserByLogin("test3"); + organisation = ((UserOrganisation) user.getUserOrganisations().iterator().next()).getOrganisation(); + } // 1. init lesson Lesson lesson = LessonManagerServlet.monitoringService.initializeLesson(title, desc, Boolean.TRUE, ldId, - orgMap.getOrganisation().getOrganisationId(), userMap.getUser().getUserId(), customCSV, - Boolean.FALSE, Boolean.FALSE, Boolean.FALSE); + organisation.getOrganisationId(), user.getUserId(), customCSV, Boolean.FALSE, Boolean.FALSE, + Boolean.FALSE); // 2. create lessonClass for lesson - createLessonClass(lesson, orgMap.getOrganisation(), userMap.getUser()); + createLessonClass(lesson, organisation, user); // 3. start lesson - LessonManagerServlet.monitoringService.startLesson(lesson.getLessonId(), userMap.getUser().getUserId()); - - //store information which extServer has started the lesson - integrationService.createExtServerLessonMap(lesson.getLessonId(), serverMap); - + LessonManagerServlet.monitoringService.startLesson(lesson.getLessonId(), user.getUserId()); + if (isMindapp == null) { + // store information which extServer has started the lesson + integrationService.createExtServerLessonMap(lesson.getLessonId(), serverMap); + } return lesson.getLessonId(); } catch (Exception e) { throw new RemoteException(e.getMessage(), e); Index: lams_central/src/java/org/lamsfoundation/lams/workspace/service/IWorkspaceManagementService.java =================================================================== RCS file: /usr/local/cvsroot/lams_central/src/java/org/lamsfoundation/lams/workspace/service/IWorkspaceManagementService.java,v diff -u -r1.22 -r1.23 --- lams_central/src/java/org/lamsfoundation/lams/workspace/service/IWorkspaceManagementService.java 3 Feb 2009 05:47:41 -0000 1.22 +++ lams_central/src/java/org/lamsfoundation/lams/workspace/service/IWorkspaceManagementService.java 1 Sep 2011 15:00:36 -0000 1.23 @@ -69,7 +69,13 @@ * anything from the folder. */ public WorkspaceFolder getWorkspaceFolder(Integer workspaceFolderID); - + + /** + * Get the workspace folders for a particular name. Does not check the user permissions - that will be checked if + * you try to get anything from the folder. + */ + public List getWorkspaceFolder(String workspaceFolderName); + /** * This method returns the contents of the folder with given * workspaceFolderID depending upon the mode. Index: lams_central/src/java/org/lamsfoundation/lams/workspace/service/WorkspaceManagementService.java =================================================================== RCS file: /usr/local/cvsroot/lams_central/src/java/org/lamsfoundation/lams/workspace/service/WorkspaceManagementService.java,v diff -u -r1.56 -r1.57 --- lams_central/src/java/org/lamsfoundation/lams/workspace/service/WorkspaceManagementService.java 29 Oct 2010 15:10:04 -0000 1.56 +++ lams_central/src/java/org/lamsfoundation/lams/workspace/service/WorkspaceManagementService.java 1 Sep 2011 15:00:36 -0000 1.57 @@ -1464,7 +1464,13 @@ { return (Vector) userMgmtService.getUsersFromOrganisationByRole(organisationID, roleName, true, false); } - - - + + /** + * Get the workspace folders for a particular name. Does not check the user permissions - that will be checked if + * you try to get anything from the folder. + */ + public List getWorkspaceFolder(String workspaceFolderName) { + return (List) baseDAO.findByProperty(WorkspaceFolder.class, "name", workspaceFolderName); + } + } Index: lams_central/web/learner.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_central/web/Attic/learner.jsp,v diff -u -r1.20 -r1.21 --- lams_central/web/learner.jsp 29 Jun 2011 13:16:55 -0000 1.20 +++ lams_central/web/learner.jsp 1 Sep 2011 15:00:36 -0000 1.21 @@ -13,10 +13,10 @@ - &portfolioEnabled=&presenceEnabledPatch=&presenceImEnabled=&presenceUrl=&createDateTime=&title=&mode="> + &portfolioEnabled=&presenceEnabledPatch=&presenceImEnabled=&presenceUrl=&createDateTime=&title=&mode=¬ifyCloseURL="> - &portfolioEnabled=&presenceEnabledPatch=&presenceImEnabled=&presenceUrl=&createDateTime=&title=&mode="> + &portfolioEnabled=&presenceEnabledPatch=&presenceImEnabled=&presenceUrl=&createDateTime=&title=&mode=¬ifyCloseURL="> Index: lams_learning/web/mainflash.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_learning/web/Attic/mainflash.jsp,v diff -u -r1.6 -r1.7 --- lams_learning/web/mainflash.jsp 12 Mar 2010 16:49:32 -0000 1.6 +++ lams_learning/web/mainflash.jsp 1 Sep 2011 15:00:28 -0000 1.7 @@ -36,7 +36,9 @@ - + + +