evaluateLearningItem
Use this wire adapter to check whether the criteria for completing a custom exercise in an Enablement program are satisfied.
Parameter Name | Type | Description | Required? |
---|---|---|---|
learningItemId | String | The ID of the LearningItem record to evaluate. | |
details | Object | An optional Map<String, Object> that includes any additional information required for evaluating the learning item. The LearningItemType record that represents the custom exercise defines this criteria. |
- A Promise object that resolves when the custom exercise's corresponding LearningItemProgress response is returned. The response includes:
id
—The ID of the LearningItemProgress record.learningItemId
—The ID of the LearningItem record that was evaluated.completedPercent
—Percentage of the learning item that’s complete.completedDate
—The date when the user completed the learning item.isCompleted
—Whether the learning item is complete. The default value is false.
error
—A validation error for invalid fields.
This example passes only the required learningItemId
.
This example evaluates a user's progress through a custom exercise that uses a screen flow. The optional details
parameter includes information about the user's current screen and the screens that the user has navigated already.
See Also
- Object Reference for the Salesforce Platform: LearningItem
- Object Reference for the Salesforce Platform: LearningItemProgress