There is a requirement where supplier needs to send his batch and manufacturing date details when he confirms the PO in SNC WEBUI PO details.
The scenario is when Supplier receives any PO, he will confirm that PO and PO confirmation will be sent out to Customer’s R/3 system.
He will send one more confirmation on Batch & Manufacturing Date on the same PO. So at that time they need to have this Manufacturing Date & Supplier Batch field editable which in standard not available.
This document describes how to make these fields editable also in general it can be used to make fields editable in any WEB UI component. To make this editable we need to implement the exits.
/SCF/PO is the web component which triggers through PO details WEB UI.
Go to the main view details and click on methods. Currently there is not exits which have been implemented.
Click on enhancement button(spiral button) and create an enhancement.
After creating this enhancement you will see all the exits available with respect to individual methods.
To achieve the described functionality we need to have one global variable which is added attributes tab.
Below methods are enhanced to achieve this functionality.
First method is BEFOREACTION is to capture the user click on screen, if this is change then set the global variable Z_VARUN = X. This will be further used to modify the screen. IF this is save button then get the values from screen for Item data, schedule line data.
Second method MODIFYVIEW is used to make the fields editable based on global variable set in the BEFOREACTION.
UPDATE_ITEM_DATA method is used to update the item details table with manufacturing data and batch details.
Same details are updated at schedule lines table as well.
Now data is updated in run time tables at run time with new information for manufacturing data and supplier batch. Now this data needs to be passed on to the table which is actually going to save the data in data base.
For this method /SCA/IF_EX_ORDER~BEFORE_WRITE is used to implement. In this method you swap the values of these 2 fields.
Now when you click on change button in the very first screen of this document following screen will come and fields will be editable.
Put any values in these two fields and save it.
The values are saved and when you re-open this PO, values are visible again.