on 04-07-2014 11:03 PM
Dear friends:
With the help of some folks in this thread I had been able to adapt the webdynpro HRECM00_PLANNING_UI to suit my requirement, at least so far. Now I have to modify (disable and change the name) of a couple of buttons that are located in the upper part of the webdynpro (save draft and display progress):
I tried to access them from webdynpro HRECM00_PLANNING_UI but it looks like they are part of the webdynpro FPM_GAF_COMPONENT (based on the technical help that I get from one of the buttons) so the windows of WB HRECM00_PLANNING_UI do not have access to them:
I think I could enhance directly class FPM_GAF_COMPONENT but I'm not sure if that would affect also other webdypros that also inherit from this component?
Any help will be greatly appreciated,
Thanks in advance,
Federico.
Hi Federico,
Please follow the below steps to configure/change the button/UI properties.
1. Go to package - PAOC_ECM_ADM_PLANNING_UI.
2. Go to FPM Floorplan Configuration - ECM_AC_PLANNING_UI_GAF, now click on Start Configurator - Display Configuration.
3. You will get the new window and go to Additional Functoins - Enhance. Give your enhancement name and save it in your package.
4. In your newly enhanced screen select the second road map step and click on the buttons that you want to customize to your need. You will get the below properties and you can do your required changes.
or else
1. Go to FPM Application Configuration from package.
2. From the Tool bar, select Web Dynpro Configuration->Test->Execute in Administaration Mode. You will get a new window.
3. Right click on the button you want to make change and select Settings for Current Configuration.
4. Make the required changes and save it in a TR.
Hope you are clear now:)
BR,
RAM.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Samuli / Ramakrishnan:
Thank you so much for taking the time to help me out with this! I was able to achieve my req. with both your recommendations. I wish I could hug you both !!
Thank you once again fellas!!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you Samuli! I tried to use the following code within one of the views of HRECM00_PLANNING_UI with no luck:
data lr_lbl type ref to cl_wd_toolbar_button.
lr_lbl ?= view->get_element( ID = '_CFG_BUTTON_8' ).
IF lr_lbl IS NOT INITIAL.
lr_lbl->set_enabled( EXPORTING VALUE = abap_false ).
endif.
Thank you Samuli!
I accessed the configuration component but I was not able to modify it, looks like it is a SAP component.
I was able to overwrite the method you told me and add the new text directly in the dfine_button method:
lo_cnr_gaf->define_button(
EXPORTING
iv_mainstep_id = 'GAF_STEP_PLANNING'
iv_element_id = 'FPM_BTN_SAVE'
iv_function = if_fpm_constants=>gc_button-other_function
iv_enabled = abap_true
iv_visibility = lv_save_visibility
********FM add new text
iv_text = 'Save Recommendations'
****************
However, I have not been able to disable the button display progress, I could not find this button in any other method (by the way, how do you do it to search globally within all methods of COMPONENTCONTROLLER?)
Thank you once again!
You have to make a copy of the SAP configurations (Application Configuration, Component Configuration) and refer the custom Application Configuration in either URL parameters or Launchpad, etc. I guess the button Display Progress is always displayed, simply disable it:
data lo_fpm type ref to if_fpm.
data lo_cnr_gaf type ref to if_fpm_cnr_gaf.
lo_fpm = cl_fpm_factory=>get_instance( ).
lo_cnr_gaf ?= lo_fpm->get_service( cl_fpm_service_manager=>gc_key_cnr_gaf ).
lo_cnr_gaf->define_button(
exporting
iv_mainstep_id = 'GAF_STEP_PLANNING'
iv_element_id = 'FPM_BTN_PROGRESS'
iv_function = if_fpm_constants=>gc_button-other_function
iv_enabled = abap_false
).
Dear Samuli: Thank you so much for taking the time to help me!
I tried your code in method FPM_SETUP_APPLICATION, but nothing changed in the webdynpro when I tried the service. I checked again the configuration application and that button does not have anything assigned in the field "element ID", could it be the reason why I can not reference it using iv_element_id?
It is not a big issue though, with the change of the text of the other button I'm more than done
Thanks again !
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.