If we are going to reuse the opportunity entity to store service information, we need to customize the opportunity entity form, as we have in the following example:
Attributes
Please refer to the Appendix1 folder on the GitHub repository for this book, at https://github.com/PacktPublishing/Implementing-Microsoft-Dynamics-365-Customer-Engagement/blob/master/Appendix1.xlsx.
Views
We will be using the following views for our auto service entity:
Default view | Change to | Sorting | Filter condition |
Open Opportunities | Open Auto Services | Topic | Status Equals Active |
Closed Opportunities | Closed Auto Services | Topic | Status Equals Inactive |
Opportunity Lookup View | Auto Service Lookup View | Topic | Status Equals Active |
Opportunity Associated View | Auto Service Associated View | Topic | Status Equals Active |
Opportunity Advanced Find View | Auto Service Advanced Find View | Topic |
Status Equals Active |
All the views will have the following fields:
- Vehicle
- Topic
- Customer
- Contact
- Service Date
Relationship
Set up the following custom N:1 relationship in the auto service entity:
Primary entity | Secondary entity | Type of behavior | Relationship name | Lookup field name |
Vehicle | Auto Service | Referential | him_vehicle_opportunity_Vehicle | Vehicle |