SalesDelivery

Create a Sales Delivery document.

 

Entity Collections Properties

Type

Description

Table


Primary

DocEntry

Primary mandatory

no

GET

yes

POST

yes

 

 

SalesOrder

 

Property

Description

Table

ORDR

Primary key

DocEntry/i

$transaction

no

$branch

no

$mask

no

 

Fields

Name

Type

Description

DocEntry

Edm.Int32

DocNumber

Edm.Int32

Reference2

Edm.String(11)

TaxDate

Edm.DateTimeOffset

DocumentDate

Edm.DateTimeOffset

DocDueDate

Edm.DateTimeOffset

BPLId

Edm.DateTimeOffset

Remarks

Edm.DateTimeOffset

CardCode

Edm.String(20)

CardName

Edm.String(1)

Printed

Edm.Int32

DocumentStatus

Edm.String(1)

 

Relations

Join to Entiy Object

Relation

SalesOrderLines

DocEntry

BusinessPartner

CardCode

 

Post

 

Field

Type

Description

Address

String(255)

Address of Business Partner

Allocation

Boolean

BaseDocEntry

Number

Base DocEntry or Work order

BaseLineNumber

Number

Base Line Number (example RDR1.LineNumber)

BaseType

String

BatchGroup

boolean

CardCode

String(20)

Business Partner

CardName

String(100)

Name of Business Partner

Comments

String(255)

Long comments

DelReservation

boolean

DocDueDate

Date

Sets or returns the document due date (for example, Delivery Date in sales orders, Value Date in invoices, Valid To in quotations, and so on). Mandatory in Sales documents.

DocumentDate

Date

Document Date. Default=Today

DocumentLines

DocumentLines

DocumentPerWorkOrder

boolean

true=If you defined WoDocEntry, the system split this for every Work order

DocumentsOwner

String

Define the Document Owner

DontDelete

boolean

do not delete entries from table BEAS_PLANDOCUMENT_LINE

ExternalDocEntry

Number

GenerateQcOrder

boolean

NumAtCard

String

Define the Reference Number from Business Partner

PDocType

String

PriceType

string

PTICode

String

Reference2

String(11)

Reference 2 on document level

ReservationDocEntry


Link to Reservation BEAS_RESERVATION_LINE.RES_DOCENTRY

ResevationLineNumber


Link to Reservation BEAS_RESERVATION_LINE.RES_LINENUM

RetrievalDocument

boolean

Series

string

Define the Document Series
See Administration > System Initialization > Document Numbering

Sort

string(255)

specialLines

String

TaxDate

Date

Tax Date. Default=SAP Standard

TrackingNumber

String

Define the Tracking Number

TransportationCode

String

Define the Transportation code

WoDocEntry

Number

Linked Work order DocEntry

WoLineNumber

Number

Linked Work order Line Number

WoLineNumber2

Number

Linked Work order Bill of Material position

example: Create a SalesDelivery Document from SalesOrder

 

odata4/v1/SalesDelivery

{

"CardCode":"S001",

"DocumentLines": [
  {"ItemCode": "RM",
   "WhsCode":"01",

   "Quantity":2 
  }
  ]
}

 

Create Delivery document based on a sales order 25, Line 1
and linked to reservation DocEntry 20, Line 1, which we have to delete

{

"CardCode":"S001",

"DelReservation":true,

"RetrievalDocument":true,

"DocumentLines": [
  {"ItemCode": "RM",
   "WhsCode":"01",

   "Quantity":2 ,

   "BaseType":"17",

   "BaseDocEntry":25

   "BaseLineNumber":1

   "ReservationDocEntry":20,

   "ReservationLineNumber":1

  }
  ]
}

 

 

Create Delivery document from Sales order

 

{

"CardCode":"C23900",

"DocDate":"2019-09-28",

"DocDueDate":"2019-10-02",

"RetrievalDocument":true,   we create a document from another document

"NumAtCard":"4443212240-1",

"TrackingNumber":"3394922",

"Comments":"This are the notes \nfor the \"created\" document",

"DocumentLines": [

 {"ItemCode": "RM",

  "BaseType":"17",   17 = type sales order

  "BaseDocEntry":147, this is the docentry from sales order

  "BaseLineNumber":0,

  "WhsCode":"01",

  "Quantity":1

 }

 ]

}

 

Create Delivery from sales order and delete based reservation

{

"CardCode":"C23900",

"DocDate":"2019-09-28",

"DocDueDate":"2019-10-02",

"Reference2":"Test \"Delivery\"",

"RetrievalDocument":true, we create a document from another document

"DelReservation":true, Command for Delete Reservation

"Comments":"This are the notes \nfor the \"created\" document",

"DocumentLines": [

 {"ItemCode": "RM_B",

  "BaseType":"17",

  "BaseDocEntry":149,

  "BaseLineNumber":1,

  "WhsCode":"01",

  "Quantity":1 ,

  "DistNumber":"20190426",

  "ReservationDocEntry":45, // DocEntry and Line Number from Reservation

  "ReservationLineNumber":1  
 }

 ]

}