on 10-27-2010 6:00 PM
Hello,
The W-4 application in ESS is picking up emergency address of an employee and giving an option to create an IT0210 record for that state also (if the state is different from the work state of the employee). However, this is not desired and emergency address should not have any thing to do with W-4 records of the employee.
Since we could not find any configuation to avoid this, we have implemented the BADI HRXSS_PER_SUBTYPE with custom logic to check only Infotypes 0207, 0208, and 0209 for the W-4 application. Only if active records exist for these infotypes, employee will be able to create a W-4 record for that state.
However I wanted to check with few other people out there, if there is any configuration available to prevent this from happening (instead of implementing the BADI).
Any inputs will be appreciated.
Thanks,
Shanti
I pretty much did the same..In adition I'm also validating the W4-Subtype with STATE in the Legal Address of the employee's 0006.
~Suresh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The code which pulls in the subtypes in ESS is in the function module
'HRXSS_PER_GET_ESS_SUBTYPES' where all the states mentioned in IT0006,
IT0207,IT208 are cumulated. These states are then checked with the
W4 indicator set in T5UTZ and then the states for which the W4 indicator
is set as either 1,2 or 5 are populated into subtype table.The final
entries inside this internal table decides what appears on the ESS for
IT210.
This subtype table is then passed to ur exit implementation.The logic
for filling this internal table is in the form 'subtype_filter' which
is called in the FM 'HRXSS_PER_GET_ESS_SUBTYPES'.My suggestion is you
can rewrite the entire logic of filling the subtype table in ur
implementation and overwrite the subtype internal table which we pass.
In other words, you can query IT0006,IT207,IT208 and use it according
to your requirements.
check
CL_IM_HR_ES_W4ADDRESS_IM and HRXSS_PER_SUBTYPE
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Siddharth,
I am having a similar requirement, and I did exactly as you have explained in this blog and one other blog as well.
However after the filtration is done and lets the subtype table contains 2 entries, it is being passed in to the class CL_HRPA_PERNR_INFTY_XSS : IF_HRPA_PERNR_INFTY_XSS~READ_METADATA,
Here my subtype table is being read and compared with a table process_allowed_subtypes. This tables contains all the subtypes which were present before filtration.
The below given code then gets executed and since the entries are different in both tables an exception is generated. I really am not sure how this process_allowed_subtypes table is being filled.
Can you please suggest a way out?
* If the user has restrictions on subtypes on top of the t7xssspersubtype table, he gives it via the url parameters.
* Obviously, if the parameters are not available then do not process further for restrictions.
* If the url parameters contain subtypes that are not present in the t7xsspersubtype then throw an exception.
IF process_allowed_subtypes IS NOT INITIAL.
LOOP AT subtytab INTO subty_l.
READ TABLE process_allowed_subtypes WITH TABLE KEY subtype = subty_l-subtype TRANSPORTING NO FIELDS.
IF sy-subrc <> 0.
DELETE TABLE subtytab FROM subty_l.
ENDIF.
IF sy-subrc = 0.
DELETE TABLE process_allowed_subtypes WITH TABLE KEY subtype = subty_l-subtype.
ENDIF.
CLEAR subty_l.
ENDLOOP.
* If the url parameters are given, then loop through the subtype-table and eliminate the subtypes that are not needed.
DESCRIBE TABLE process_allowed_subtypes LINES lin.
IF lin > 0.
RAISE EXCEPTION TYPE cx_hrpa_invalid_customization.
ENDIF.
ENDIF.
CATCH cx_hrpa_invalid_customization.
IF 1 = 0.
MESSAGE ID 'PG' TYPE 'E' NUMBER '016'.
ENDIF.
User | Count |
---|---|
103 | |
12 | |
11 | |
6 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.