Hi Experts,
My requirement is to throw the error messages in appraisal document whenever the weightage value for some elements exceeds the mentioned values (eg; Initiative & Innovation - 40%). Tcode: PHAP_ADMIN. If error occurs, save and sub status change should not happen. eg; after pressing push button 'send to supervisor', sub status changes to 'Supervisor Q1 rating'.
Initially we tried to use the badi HRHAP00_DOC_BC. But it triggers for all the buttons including 'BACK' button in standard tool bar. So We used HRHAP00_DOC_SAVE. We created the logic and filled the exporting parameter S_RETURN with error msg details. It shows error msg finely before save.
But when push buttons like 'send to supervisor', 'send to department head' is pressed, control comes out of the screen i.e change screen of appraisal document and then error is thrown outside. And sub status change is also happening. Error message is not stopping the sub status change.
Please help and suggest how to solve this issue.
Thank you so much.
Regards,
Rajee