Salesforce Certified Platform Developer II — Question 280
When the sales team views an individual customer record, they need to see recent interactions for the customer. These interactions can be sales, orders, phone calls, or Cases. The date range for recent interactions will be different for every customer record type.
How can this be accomplished?
Answer options
- A. Use a Lightning component to query and display interactions based on record type that is passed in using a design:attribute from the Lightning page.
- B. Use a dynamic form on the customer record page to display recent interactions.
- C. Use batch Apex to query for the most recent interactions when the customer view screen is loaded.
- D. Use Lightning Flow to read the customer's record type, and then do a dynamic query for recent interactions and display on the View page.
Correct answer: A
Explanation
The correct answer is A because using a Lightning component allows for dynamic querying based on the record type, which meets the requirement of different date ranges for each type. Options B and C are not suitable since they either don't provide the necessary dynamic capabilities or are not efficient for real-time data display. Option D, while feasible, is more complex than needed for this specific requirement.