We have a requirement in SRM to customize couple of standard Search helps attached to the Webdynpro components. As such I know the concept of how we can handle this requirement but hitting an issue.
Standard Working scenario -
1) Standard Structure available with multiple fields. Two fields that are of our interest are SH_VALUE and SH_VALUE_LABEL.
2) Standard Search help for this being used has fields VALUE and VALUE_LABEL.
3) In the Structure the both the fields SH_VALUE and SH_VALUE_LABEL are mapped to the Search help VALUE and VALUE_LABEL.
4) In the WD component the node is mapped to the standard structure.
Running the application and the picking up the values from F4 on the SH_VALUE field will return its corresponding value and also map the SH_VALUE_LABEL field with the Label from the F4 since the structure and Search help mapping are there.
So far good when its standard.
Issue I am facing -
We need to modify this standard search help to customize our needs.
1) Did a Copy of the standard Search help and then modified to suit our needs. The output structure of the search is still the same as the standard one.
2) Did a Post Exit in the WD component to call our custom search help through the below code -
data lo_nd_attrib type ref to if_wd_context_node. data lo_nd_attrib_info type ref to if_wd_context_node_info. lo_nd_attrib = wd_context->path_get_node( path = `ATTRIBUTES_DATA.ATTR_DTLS_MULT` ). lo_nd_attrib_info = lo_nd_attrib->get_node_info( ). lo_nd_attrib_info->set_attribute_value_help( name = 'SH_VALUE' value_help_mode = '121' value_help = 'Z_ORG_ATTR' ). lo_nd_attrib_info->set_attribute_value_help( name = 'SH_VALUE_LABEL' value_help_mode = '121' value_help = 'Z_ORG_ATTR' ).
Running the application just returns the SH_VALUE field but does not get the data for the SH_VALUE_LABEL.
Is there something wrong in the way I am calling the Custom Search help or should I need to approach this differently?