04-03-2014 7:03 PM
Hi Experts,
I have a requirement to add a new field (SLFDT - Statistical delivery date) in ME22N fast change option.
I have created an append structure for MEPOITEM and MEGUI_MASSCH_ALLOWED_FIELDS, but the new field is not reflected in the fast change output.
Lot of discussions happened in SDN about this, but none is updated with a solution.
Kindly let me know if you could provide some hints on this.
BR/Josh
04-03-2014 8:09 PM
Structure MEPOITEM is not required.
1. Add an append structure in MEGUI_MASSCH_ALLOWED_FIELDS
2. Create FM for exchanging data.
3. Use BADI ME_PROCESS_PO_CUST- Method TRANSPORT_TO_MODEL
Will update once I am done with my dev and testing.
If u ve any inputs, please add.
BR/Josh
04-03-2014 8:09 PM
Structure MEPOITEM is not required.
1. Add an append structure in MEGUI_MASSCH_ALLOWED_FIELDS
2. Create FM for exchanging data.
3. Use BADI ME_PROCESS_PO_CUST- Method TRANSPORT_TO_MODEL
Will update once I am done with my dev and testing.
If u ve any inputs, please add.
BR/Josh
04-25-2014 12:03 PM
Hello Josh,
have you a solution to this respectively have your mentioned steps worked?
Please let me know.
Thanks.
BR Thomas
03-04-2015 1:08 PM
Same for me.
Someone succeed to add field SLFDT in fast change on PO ?
Thanks.
03-04-2015 1:58 PM
Hi Michael,
Yes I was successful in adding a field to SLFDT.
1. Include LWRF_POHF_MASS_CHANGEPT1 - Add the selection screen parameter here.
2. LWRF_POHF_MASS_CHANGEF01 - FORM change_data - Create an enhancement towards the last and add the below logic.
**In this form LS_SELECT will have the value for the new field.
Update the new values in the ITAB CT_EKET and inside the loop for CT_EKET, Read CT_EKETX ASSIGNING <ls_eketx> and mark the new field added as 'X'
3. Include LMEGUICJQ -> CLASS lcl_mass_change_view_mm IMPLEMENTATION -> METHOD transport_to_model. - create implmentation in the first available enh point.
lo_item ?= im_model.
lo_header ?= lo_item->my_parent.
CALL METHOD fs_get( im_model = im_model ).
CALL METHOD lo_item->get_data
IMPORTING
ex_data = lwa_item_data.
CALL METHOD lo_item->get_datax
IMPORTING
ex_data = lwa_item_datax.
LOOP AT my_value_models INTO lsa_model.
mmpur_dynamic_cast la_value_model lsa_model-model.
CHECK NOT la_value_model IS INITIAL.
CALL METHOD la_value_model->get_datatype
IMPORTING
ex_datatype = la_datatype.
SHIFT la_datatype UP TO lc_hiphen.
SHIFT la_datatype LEFT BY 1 PLACES.
<<LA_DATATYPE WILL HAVE THE FIELD NAMES>>
IF la_datatype = <<Check ur field>>.
ASSIGN COMPONENT la_datatype OF STRUCTURE lwa_item_data_temp
TO <src1>.
CALL METHOD la_value_model->get_value
IMPORTING
ex_value = <src1>.
pass the <src1> to a temp field, Use a FM to set this value to a global parameter and this can be retrieved below.
4. Include LMEGUICIF, method transport_to_dynp.
Get the new value using a custom function module (To Hold Global Values) and then update the structure mepo1320 with the new value.
Create structures as and when required.
BR/ Josh
07-16-2015 9:20 PM
Hi Josh,
How do you add codes to LWRF_POHF_MASS_CHANGEPT1 and LWRF_POHF_MASS_CHANGEF01 - FORM change_data? There is no enhancement spots there.I put a break point there, it is not hit when I run the fast button. I am having the similar requirement. Could you please help me on this?
Thanks a lot!
Meiying