TRTVENISOC processing: TRTVENISOC
ALIMSKSOH: Load [M] order header in inter-company order generation
Use this entry point, in a multi-company context, in order to intervene during the automatic generation of a sales order from a purchase order. This entry point is used to take control after the fields in the order screens are loaded.
It is therefore used to load specific/custom fields in the sales order management screens and in the tables SORDER, SORDERP, SORDERQ.
It is called in the purchase order management upon generation (creation, modification) of a sales order from the purchase order.
Context and operating mode
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 is to be abandoned.
Log file
A log file is open.
Call context
This entry point is called from the management of an inter-company purchase order if there is automatic generation of the sales order. It is called when creating or modifying the purchase order (in the CREATION or MODIF object actions).
It is called after the update of the purchase order, after the sales order screens are loaded from the purchase order screens.
It is called just before the sales order is updated. This update is performed in such a way as to be as close as possible of the interactive update. It executes all the actions called by the sales order object. The entry point is located just before the call to the actions VERIF_CRE, INICRE, CREATION or VERIF_MOD, INIMOD, MODIF for the sales order object.
Available variables and masks
The masks of the POH object are on line and loaded with the purchase order currently being processed.
The masks of the SOH object are on line. They are loaded from the purchase order and completed in such a way as to have a screen class as complete as it would be in interactive sales order management just before the update.
The variables used by GOBJET are loaded. As a result, GREP is set to "C" or "M".
NB:
This entry point can be used to update standard fields. But you need to be cautious:
. The modification of a standard field must be controlled depending on the case.
. It can lead to other processes: modification of other fields, miscellaneous calculations, etc.
. Some fields cannot be modified depending on the context.
. This modification may cause the purchase order and sales order to diverge when they should reflect each other.
It will therefore be necessary to check on a case-by-case basis if this is possible and what it will lead to.
For example, if the entry point is used to change the type of the order, it is also necessary to re-load the GCPT (sequence number counter code) and GMANCOU (manual sequence number counter flag) global variables.
Open tables
In the table below, the significant content flag indicates that the content matches the context (the current customer is loaded…). It is usually the case for the file that contains the header but not for the file that contain 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 |
No |
Order headers |
SORDERQ |
No |
Order line quantities |
SORDERP |
No |
Order line prices |
BPARTNER |
No |
BP |
BPCUSTOMER |
No |
Customers |
BPDLVCUST |
No |
Ship-to customers |
ITMMASTER |
No |
Products |
ITMSALES |
No |
Products-sales |
ITMBPC |
No |
Products-customer |
ITMFACILIT |
No |
Product-site |
TABSOHTYP |
No |
Order types |
FACILITY |
No |
Sites |
TABCUR |
No |
Currency table |
SPRICLINK |
No |
Sales price list search (link) |
PRICSTRUCT |
No |
Price list structure |
SALESREP |
No |
Sales reps |
ITMBPS |
No |
Product-supplier |
TABCOUAFF |
No |
Sequence number table |
SPRICLIST |
No |
Customer price lists |
ALIMSKSOH4: Load [M] order detail in inter-company order generation
Use this entry point, in a multi-company context, in order to intervene during the automatic generation of a sales order from a purchase order. It is used to take control when the fields of the order detail screen are loaded, after a line is loaded.
It can be therefore be used to load specific/custom fields in the detail screens in the sales order management and in the SORDERP and SORDERQ tables.
It is called in the purchase order management upon generation (creation, modification) of a sales order from the purchase order.
Context and operating mode
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 is to be abandoned.
Log file
A log file is open.
Call context
This entry point is called from the management of an inter-company purchase order if there is automatic generation of the sales order. It is called when creating or modifying the purchase order (in the CREATION or MODIF object actions).
It is called after the update of the purchase order when the sales order screens are loaded from the purchase order screens.
It is called before the sales order is updated. This update is performed in such a way as to be as close as possible of the interactive update. It executes all the actions called by the sales order object. The entry point is located before the call to the actions VERIF_CRE, INICRE, CREATION or VERIF_MOD, INIMOD, MODIF for the sales order object.
More precisely, it is called after the header screens are loaded ([M :SOH0], [M :SOH1], [M :SOH2, [M :SOH3]) during the loading of the lines' screen ([M :SOH4]). It is set in the line processing loop, at the end of the loading of each order detail line.
Available variables and masks
The masks of the POH object are on line and loaded with the purchase order currently being processed.
The masks of the SOH object are on line. The header masks are loaded from the purchase order and then completed. They are completely populated.
The order detail mask is being loaded. The line currently being processed is populated.
Nolign is populated. Nolign-1 corresponds to the index for the line that is currently being processed in [M :SOH4].
NOLPOH is populated. NOLPOH-1 corresponds to the index for the line that is currently being processed in [M :POH2].
The variables used by GOBJET are loaded. As a result, GREP is set to "C" or "M".
NB:
This entry point can be used to update standard fields. But you need to be cautious:
tab. The modification of a standard field must be controlled depending on the case.
tab. It can lead to other processes: modification of other fields, miscellaneous calculations, etc.
tab. Some fields cannot be modified depending on the context.
tab. This modification may cause the purchase order and sales order to diverge when they should reflect each other.
It will therefore be necessary to check on a case-by-case basis if this is possible and what it will lead to.
For example, if the entry point is used to change the gross price of an order line, it is also necessary to recalculate the net price, the margin, the amounts for the line, as well as recalculate the amounts of the order.
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…). It is usually the case for the file that contains the header but not for the file that contain the lines…
The open tables are the tables opened by the order OBJect.
Table |
Significant content |
Table title |
SORDER |
No |
Order headers |
SORDERQ |
No |
Order line quantities |
SORDERP |
No |
Order line prices |
SQUOTE |
Yes |
Quote header |
SQUOTED |
Yes |
Quote detail |
BPARTNER |
No |
BP |
BPCUSTOMER |
Yes |
Customers |
BPDLVCUST |
No |
Ship-to customers |
BPCUSTMVT |
No |
Customer transactions |
ITMMASTER |
Yes |
Products |
ITMSALES |
Yes |
Products-sales |
ITMBPC |
Yes |
Products-customer |
ITMMVT |
No |
Product movements |
ITMFACILIT |
Yes |
Product-site |
TABSOHTYP |
No |
Order types |
FACILITY |
No |
Sites |
TABCUR |
No |
Currency table |
SPRICLINK |
No |
Sales price list search (link) |
PRICSTRUCT |
No |
Price list structure |
SALESREP |
No |
Sales reps |
ALIENTPOH: Load [M] order header in inter-company order generation
Use this entry point, in a multi-company context, in order to intervene during the automatic generation of a sales order from a purchase order. It is used to take control of the fields in the sales order header once they are loaded from the fields of the purchase order header.
It is called in the purchase order management upon generation (creation, modification) of a sales order from the purchase order.
Context and operating mode
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 is to be abandoned.
Log file
A log file is open.
Call context
This entry point is called from the management of an inter-company purchase order if there is automatic generation of the sales order. It is called when creating or modifying the purchase order (in the CREATION or MODIF object actions).
It is called after update of the purchase order, when the fields of the sales order are being loaded.
More precisely, it is called during the loading of the ([M:SOH0], [M:SOH1], [M:SOH2], [M:SOH3]) order header screens, after the fields are loaded from the purchase order fields, and before the fields coming from the customers and miscellaneous fields are loaded. The ([M:SOH4]) order detail screen is not loaded yet.
This entry point can be used, for example, to modify the type of order defined by the inter-company setup, by modifying the [M:SOH0]SOHTYP field.
Available variables and masks
The masks of the POH object are on line and loaded with the purchase order currently being processed.
The masks of the SOH object are on line. They are loaded from the purchase order and completed in such a way as to have a screen class as complete as it would be in interactive sales order management just before the update.
The variables used by GOBJET are loaded. As a result, GREP is set to "C" or "M".
NB:
This entry point can be used to update standard fields. But you need to be cautious:
. The modification of a standard field must be controlled depending on the case.
tab. It can lead to other processes: modification of other fields, miscellaneous calculations, etc.
. Some fields cannot be modified depending on the context.
. This modification may cause the purchase order and sales order to diverge when they should reflect each other.
It will therefore be necessary to check on a case-by-case basis if this is possible and what it will lead to.
For example, if the entry point is used to change the type of the order, it is also necessary to re-load the GCPT (sequence number counter code) and GMANCOU (manual sequence number counter flag) global variables.
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…). It is usually the case for the file that contains the header but not for the file that contain 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 |
No |
Order headers |
SORDERQ |
No |
Order line quantities |
SORDERP |
No |
Order line prices |
BPARTNER |
No |
BP |
BPCUSTOMER |
No |
Customers |
BPDLVCUST |
No |
Ship-to customers |
ITMMASTER |
No |
Products |
ITMSALES |
No |
Products-sales |
ITMBPC |
No |
Products-customer |
ITMFACILIT |
No |
Product-site |
TABSOHTYP |
No |
Order types |
FACILITY |
No |
Sites |
TABCUR |
No |
Currency table |
SPRICLINK |
No |
Sales price list search (link) |
PRICSTRUCT |
No |
Price list structure |
SALESREP |
No |
Sales reps |
ITMBPS |
No |
Product-supplier |
TABCOUAFF |
No |
Sequence number table |
SPRICLIST |
No |
Customer price lists |
BETCPYSETPRI: Price/discount line modification or price list search on sales ord
Use this entry point, in a multi-company context, in order to intervene during the automatic creation/modification of a sales order during the creation/modification of a purchase order. It is used to take control in order to modify the gross price and/or the charges/discounts for the sales order line during the automatic creation/modification of the sales order performed during the creation/modification of the purchase order.
It is called in the purchase order management when creating/modifying a sales order from the purchase order.
Context and operating mode
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 is to be abandoned.
Log file
A log file is open.
Call context
This entry point is called from the management of an inter-company purchase order if there is automatic generation of the sales order. It is called when creating/modifying the purchase order (in the CREATION or MODIF object actions). The GREP global variable gives the context of creation if its value is "C", or the context of modification if its value is "M".
It is called after creating or updating the purchase order, when the lines of the sales order are being loaded.
More specifically, it is called when the screen of the sales order line ([M:SOH4]) is loaded, after loading the fields for the delivery address, sales unit and conversion coefficient of sales unit into stock unit, from the fields of the purchase order line, and before loading the other fields of the line. The order header screen ([M:SOH0]) and the other screens containing other data ([M:SOH0],[M:SOH1],[M:SOH2]) are updated.
This entry point is used to:
- either modify the gross price and/or charges/discounts on the sales order line. In this case, the WRECH_TAR variable should be set to 3 in order to re-calculate the net price and the margin;
- or to force the price list search. In this case, the WRECH_TAR variable should be set to 2 in order to perform the price list search.
Important clarification: If the value of the WRECH_TAR variable is 2 when the entry point is called, this means that the sales unit was changed in the sales order and that it is necessary to perform a price list search. In this case, you should avoid settingthe value of the variable to 1. However, it is possible to set its value to 3 if you do not want to perform a price list search and if the gross price and/or the charges/discounts have been modified. In this case, there will only be a recalculation for the net price and the margin.
In creation mode, never set the WRECH_TAR variable to 1.
Available variables and masks
The masks of the POH object are on line and loaded with the purchase order currently being processed. The NOLPOH-1 variable contains the number of the current line of the purchase order.
The masks of the SOH object are on line. They are loaded from the purchase order and completed in such a way as to have a screen class as complete as it would be in interactive sales order management just before the update. The NLIG variable contains the number of the current line of the sales order.
The variables used by GOBJET are loaded. As a result, GREP is set to "C" or "M".
NB:
This entry point is used for the requirements mentioned above. It cannot be used to update other standard fields.
Open tables
In the table below, the significant content flag indicates that the content matches he context (the current customer is loaded…). It is usually the case for the file that contains the header but not for the file that contain 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 |
No |
Order headers |
SORDERQ |
No |
Order line quantities |
SORDERP |
No |
Order line prices |
BPARTNER |
No |
BP |
BPCUSTOMER |
No |
Customers |
BPDLVCUST |
No |
Ship-to customers |
ITMMASTER |
No |
Products |
ITMSALES |
No |
Products-sales |
ITMBPC |
No |
Products-customer |
ITMFACILIT |
No |
Product-site |
TABSOHTYP |
No |
Order types |
FACILITY |
No |
Sites |
TABCUR |
No |
Currency table |
SPRICLINK |
No |
Sales price list search (link) |
PRICSTRUCT |
No |
Price list structure |
SALESREP |
No |
Sales reps |
ITMBPS |
No |
Product-supplier |
TABCOUAFF |
No |
Sequence number table |
SPRICLIST |
No |
Customer price lists |
ALIBPAADD: Loading line delivery address
Use this entry point, in a multi-company context, in order to intervene during the automatic creation/modification of a sales order performed during the creation/modification of a purchase order. It is used to take control in order to intervene during the initialization of the delivery address of the order lines.
It is called in the purchase order management when creating/modifying a sales order from the purchase order.
Context and operating mode
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 is to be abandoned.
Log file
A log file is open.
Call context
This entry point is called from the management of an inter-company purchase order if there is automatic generation of the sales order. It is called when creating/modifying the purchase order (in the CREATION or MODIF object actions). The GREP global variable gives the context of creation if its value is "C", or the context of modification if its value is "M".
It is called after creating or updating the purchase order, when the lines of the sales order are being loaded.
More specifically, it is called when loading the screen of the sales order lines ([M:SOH4]), for each line, during the loading of the delivery address (before loading the other fields of the line). The order header screen ([M:SOH0]) and the other screens containing other data ([M:SOH0],[M:SOH1],[M:SOH2]) are updated.
This entry point is used to:
- to modify the delivery address of the line that has been loaded in a standard way with the delivery address linked to the receipt site of the purchase order line.
The delivery address of the line is stored in the WDBPAADD variable. This variable is the one that needs to be loaded in the EP.
Available variables and masks
The masks of the POH object are on line and loaded with the purchase order currently being processed. The NOLPOH-1 variable contains the number of the current line of the purchase order.
The masks of the SOH object are on line. They are loaded from the purchase order and completed in such a way as to have a screen class as complete as it would be in interactive sales order management just before the update. The NLIG variable contains the number of the current line of the sales order.
The variables used by GOBJET are loaded. As a result, GREP is set to "C" or "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…). It is usually the case for the file that contains the header but not for the file that contain 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 |
No |
Order headers |
SORDERQ |
No |
Order line quantities |
SORDERP |
No |
Order line prices |
BPARTNER |
Yes |
A/P - A/R Accounting |
BPCUSTOMER |
Yes creation No modif |
Customers |
BPDLVCUST |
Yes |
Ship-to customers |
ITMMASTER |
No creation Yes modif |
Products |
ITMSALES |
No creation Yes modif |
Products-sales |
ITMBPC |
No |
Products-customer |
ITMFACILIT |
No |
Product-site |
TABSOHTYP |
Yes creation No modif |
Order types |
FACILITY |
No |
Sites |
TABCUR |
No |
Currency table |
SPRICLINK |
No |
Sales price list search (link) |
PRICSTRUCT |
No |
Price list structure |
SALESREP |
No |
Sales reps |
ITMBPS |
No |
Product-supplier |
TABCOUAFF |
No |
Sequence number table |
SPRICLIST |
No |
Customer price lists |
COMPANY |
Yes creation No modif |
Company |
PORDER |
Yes creation No modif |
Purchase order |
MAJDEMDLVDAT: Modification of requested delivery date
Use this entry point, in a multi-company context, in order to intervene during the automatic modification of a sales order performed during the modification of a purchase order. It is used to take control during the modification of the requested delivery date in the order lines.
This entry point is called in the purchase order management when modifying a sales order from the purchase order.
Context and operating mode
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 is to be abandoned.
Log file
A log file is open.
Call context
This entry point is called from the management of an inter-company purchase order if there is automatic generation of the sales order. It is called when modifying the purchase order (in the MODIF object action). The GREP global variable gives the context of modification if its value is "M".
It is called after the purchase order is updated, when the sales order lines are loaded, more specifically during the modification of the sales order lines ([M:SOH4]) from the purchase order lines ([M:POH2]) that have been modified.
It is called during the loading of the requested delivery date from the receipt date line of the purchase order.
The entry point can be used to short-circuit this loading by setting the value of the GPE variable to 1, and to load the date systematically by modifying the [M:SOH4]DDEMDLVDAT (nolign-1) field.
Available variables and masks
The masks of the POH object are on line and loaded with the purchase order currently being processed. The NOLPOH-1 variable contains the number of the current line of the purchase order.
The masks of the SOH object are on line and loaded with the sales order. The sales order header is modified with the changes made in the purchase order header. The NLIG variable contains the number of the current line of the sales order.
The variables used by GOBJET are loaded. As a result, GREP is set to "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…). It is usually the case for the file that contains the header but not for the file that contain 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 |
No |
Order headers |
SORDERQ |
No |
Order line quantities |
SORDERP |
No |
Order line prices |
BPARTNER |
Yes |
A/P - A/R Accounting |
BPCUSTOMER |
Yes creation No modif |
Customers |
BPDLVCUST |
Yes |
Ship-to customers |
ITMMASTER |
No creation Yes modif |
Products |
ITMSALES |
No creation Yes modif |
Products-sales |
ITMBPC |
No |
Products-customer |
ITMFACILIT |
No |
Product-site |
TABSOHTYP |
Yes creation No modif |
Order types |
FACILITY |
No |
Sites |
TABCUR |
No |
Currency table |
SPRICLINK |
No |
Sales price list search (link) |
PRICSTRUCT |
No |
Price list structure |
SALESREP |
No |
Sales reps |
ITMBPS |
No |
Product-supplier |
TABCOUAFF |
No |
Sequence number table |
SPRICLIST |
No |
Customer price lists |
COMPANY |
Yes creation No modif |
Company |
PORDER |
Yes creation No modif |
Purchase order header |