Hi Community Members,
I am recently working on enhancement which is going to forbid quantity changes for delivery line items
if corresponding PO line item is blocked or deleted.
To do this I want to use BAdi LE_SHP_DELIVERY_PROC (Enhancements in Delivery Processing)
One of methods PUBLISH_DELIVERY_ITEM imports 2 internal tables:
IT_XLIPS Current Status of Delivery Items
IT_YLIPS Database Status: Delivery Items
Inside the method I am checking if recent quantity value (IT_XLIPS-LFIMG) is not equal to the one from database (IT_YLIPS-LFIMG). If so then I throw error.
Everything is ok, but I have encountered a strange behavior.
For example when I change delivery item quantity (LFIMG, for example 1->2 ) and then go back to the initial value (2->1)...
The problem is that when entering the method (debugger) I can see inside IT_XLIPS that LFIMG is updated, but Gross/Net weigth and volume fields still have old values (NTGEW, BRGEW, VOLUM).
That is a problem because highly possible is that after quantity field customer will also want to validate weight and volume fields.
Moreover I also checked FILL_DELIVERY_ITEM and CHANGE_DELIVERY_ITEM methods of BAdi mentioned. In all of them weight/volume (and probably other fields also) behave the same.
Could you share your comments on this issue please?
What would you recommend to do to enable such validation?