SAP Knowledge Base Article - Public

2531287 - Learning Plan search API not returning scheduleID

Symptom

The Learning Plan search API used to get the Class ID, is returning the field "scheduleID": null.

Environment

SAP SuccessFactors Learning

Reproducing the Issue

1.Generate a token of user type >

2.Call the learning plan API, for example:

URL : https://customer.plateau.com/learning/odatav4/learningPlan/v1/UserTodoLearningItems?$filter=criteria/maxRowNum eq 20

3.Sample response (after the 1702 system version)

Response : (For Item : Vish-Course-Completion-SO-Title)

{

"@odata.context": "$metadata#UserTodoLearningItems",

"value": [

 

{

"sku": "SKU-165001",

"cpnt_classification": "TIME-BASED",

"isUserRequestsEnabled": true,

"title": "Vish-Course-Completion-SO-Title",

"description": "Vish-Course-Completion-SO-Desc",

"status": "Y,E,N,N,897275001,-7,-1,-1,N,N,N,N,N,Y,N,N,Y",

"userID": "PD-001",

"componentTypeID": "Vish-Course",

"componentTypeDesc": "Vish-Course",

"componentID": "Vish-Course-Completion-SO",

"componentKey": 159001,

"componentLength": 8,

"contactHours": null,

"creditHours": null,

"cpeHours": null,

"revisionDate": 1472470500000,

"assignedDate": 1456894800000,

"availableNewRevision": false,

"revisionNumber": "1",

"requiredDate": 1458100799000,

"daysRemaining": -342,

"addUser": "A",

"addUserName": "PAYEL,Dey ,, ",

"addUserTypeLabelID": "Admin",

"orderItemID": null,

"usedOrderTicketNumber": null,

"usedOrderTicketSequence": null,

"onlineLaunched": false,

"origin": "Directly Assigned",

"cdpGoalID": null,

"seqNumber": 209001,

"scheduleID": null,

"qualificationID": null,

"rootQualificationID": null,

"qualTitle": null,

"isRequired": true,

"orderItemStatusTypeID": null,

"showInCatalog": true,

"requirementTypeDescription": "REQ",

"requirementTypeId": "REQ",

"hasOnlinePart": false,

"itemDetailsDeeplink": null,

"courseDeeplink": null,

"criteria": null,

"linkedSchedules": [],

"programType": null,

"programEndDate": null,

"programStartDate": null,

"programDuration": null,

"programDurationType": null,

"programDeeplink": null,

"vlsLink": null,

"studentSurveyID": null,

"itemSurveyID": null,

"surveyID": null,

"surveyLevel": null,

"surveydesc": null,

"surveyStatusID": null,

"surveyDeepLink": null

}

,

 

{

"sku": "SKU-897213001",

"cpnt_classification": "BLENDED",

"isUserRequestsEnabled": true,

"title": "CM_TEST",

"description": "CM_TEST",

"status": "Y,N,N,N,-1,-1,-1,-1,N,N,N,N,N,Y,N,N,Y",

"userID": "PD-001",

"componentTypeID": "Ashok_Honeywell_ILT ",

"componentTypeDesc": "Ashok_Honeywell_ILT ",

"componentID": "897CM1",

"componentKey": 897202001,

"componentLength": null,

"contactHours": null,

"creditHours": null,

"cpeHours": null,

"revisionDate": 1474309085000,

"assignedDate": 1476849600000,

"availableNewRevision": false,

"revisionNumber": "1",

"requiredDate": 1478667599000,

"daysRemaining": -104,

"addUser": "A",

"addUserName": "System AP,, ",

"addUserTypeLabelID": "Admin",

"orderItemID": null,

"usedOrderTicketNumber": null,

"usedOrderTicketSequence": null,

"onlineLaunched": false,

"origin": "System AP",

"cdpGoalID": null,

"seqNumber": 897305002,

"scheduleID": null,

"qualificationID": null,

"rootQualificationID": null,

"qualTitle": null,

"isRequired": true,

"orderItemStatusTypeID": null,

"showInCatalog": true,

"requirementTypeDescription": "REQ",

"requirementTypeId": "REQ",

"hasOnlinePart": true,

"itemDetailsDeeplink": null,

"courseDeeplink": null,

"criteria": null,

"linkedSchedules": [],

"programType": null,

"programEndDate": null,

"programStartDate": null,

"programDuration": null,

"programDurationType": null,

"programDeeplink": null,

"vlsLink": null,

"studentSurveyID": null,

"itemSurveyID": null,

"surveyID": null,

"surveyLevel": null,

"surveydesc": null,

"surveyStatusID": null,

"surveyDeepLink": null

}

,

 

{

"sku": "SKU-897218001",

"cpnt_classification": "BLENDED",

"isUserRequestsEnabled": true,

"title": "Testing SSB_Item for fac and loc",

"description": "Testing SSB_Item for fac and loc",

"status": "Y,N,N,N,-1,-1,-1,-1,N,N,N,N,N,Y,N,N,Y",

"userID": "PD-001",

"componentTypeID": "BLENDED",

"componentTypeDesc": "BLENDED",

"componentID": "SSB_Item",

"componentKey": 225001,

"componentLength": 8,

"contactHours": null,

"creditHours": null,

"cpeHours": null,

"revisionDate": 1475530380000,

"assignedDate": 1475640000000,

"availableNewRevision": false,

"revisionNumber": "2",

"requiredDate": null,

"daysRemaining": null,

"addUser": "A",

"addUserName": "yparimi,Yashwanth, Parimi ,, ",

"addUserTypeLabelID": "Admin",

"orderItemID": null,

"usedOrderTicketNumber": null,

"usedOrderTicketSequence": null,

"onlineLaunched": false,

"origin": "Directly Assigned",

"cdpGoalID": null,

"seqNumber": 269422,

"scheduleID": null,

"qualificationID": null,

"rootQualificationID": null,

"qualTitle": null,

"isRequired": null,

"orderItemStatusTypeID": null,

"showInCatalog": true,

"requirementTypeDescription": null,

"requirementTypeId": null,

"hasOnlinePart": true,

"itemDetailsDeeplink": null,

"courseDeeplink": null,

"criteria": null,

"linkedSchedules": [],

"programType": null,

"programEndDate": null,

"programStartDate": null,

"programDuration": null,

"programDurationType": null,

"programDeeplink": null,

"vlsLink": null,

"studentSurveyID": null,

"itemSurveyID": null,

"surveyID": null,

"surveyLevel": null,

"surveydesc": null,

"surveyStatusID": null,

"surveyDeepLink": null

}

],

}

Resolution

When the user is assigned an Item and registers to the class (by admin or user directly), there will be two records and Learning plan search API picks up one of the records based on the required date (minimum of the all required dates corresponding to that item and class). In this case the response with null Schedule ID corresponds to Item and this is an expected behavior.

Also if the user needs the details of enrolled scheduled offerings for a particular item, use the below mentioned API that returns the response with status and enrollment seat id.
http://<learning-server>/learning/odatav4/public/user/learningPlan/v1/LearningItemDetails('<Item-Name>')/scheduledofferings

Below are the API behavior with various scenarios tested:

1.User is registered in the class by admin, the schedule ID is returned by the API correctly.

2.User self-registers in the class, the schedule ID is returned by the API correctly.

3.User is assigned the item by admin, then enrolled in the class by admin. The scheduleID is NOT returned by the API.

4.User self assigns item, then self registers in the class. The scheduleID is NOT returned by the API.

Keywords

ODATA, API, Learning plan search, SO, scheduleID, Offerings Schedule offering, odatav4/public/user/learningplan-service/v1/UserTodoLearningItems, UserTodoLearningItems, class , KBA , LOD-SF-LMS-ODA , Web Services OData , LOD-SF-LMS , Learning Management System , Problem

Product

SAP SuccessFactors Learning all versions