ALISOQ: Specific/custom loading in creation/modification of delivery requests

This entry point is used, in the multi-company context, to intervene during the automatic generation of an inter-site sales delivery request from a purchase delivery request. It is used, upon completion of the loading of the fields, to take control of the SORDERQ quantity detail file and it is used as a consequence to load specific/custom fields.

It is called in the management of the purchase delivery requests upon generation (creation, modification) of a sales delivery requests from the purchase delivery request.

Context and operating method

Transaction

There is one transaction in progress. The GOK variable is used and tested. It is equal to 1. It can be set to 0 if the transaction should be abandoned.

Log file

A log file is open.

Call context

This entry point is called from the management of an inter-company purchase delivery request if there is automatic generation of the sales delivery request. It is called in creation and modification of the purchase delivery request.

For the creation, it is called, on purchase side, in the INICRE_LIG action of the TABLEAUX processing. The INICRE_LIG action is carried out just before the creation of the purchase delivery request. (It is used, after the transclass of [M] into [F] to initialize the fields). On the sales side, it is called at the end of the loading of the [F :SOQ] record just before the write.

For the modification, it is called, on purchase side, in the VALLIG action of the TABLEAUX processing. The VALLIG action is executed just after the update of the purchase DR. (It us used to carry out additional updates). On the sales side, it is called at the end of the loading of the [F :SOQ] record just before the rewrite.

Available variables and masks

The POD object masks are on line and loaded with the purchase DR currently being processed.

The [M :SORW] mask is on line. It is a work mask that contains all the fields useful for the generation of the sale DR (along with those fields useful for the generation of the contract and product line). This screen is the one used to generate the sale DR and not the screens of the POD object.

The SORDER, SORDERC, SORDERQ tables are on line. SORDER is loaded with the contract, SORDERC, with the product line, SORDERQ, with the delivery request.

In DR creation , [M :SORW]MAJCOD="C", in DR modification, [M :SORW]MAJCOD="M".

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...

The open tables are the tables opened by the purchase order object and the sales order object.

Table

Significant content

Table Title

SORDER

Yes

Order headers

SORDERC

Yes

Order totals order A/R

SORDERQ

Yes

Order line quantities

SORDERP

No

Order line prices

BPARTNER

No

BP

BPCUSTOMER

Yes

Customers

BPDLVCUST

Yes

Ship-to customers

BPCUSTMVT

No

Customer transactions

ITMMASTER

Yes

Products

ITMSALES 

Yes

Products - Sales

ITMBPC

Yes

Products-customer

ITMFACILIT

No

Product-site

TABSOHTYP

No

Order types

FACILITY

No

Sites

TABUNAVAIL

No

Table of the unavailability periods

TABCOUAFF

No

Sequence number counters

PORDERQ

No

Purchase orders qty lines