cancel
Showing results for 
Search instead for 
Did you mean: 

BSP Questions

Former Member
0 Kudos

I'm implementing E-Recruiting and I added a new field to a existing infotype HRP5107. It shows up automatically on E-Recruiting website as a text field. I was wondering in BSP is it possible to manipulate the field to be a dropdown list that will allow the user to select multiple fields? And I have two fields that already exist I need to set them to a default value. Can this be done on BSP side? If not how can I do this?

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Matthew Wong,

You mean to say, mutiple values from Dropdown list? Yes...It is possible for users to select multiple values from dropdown list box. Please try this below code from BSP side.

<hrrcf:formLayoutListBox id = "field_id"

label = "<%= otr(ZE-RECRUITING/EDUCATION_TYPE_EN) %>"

nameOfKeyColumn = "LOW"

nameOfValueColumn = "DDTEXT

table = "<%= controller->pt_default_list %>"

selections = "<%= controller->pt_selected_list %>" />

Let assume that, pt_default_list & pt_selected_list type as <b>ddfixvalues</b>

Please populate <b>PT_DEFAULT_LIST table in DO_INIT()</b> method itself.

Now, you need to populate the user selected values from dropdown list into <b>pt_selected_list</b> table, it will not get populate automatically. In order to this, you need to handle the code in DO_HANDLE_DATA() method.

LOOP AT form_fields INTO ls_form_field.

CASE ls_form_field-name.

WHEN 'field_id'.

LOOP AT form_fields INTO ls_form_field WHERE name = 'field_id'

POPULATE the table <b>pt_selected_list</b>

ENDLOOP.

END LOOP.

For your second question....

To make a default value for particular field in the BSP, try to do in DO_INITATTRIBUTES() method. Its a best practice to add logic in controllers rather than doing it in BSP's.

I hope this would resolve your problem.

Regards,

Ramki.

Former Member
0 Kudos

Ramki and Raja,

Thanks for your help to this post. I was able to resolve my issue with putting the Application Source fields with its dropdown lists from HRP5132 onto the candidate profile record of HRP5106. I accomplished this by merging the coding from the classes CL_HRRCF_REG_APPLN_SOURCE_V and CL_HRRCF_PROFILE_DES_JOB_M into ZCL_HRRCF_PROFILE_DES_JOB_M. I also merged the bsp coding from BSP application HRRCF_reg_appln view appl_source.bsp with view desJob_m.bsp in the bsp application ZHRRCF_PROFILE.

In addition, I had to change table T77RCF_CS_ITEM for element 5 - Candidate profile - desired job to point to application ZHHRCF_PROFILE.

Sandra

soldner
Participant
0 Kudos

Thanks Ramakrishnan!!

I am coding a BSP using JQuerymobile and have a multiple select for vendors.  Couldn't find out how to get all the values, but your post put me on the right track.  Code snippet is the not my final code but proof of concept.

In the "oninputprocessing"

DATA:   lt_selects TYPE tihttpnvp.

request->get_form_fields(

*  EXPORTING

*    formfield_encoding = 0

   CHANGING

     fields             = lt_selects

        ).

In itab lt_selects, the first 3 are what I was looking for!!!

1vendor_select0000010005
2vendor_select0000010007
3vendor_select0000010009
4date
5date_low
6to
7oninputprocessingnext

The rest is simple ABAP.

Thanks again!

raja_thangamani
Active Contributor
0 Kudos

Try this, you can select multiple entries:

Page attributes:  myItab TYPE STRING_TABLE.

<htmlb:listBox id = "MyID1"
nameOfKeyColumn   = "NAME"
nameOfValueColumn = "VALUE"
size              = "10"
selections = "<%= myItab %>" 
table             = "<%= itab_country %>" />
 

Here "myItab" will have the selected entries.

<b>Note:-</b> Use SHIFT or CRTL key to select more than one entries.

Raja T

Former Member
0 Kudos

Did you ever get this resolved? It turns out that I must do very similar request to HRP5107 to add the application source and source type fields to this infotype and was wondering if you accomplished this. I have copied HRRCF_PROFILE to ZHRRCF_PROFILE and made the BSP changes, and updated the T77RCF_LOG_APPl for entry PROFILE_BUILDER, but it does not seem to be calling up the ZHRRCF_PROFILE bsp. Help?