serlm.SyncEstimateAndQuoteServiceglobal with sharing class SyncEstimateAndQuoteService A service that provides functionality related to adding details from estimates to their related quotes. MethodssyncEstimateAndQuoteglobal static List<serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteResponse> syncEstimateAndQuote(List<serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteRequest> requests) A method that adds estimate details to their related quotes. Input Parameters
Return ValueThis service returns SyncEstimateAndQuoteResponse in a list that parallels the input list. Sample Code//Note: This sample code is for demonstration purposes only. It is not intended for //use in a production environment, is not guaranteed against defects or errors, and //is in no way optimized or streamlined. // The ID of the primary estimate that contains the details you want to add to the related quote. Id estimateId = 'a6MDK000000L2fJ2AS'; // Construct the request serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteRequest request = new serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteRequest(estimateId); List<serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteResponse> responses = serlm.SyncEstimateAndQuoteService.syncEstimateAndQuote( new List<serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteRequest>{ request } ); // Extract the response data System.debug('The estimate ID: ' + responses[0].EstimateId); // Extract errors System.debug('Number of errors: ' + responses[0].Errors.size()); if (!responses[0].Errors.isEmpty()) { System.debug('Error message: ' + responses[0].Errors[0].Message); } serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteRequestglobal with sharing class SyncEstimateAndQuoteRequest The request structure for adding an estimate to its related quote. Sample Code//Note: This sample code is for demonstration purposes only. It is not intended for //use in a production environment, is not guaranteed against defects or errors, and //is in no way optimized or streamlined. // The ID of the primary estimate that contains the details you want to add to the related quote. Id estimateId = 'a6MDK000000L2fJ2AS'; // Construct the request serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteRequest request = new serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteRequest(estimateId); Properties
MethodsSyncEstimateAndQuoteRequestglobal SyncEstimateAndQuoteRequest(Id estimateId) A default constructor with minimum required properties. Input Parameters
serlm.SyncEstimateAndQuoteService.SyncEstimateAndQuoteResponseglobal with sharing class SyncEstimateAndQuoteResponse The response structure for adding an estimate to its related quote. Properties
|