Cross entity derivations using BAdI usmd_rule_service_cross_et
The document explains how to derive values on Web UI based on certain screen fields.
We can use the BAdI for deriving cross entities, ir usmd_rule_service_cross_et. Here I am deriving the EAN number with respect to the unit of measure.
1. In SE18 enter the BAdi name and display it.
2.Right click and create BAdI implemenmtation
3. Enter enhancement class
4.Now you will be able to see the implementation, and edit the implementation
5.We have to use Field symbols for this and along with data declaration, declare the fs part too.
6.We are using cl_usmd_app_context for getting the crequest id
7.Now call the method io_changed_data
8. Now we have to assign the values into the declared field symbols
9. Assign the values of EAN with respect to the UOM
10. Now call the method io_model->create_data_reference
11.Write data to change buffer and pass the new values to io_write_data->write_data
12. The EAN values , derived will be populated on UI screen.