Index: lams_central/src/java/org/lamsfoundation/lams/webservice/xml/LessonManagerServlet.java =================================================================== diff -u -r30e0cf0cbcdb4a92a40c6c13f090d3ce2d96475c -r8ffbcd21eb6459cfab69d057e60af1e33fb7e004 --- lams_central/src/java/org/lamsfoundation/lams/webservice/xml/LessonManagerServlet.java (.../LessonManagerServlet.java) (revision 30e0cf0cbcdb4a92a40c6c13f090d3ce2d96475c) +++ lams_central/src/java/org/lamsfoundation/lams/webservice/xml/LessonManagerServlet.java (.../LessonManagerServlet.java) (revision 8ffbcd21eb6459cfab69d057e60af1e33fb7e004) @@ -192,7 +192,7 @@ } else if (method.equals(CentralConstants.METHOD_CLONE)) { lsId = new Long(lsIdStr); - Long lessonId = cloneLesson(serverId, datetime, hashValue, username, lsId, courseId); + Long lessonId = cloneLesson(serverId, datetime, hashValue, username, lsId, courseId, country, lang); element = document.createElement(CentralConstants.ELEM_LESSON); element.setAttribute(CentralConstants.ATTR_LESSON_ID, lessonId.toString()); @@ -413,23 +413,24 @@ } private Long cloneLesson(String serverId, String datetime, String hashValue, String username, long lsId, - String courseId) throws RemoteException { + String courseId, String countryIsoCode, String langIsoCode) throws RemoteException { try { ExtServerOrgMap serverMap = LessonManagerServlet.integrationService.getExtServerOrgMap(serverId); Authenticator.authenticate(serverMap, datetime, username, hashValue); + ExtUserUseridMap userMap = LessonManagerServlet.integrationService.getExtUserUseridMap(serverMap, username); + Integer creatorId = userMap.getUser().getUserId(); - ExtCourseClassMap orgMap = LessonManagerServlet.integrationService.getExtCourseClassMap(serverMap.getSid(), - courseId); + ExtCourseClassMap orgMap = LessonManagerServlet.integrationService.getExtCourseClassMap(serverMap, userMap, + courseId, countryIsoCode, langIsoCode, null, LoginRequestDispatcher.METHOD_MONITOR); if (orgMap == null) { LessonManagerServlet.log.debug("No course exists for: " + courseId + ". Can't delete any lessons."); throw new Exception("Course with courseId: " + courseId + " could not be found"); } Organisation organisation = orgMap.getOrganisation(); // clone lesson - Long newLessonId = monitoringService.cloneLesson(lsId, userMap.getUser().getUserId(), true, true, null, - null, organisation); + Long newLessonId = monitoringService.cloneLesson(lsId, creatorId, true, true, null, null, organisation); // store information which extServer has started the lesson LessonManagerServlet.integrationService.createExtServerLessonMap(newLessonId, serverMap);