STKVALMAJ2 processing: STKVALMAJ2
MAJ_ITH: Updating the Products-sites totals history
Use this entry point in order not to update the history of the products-sites totals (ITMMVTHIS table).
Context and operating method
Transaction
There is one transaction in progress.
Log file
No trace file is open.
Different call cases
Call upon update of stock in product shortage when the products-sites totals are being updated.
In order not to update the history of the products-sites totals, the GPE variable must be set to 1.
Attention: this entry point is the equivalent of the entry point located in the STKMAJ processing. The same behavior will probably be required in both cases.
Available variables and masks
Variable or mask |
Definition |
Section 1 of the STOWORK screen |
It contains the characteristics of the document line for which the stock is being updated, among which: - [M:STW]TRSTYP: transaction type (local menu 704) - [M:STW]VCRTYP: document type (local menu 701) |
|
Open tables
All the tables opened by the stock engine.
MAJPMP: Calculating the average cost
Use this entry point to personalize the average cost calculation.
Context and operating method
Transaction
There is one transaction in progress.
Log file
There can be an open log file (GTRACE test).
Different call cases
Systematic call on stock receipt and issue.
Available variables and masks
[M:STW] = Stock work screen
[M:SVW] = Stock valuation work screen
PIO = Flag used to identify whether triggering the average cost update is caused by a receipt (=1) or an issue (=2).
PAMTDEV(,) = Detail of the variance not-absorbed.
The first index (0..1) is used to differentiate the 1st valuation method from the 2nd.
The 2nd index set to 0 corresponds to the total variance not-absorbed. Index 1 set to GACTMAT = not absorbed by material cost group. Index GACTMAT+1 set to GACTMAT+GACTMAC = not absorbed by machine cost group. Index GACTMAT+GACTMAC+1 set to GACTMAT+GACTMAC+GACTLAB = not absorbed by labor cost group. Index GACTMAT+GACTMAC+GACTLAB+1 = not absorbed by subcontract. Index GACTMAT+GACTMAC+GACTLAB+2 = not absorbed by invoicing elements. Index GACTMAT+GACTMAC+GACTLAB+3 set to GACTMAT+GACTMAC+GACTLAB+6 = not absorbed by material then machine then labor then subcontract overhead.
Open tables
The stock total recording is on line with the [ITV] abbreviation, it will be re-written after the entry point.