scmc.ReceiptsService
global with sharing class ReceiptsService
This service is used to support actions that are performed on a receipt.
Methods
create
global 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. Supported entities: - Customer Return: all the lines being received must belong to the same Customer Return.
Input Parameters
receiptDTOList |
List<scmc.ReceiptDTO> |
List holding the the DTOs used for the receipt. |
Return Value
The id list of receipts created.
Sample Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | 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);
|
|