Entry Points > Module Sales > Standard script TRTVENLIV 

MAJCDESDD: Load [F] SDELIVERYD in an order delivery

This entry point is used to introduce specific developments at the end of the loading of class [F] in the shipment detail and as a result just before the read of the corresponding record in order to enter the fields in this record.

It is called in the update process for a delivery TRTVENLIV.

Context and operating method

Transaction

There is one transaction in process.

Log file

There is an open log file.

Different call cases

This entry point is called from the next shipment creation processes:

·               Automatic shipment function

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

Table

Significant content

Table Title

SDELIVERY

No

(in the process of being loading)

Shipment header

SDELIVERYD

No

(in the process of being loading)

Shipment line

SORDER

Yes

Order headers

SORDERQ

Yes

Order line quantities

SORDERP

Yes

(if [F:SOH]SOHCAT<>4)

Order line prices

SORDERC

Yes

(if F:SOH]SOHCAT=4)

Product / customer orders (contract orders)

BPARTNER

Yes (BP invoice)

BP (Business Partners)

BPCUSTOMER

Yes (Bill to customer )

Customers

BPDLVCUST

Yes

Ship-to customers

BPCUSTMVT

No

Customer movements

SALESREP

No

Sales representatives

BPCARRIER

Yes

Carriers

ITMMASTER

Yes

Products

ITMSALES

Yes

Products - Sales

ITMBPC

Yes

(if the product-customer exists)

Products - Customers

ITMFACILIT

No

Products - Sites

TABMODELIV

Yes

Shipment methods

FACILITY

No

Sites

 

ALI_NEGSTO: To force the generation of the shortage

This entry point is used during the process of an order line in automatic delivery.

It is used to force the generation of a shortage when the allocated quantity in the order cannot be delivered.

Context and operating method

Transaction

There is one transaction in process.

Log file

There is an open log file.

Call context

It is called in automatic delivery for each processing of an order line.

It is located in the ALICDESDD label of the TRTVENLIV process after reading the order line and determining the quantity to be delivered.   

It is used (if negative stock is authorized) to force the generation of a shortage quantity corresponding to the difference between the quantity to be delivered and the actual quantity that can be delivered.

Available variables and masks

[F :ITM]NEGSTO      : Negative stock authorised (1=no/2=yes)

GSHTDLV                  : Shipment of quantities with shortages (1=no/2=yes).

For instance:

The quantity allocated in detail on the order line can only be partially delivered, maybe not at all (physical stock count in process, analysis request, prohibited status, expired lot or non identified stock waiting put-away).

The quantity allocated in global on the order line can only be partially delivered, maybe not at all (if there is no (or insufficient) stock that respects the issue rules for the delivery).

In this case, to force the generation of a shortage for this non shippable quantity, it is necessary to act on the WRUP value.

[L]WRUP = 1

Warning, this modification may cause shortages (stock physically not present or that cannot be delivered), and then pending movements that cannot be adjusted.

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

Table

Significant content

Table Title

SORDER

Yes

Order headers

SORDERQ

Yes

Order line quantities

SORDERP

Yes if [F :SOH]SOHCAT<>4

Order line prices

SORDERC

Yes if [F :SOH]SOHCAT=4

Product line orders

ITMMASTER

Yes

Products

ITMSALES 

Yes

Sales product

 

CALPORT: Specific/custom freight calculation

This entry point is involved in the carrier management.

It is used to make a specific/custom freight calculation. It replaces the standard calculation carried out by the search through the carrier price lists.

This entry point is located in the TRTVENLIV process.

It is called from the processes that are used in the generation of a shipment : Shipment button in the orders, automatic invoicing of shipments.

Context and operating method

Transaction

There is a transaction in process (shipment creation transaction). The GOK variable is used and tested. It is equal to 1. It can be set to 0 if the transaction should be aborted.

Log file

There is no open log file.

Different call cases - Available variables and masks

The entry point is called from:

·               The shipment button in the orders management

·               The automatic shipment function.

It is called during the shipment creation transaction. All the detail lines are created with the associated updates. It is located just before the update of the customer movements and the writing of the shipment header record.

The entry point is called at the time of the search for the carrier price list.

The following variables are used:

·               WDACDLV (local integer) is loaded with the freight invoicing element n° given by the FRENUM parameter.

·               WCRY (local char)

WCTY (local char)

WPOSCOD (local char)    :

If nothing has been entered in the shipment address window, these variables are loaded with the country code, the town and the postcode of the ship-to customer (by reading the ship-to customer address in the addresses table) if not they are loaded with the codes entered in the shipment address window.

·              WPOINT_ENTREE (local integer)    :

It is initialised to 0. If set to 1, it will prevent the standard carrier price search.

·         LAMTFRE (local decimal)        :

Calculated freight amount.

·         STAT (local integer)      :

Return status. Set to 0, it is used to load the calculated freight amount in the invoicing element grid of the shipment and its display.

The carrier price search is carried out if the FRENUM parameter corresponding to the freight invoicing element n° is not equal to 0 and if the reading of this invoicing element in the elements table has taken place (WDACDLV is loaded).

It is here that the CALPORT entry point is called.

Next the search of the standard carrier prices is carried out if WPOINT_ENTREE equals 0.

Then the calculated freight amount loading in the invoicing elements grid and the display is carried out if STAT = 0.

The CALPORT entry point must therefore:

.        Set the WPOINT_ENTREE to 1.

.        Set LAMTFRE with the calculated freight amount.

.        Set STAT to 0 for the selection of this amount to be carried out.

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

For the tables that are not used in all processes, the names of the processes that use them are given.

Table

Significant content

Table Title

SDELIVERY

No

Shipment header

SDELIVERYD

No

Shipment line

SORDER

No

Order headers

SORDERQ

No

Order line quantities

SORDERP

No

Order line prices

SORDERC

No

Product / customer orders (contract orders)

BPARTNER

Yes (BP invoice)

BP (Business Partners)

BPCUSTOMER

Yes (Bill to customer )

Customers

BPDLVCUST

No

Ship-to customers

BPCUSTMVT

No

Customer movements

SALESREP

No

Sales representatives

BPCARRIER

Yes

Carriers

ITMMASTER

No

Products

ITMSALES 

No

Products - Sales

ITMBPC

No

Products - Customers

ITMFACILIT

No

Products - Sites

TABMODELIV

Yes

Shipment methods

FACILITY

No

Sites

SFOOTINV

Yes

Invoicing elements

TABSOHTYP

No (SUBSOH)

Order type table

TABCUR

No (SUBSOH)

Currency table

ITMMVT

No (SUBSOH)

Product - Movements

SPRICLINK

No (SUBSOH)

Search sales prices (link)

PRICSTRUCT

No (SUBSOH)

Price list structure

CONTACT

No (SUBSOH)

Contact

ATEXTE

No (SUBSOH)

Dictionary messages

SQUOTED

No (SUBSOH)

Quote detail

 

RECHNUMSEQ: Calculate order sequence number

This entry point concerns the management of the contract order deliveries (can be inter-site).

During the partial delivery of a delivery request, it is used to intervene on the calculated sequence number for the new delivery request.

This is used in the case of repetitive partial shipments, in order to not be blocked after 9 shipments for a single shipment request. The standard function assigns in effect the sequence numbers by dichotomy (in order to make line insertions impossible).

This entry point is located in the TRTVENLIV process.

Context and operating method

Transaction

There is a transaction in process (shipment creation transaction). The GOK variable is used and tested. It is equal to 1. It can be set to 0 if the transaction should be aborted.

Log file

There is no open log file.

Different call cases - Available variables and masks

The entry point is called during each partial delivery for a delivery request.

[F :SOQ]SOQSEQ contains the sequence number for the shipment request that is in the process of being shipped.

[F :SOQ1]SOQSEQ contains the sequence number for the next shipment request. Its value is blank if this delivery request does not exist.

The WSEQ variable contains the sequence number assigned for the creation of the new shipment request.

So as to intervene in the sequence number for the new delivery request, it is therefore necessary to modify the value of this variable WSEQ.

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

For the tables that are not used in all processes, the names of the processes that use them are given.

Table

Significant content

Table Title

SORDERQ

Yes

Order line quantities

 

CPYSLSTXT: Load the texts in the SDELIVERY file

This entry point is used to introduce specific developments at the end of the loading of class [F] for the delivery header from the first order to be delivered and only after loading of the header and footer texts associated with this delivery.

It is as a consequence possible :

- to intervene in the texts to be associated with this delivery.

- to access the contents for the delivery header fields.

It is called in the update process for a delivery TRTVENLIV.

Context and operating method

Transaction

There is one transaction in process.

Log file

There is an open log file.

Different call cases

This entry point is called from the next shipment creation processes:

·               Automatic shipment function

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

Table

Significant content

Table Title

SDELIVERY

Yes, partially

(in the process of being loading)

Shipment header

SDELIVERYD

No

Shipment line

SORDER

Yes

Order headers

SORDERQ

Yes

Order line quantities

SORDERP

No

Order line prices

SORDERC

No

Product / customer orders (contract orders)

BPARTNER

Yes (BP invoice)

BP (Business Partners)

BPCUSTOMER

Yes (Bill to customer )

Customers

BPDLVCUST

Yes

Ship-to customers

BPCUSTMVT

No

Customer movements

SALESREP

No

Sales representatives

BPCARRIER

Yes

Carriers

ITMMASTER

Yes

Products

ITMSALES 

No

Products - Sales

ITMBPC

No

(if the product-customer exists)

Products - Customers

ITMFACILIT

No

Products - Sites

TABMODELIV

Yes

Shipment methods

FACILITY

No

Sites

 

 

 

 

ALISOQ1: Load [F] SORDERQ in modification of a delivery request

This entry point concerns the management of the contract order deliveries (can be inter-site).

The modification of a delivery request causes the original line to be closed and a new line to be created.

The entry point is used to populate specific/custom fields for this new line.   

This entry point is located in the TRTVENLIV process.

Context and operating method

Transaction

There is a transaction in process (shipment creation transaction). The GOK variable is used and tested. It is equal to 1. It can be set to 0 if the transaction should be aborted.

Log file

There is no open log file.

Different call cases - Available variables and masks

The entry point is called before writing the [F:SOQ1] class of the new line.

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

For the tables that are not used in all processes, the names of the processes that use them are given.

 Table

Significant content

Table Title

SORDERQ1

Yes

Order line quantities

 

ALISOQSDH: Load delivery detail fields in order delivery

This entry point is used to introduce specific developments at the end of the loading of the delivery detail screen from an order detail record upon order delivery creation.

It is hence used to load fields that are specific to screen SDH1 or to modify standard fields.

It is called for each line in an order picking from the delivery management and for each line upon order delivery via button delivery in the order management.

Context and operating method

Transaction

There is no transaction in progress if in order picking mode from the delivery management. There is a transaction in progress if the delivery button is used from the order management.

Log file

There is no log file.

Call context

It is called for each line in an order picking from the delivery management and for each line upon order delivery via button delivery in the order management.

It is located at the end of sub-program ALISOQSDH of process TRTVENLIV.

It is used to load fields that are specific to screen SDH1 (and to table SDELIVERYD, too) or to modify standard fields from this screen in this table.

Available variables and masks

The delivery object screens are opened and loaded with the delivery being created.

Variable NOL contains the number of the line being created in the [M:SDH1] line grid. All the fields of the line are loaded.

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

Table

Significant content

Table Title

SORDER

Yes

Order headers

SORDERQ

Yes

Order line quantities

SORDERP

Yes if [F :SOH]SOHCAT<>4

Order line prices

SORDERC

Yes if [F :SOH]SOHCAT=4

Product line orders

ITMMASTER

Yes

Products

ITMSALES 

Yes

Sales product

 

ALICDESDD: Load [F]SDD in order delivery before the price list/tax calculation

This entry point is used to introduce specific developments at the end of the loading of class [F] in the shipment detail and as a result just before the read of the corresponding record in order to enter the fields in this record.

However, conversely to entry point MAJCDESDD, this entry point is located before the price list/tax calculation.

It is called in the update process for a delivery TRTVENLIV.

Context and operating method

Transaction

There is one transaction in process.

Log file

There is an open log file.

Different call cases

This entry point is called from the next shipment creation processes:

·               Automatic shipment function

It is located before the price list and tax calculation, and so before entry point MAJCDESDD.

Open tables

In the table below, the significant content flag indicates that the content is in phase with the context (the current customer is loaded...). Traditionally, this is the case for the file that contains the header and not the file that contains the lines...

Table

Significant content

Table Title

SDELIVERY

No

(in the process of being loading)

Shipment header

SDELIVERYD

No

(in the process of being loading)

Shipment line

SORDER

Yes

Order headers

SORDERQ

Yes

Order line quantities

SORDERP

Yes

(if [F:SOH]SOHCAT<>4)

Order line prices

SORDERC

Yes

(if F:SOH]SOHCAT=4)

Product / customer orders (contract orders)

BPARTNER

Yes (BP invoice)

BP (Business Partners)

BPCUSTOMER

Yes (Bill to customer )

Customers

BPDLVCUST

Yes

Ship-to customers

BPCUSTMVT

No

Customer movements

SALESREP

No

Sales representatives

BPCARRIER

Yes

Carriers

ITMMASTER

Yes

Products

ITMSALES 

Yes

Products - Sales

ITMBPC

Yes

(if the product-customer exists)

Products - Customers

ITMFACILIT

No

Products - Sites

TABMODELIV

Yes

Shipment methods

FACILITY

No

Sites