scmc.ReceiptsServiceglobal with sharing class ReceiptsService this service is used to support actions that are performed on a receipt. Methodscreateglobal static List<Id> create(List<scmc.ReceiptDTO> receiptDTOList) Generic service to perform receipts. The type of receipts is driven by the DTO used as parameter.
Input Parameters
Return ValueThe id list of receipts created. 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. SCMC.ReceiptDTO.CretDTO serializedCretDTO = new SCMC.ReceiptDTO.CretDTO(); serializedCretDTO.CustomerReturnLineId = 'a1f170000015QQgAAM'; serializedCretDTO.QuantityToReceive = 1; serializedCretDTO.SerialNumberList = new List<String> {'SN1'}; SCMC.ReceiptDTO.CretDTO nonSerializedCretDTO = new SCMC.ReceiptDTO.CretDTO(); nonSerializedCretDTO.CustomerReturnLineId = 'a1f170000015QQfAAM'; nonSerializedCretDTO.QuantityToReceive = 1; List<SCMC.ReceiptDTO.CretDTO> cretDTOList = new List<SCMC.ReceiptDTO.CretDTO> { serializedCretDTO, nonSerializedCretDTO }; SCMC.ReceiptsService.create(cretDTOList); |