Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Function module to get admin within personnel area

Former Member
0 Likes
2,199

Hi,

are there any function module to get admin for certain personnel area?

i want to used it in workflow,

to make rule agents for employee within personnel number "A", this workflow will go to admin for personnel area "A"

thanks

1 ACCEPTED SOLUTION
Read only

ravi_lanjewar
Contributor
0 Likes
1,658

Hi,

You read personal number first, then pass the personal number to the any of following function module,

You will get personal area of employees.

1) BAPI_EMPLOYEE_GETDATA

2) HR_GETEMPLOYEEDATA_FROMUSER

Hi,

You read personal number first, then pass the personal number to the any of following function module,

You will get personal area of employees.

1) BAPI_EMPLOYEE_GETDATA

2) HR_GETEMPLOYEEDATA_FROMUSER

9 REPLIES 9
Read only

ravi_lanjewar
Contributor
0 Likes
1,659

Hi,

You read personal number first, then pass the personal number to the any of following function module,

You will get personal area of employees.

1) BAPI_EMPLOYEE_GETDATA

2) HR_GETEMPLOYEEDATA_FROMUSER

Read only

0 Likes
1,658

Sorry,

I think I didn't explain it clearly.

I'm looking for function module to be used in workflow,

when person in personnel area A create and send travel request, using ESS, then it will send notification to the admin for personnel area A to approve or reject it.

so i want to pass it to the admin of personnel area, not to the manager. and all transaction need to be approve for personnel number within personnel area A, will send to admin of personnel area A. so do for the other personnel area.

how it can be done?

thanks.

Edited by: nzworld on Aug 9, 2010 9:43 AM

Read only

RaymondGiuseppi
Active Contributor
0 Likes
1,658

If i undestand your requirement, you need to

- read Infotype 0105 to get personal number (HR_GETEMPLOYEEDATA_FROMUSER)

- read Infotype 0001 to get the personnel area (HR_READ_INFOTYPE or from previous)

- read table T526 to get the administrator (RP_GET_APPLICANT_CLERK)

Regards,

Raymond

Read only

Former Member
0 Likes
1,658

Did not get you... Will be helpful if you can explain in detail...

admin for personnel area

?

Read only

0 Likes
1,658

OK, here's the case.

in our company, we assign people to be the administrator.

each personnel area has administrator.

for example

- PERNER 34010-34050 are in personnel area 4700, with the administrator is user ABC

- PERNER 34051-34100 are in personnel area 4800, with the administrator is user EFG

so, when employee with personnel number 34010 create travel request, i want the workflow to send notification to admin/user ABC to either approve or reject the request.

how to do this?

thanks

Edited by: nzworld on Aug 10, 2010 4:30 AM

Read only

former_member226519
Active Contributor
0 Likes
1,658

there is no function module to get a leader from personnel area.

usually leaders are defined in the org structure. ask your org management guys.

Read only

0 Likes
1,658

it is not to get the leader,

but I want to get the PersAdmin.

in Organizational Assignment infotype.

how to send notification to the PersAdmin administrator??

thank

Read only

0 Likes
1,658

you will have to read T526 with WERKS = P0001-SBMOD and SACHX = P0001-SACHP to get the user ID.

With the user ID you can read infotype 0105 to get the PerNr of the SACHP and with this PerNr you can read 0105 again to get the email address.

Read only

0 Likes
1,658

Thanks, Volker Binder

your reference to read table T526 with WERKS = P0001-SBMOD and SACHX = P0001-SACHP to get the user ID.

it helps to create the function module.

thanks.

it solved.