MGCLatticeSalesInvoiceDocumentAttachmentEntity
The MGCLatticeSalesInvoiceDocumentAttachmentEntity exposes document attachments linked to sales invoice journal records (CustInvoiceJour), including file metadata and content. Uses DocuRefEntity as the root data source following the standard D365 attachment entity pattern.
- Public collection name:
LatticeSalesInvoiceDocumentAttachments
- Primary key:
DocumentId
Fields
| Name | Type | Mandatory | Description |
|---|
DocumentId | DocuDocumentId | No | |
ActualCompanyId | `` | No | |
DocumentAttachmentTypeCode | DocuTypeId | No | |
AttachmentDescription | Description | No | |
Notes | Notes | No | |
AccessRestriction | DocuRestriction | No | |
Attachment | BitMap | No | |
FileName | Filename | No | |
FileType | FilenameType | No | |
IsDefaultAttachment | DocuDefaultAttachment | No | |
SalesOrderNumber | SalesIdBase | No | |
InvoiceId | CustInvoiceId | No | |
InvoiceDate | TransDate | No | |
CustomerAccount | CustAccount | No | |
InvoiceAccount | CustInvoiceAccount | No | |
ExternalSystem | MGCLatticeExternalSystemId | No | The external system, such as a CRM, a marketplace or a legacy ERP, whose key this is. |
SalesOrderNumberExternalKey | MGCLatticeExternalKey | No | The external system's key for the sales order. Send it instead of the sales order number. |
Mappings
| Entity field | Data source | Field |
|---|
DocumentId | DocuRefEntity | DocumentId |
ActualCompanyId | DocuRefEntity | ActualCompanyId |
DocumentAttachmentTypeCode | DocuRefEntity | TypeId |
AttachmentDescription | DocuRefEntity | Name |
Notes | DocuRefEntity | Notes |
AccessRestriction | DocuRefEntity | Restriction |
Attachment | DocuRefEntity | FileContents |
FileName | DocuRefEntity | FileName |
FileType | DocuRefEntity | FileType |
IsDefaultAttachment | DocuRefEntity | DefaultAttachment |
SalesOrderNumber | CustInvoiceJour | SalesId |
InvoiceId | CustInvoiceJour | InvoiceId |
InvoiceDate | CustInvoiceJour | InvoiceDate |
CustomerAccount | CustInvoiceJour | OrderAccount |
InvoiceAccount | CustInvoiceJour | InvoiceAccount |