Index: lams_bb_integration/web/modules/learnermonitor.jsp =================================================================== diff -u -refced1f751a9f688a5f99a75cf6592120260428e -r780957f27df870898ade718ccdacd93d5dfadbd7 --- lams_bb_integration/web/modules/learnermonitor.jsp (.../learnermonitor.jsp) (revision efced1f751a9f688a5f99a75cf6592120260428e) +++ lams_bb_integration/web/modules/learnermonitor.jsp (.../learnermonitor.jsp) (revision 780957f27df870898ade718ccdacd93d5dfadbd7) @@ -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());