Index: lams_bb_integration/web/modules/learnermonitor.jsp =================================================================== diff -u -rbf2e3def872911ffee2bfe1f8b7f1e6f8a05c90f -re27f01d34eea709e255d542039faac9c4e46ac4d --- lams_bb_integration/web/modules/learnermonitor.jsp (.../learnermonitor.jsp) (revision bf2e3def872911ffee2bfe1f8b7f1e6f8a05c90f) +++ lams_bb_integration/web/modules/learnermonitor.jsp (.../learnermonitor.jsp) (revision e27f01d34eea709e255d542039faac9c4e46ac4d) @@ -27,6 +27,8 @@ <%@ page import="blackboard.base.*"%> <%@ page import="blackboard.platform.*"%> <%@ page import="blackboard.platform.plugin.*"%> +<%@ page import="blackboard.portal.servlet.*"%> +<%@ page import="blackboard.portal.data.*"%> <%@ page import="org.lamsfoundation.ld.integration.blackboard.LamsSecurityUtil"%> <%@ page errorPage="/error.jsp"%> <%@ taglib uri="/bbNG" prefix="bbNG"%> @@ -90,20 +92,27 @@ String contentIdStr = request.getParameter("content_id"); String title = ""; String description = ""; + String strLineitemId = null; //contentId is available in versions after 1.2.3 if (contentIdStr != null) { Container bbContainer = bbPm.getContainer(); Id contentId = new PkId( bbContainer, CourseDocument.DATA_TYPE, request.getParameter("content_id") ); ContentDbLoader courseDocumentLoader = (ContentDbLoader) bbPm.getLoader( ContentDbLoader.TYPE ); Content courseDoc = (Content)courseDocumentLoader.loadById( contentId ); - title = courseDoc.getTitle(); description = courseDoc.getBody().getText(); + + //get lineitemid from the storage (bbContentId -> lineitemid) + PortalExtraInfo pei = PortalUtil.loadPortalExtraInfo(null, null, "LamsLineitemStorage"); + ExtraInfo ei = pei.getExtraInfo(); + strLineitemId = ei.getValue(contentIdStr); + } else { title = request.getParameter("title"); description = request.getParameter("description"); + strLineitemId = request.getParameter("lineitemid"); } //display learning design image @@ -119,7 +128,6 @@ //check whether user has score for this lesson Score current_score = null; - String strLineitemId = request.getParameter("lineitemid"); if (strLineitemId != null) { // there won't be "lineitemid" parameter in case lesson had been created in LAMS building block version prior to 1.2 Id lineitemId = bbPm.generateId(Lineitem.LINEITEM_DATA_TYPE, strLineitemId.trim());