Closed jeff-steinberg-northsight closed 3 months ago
The sample code here is 11 years old so it's hard to know the "why" -- but there is a code comment above that controller action method that says This controller is not using the pattern approach in this code sample version. See the other two controllers in this sample for an illustration of how the patterns are used
So it seems like Andy acknowledged up front that the sample code is not a good example of adopting the Apex Enterprise Patterns.
Just wondering why this class has a SOQL query in it instead of creating a selector for OpportunityLineItems? Are there certain situations where a selector class should not be used? Since the query retrieves values from PricebookEntry, seems like it could be a good example for showing how to use relationship queries in a selector class.