Ansicht
Dokumentation

OHAIEOSP00105B - Activate the Customer Exit For Part Day Factoring

OHAIEOSP00105B - Activate the Customer Exit For Part Day Factoring

General Data in Customer Master   TXBHW - Original Tax Base Amount in Local Currency  
This documentation is copyright by SAP AG.
SAP E-Book

In this step, you enter the customer-specific code to handle part-day absences.

A possible part-day absence rule could be:

  1. Absences less than 4 hours duration imply no entitlement
  2. Absences greater than, or equal to, four hours duration imply half a day's entitlement
  3. More than two 4-hour absences in one day should not be allowed. Therefore, process the absence collision message.

In the above example, the code would look like:

if p_ab_mins < 240. "COMPARISON IN MINUTES
p_ab_mins = 0. "None of a day's entitlement.
else.
p_ab_mins = 720. "Half of a day's entitlement.
endif.

Why it may be necessary to implement this customer exit

If the scheme allows part-days to be processed, then this customer exit is mandatory unless you require the accuracy of entitlements in minutes, which is the default if this exit is not used.

When this is processed

As each day of an absence is processed, the employee's applicable scheme rules are derived and processed one by one. For the current scheme rule being processed, the check window, entitlement, absence grouping, and payment band are derived. Then the day is processed and if there are any entitlement days for the absence grouping and payment band that have not been used up in the check window, then the day will be "marked" using the valuation rule associated with this payment band.

Just before this routine is called

The previous marks for this day (previous part day absences) are derived and the previous number of entitlement minutes are totalled.

The elaspsed time in minutes has been derived for this part-day absence. The elapsed time is derived between start and end time regardless of breaks. Because there is no simple rule that could derive every eventuality in this sceranrio, none has been provided by SAP.

Just after this routine is called

The total number of entitlement minutes in this day is checked.

The default setup is that all part-day absences are handled in minutes. 11:00 to 12:00 is 60 minutes and therefore 60/1440 is one twenty-fourth of a whole day's entitlement.

This customer exit is one of seven available as part of the absence evaluation and payment scheme functionality. They are ordered from the most likely to be used to the least likely:

  1. EXIT_SAPLHRGPBS_OSP_OMP_CVR
Derive an employee's scheme according to client specific rules
  1. EXIT_SAPLHRGPBS_OSP_OMP_MIN
Define a part-day absence as entitlement in minutes
  1. EXIT_SAPLHRGPBS_OSP_OMP_SEN
Define the seniority time unit parameters
  1. EXIT_SAPLHRGPBS_OSP_OMP_ENT
Adjust the employee's entitlement
  1. EXIT_SAPLHRGPBS_OSP_OMP_LEN
Define a time unit length in days
  1. EXIT_SAPLHRGPBS_OSP_OMP_MTD
Define a rollback method
  1. EXIT_SAPLHRGPBS_OSP_OMP_MAN
Perform customer-specific processing for manual splitting

These are the only customer exits provided to supplement the Payroll absence processing functionality. Before using any of the customer exits, make sure you have consulted with SAP. This will ensure the changes you need are necessary (cannot be fulfilled elsewhere in Customising) and that the changes you are about to make will have the desired results with no adverse impact on performance.

General information about interfaced data

All seven customer exits have the following fields:
IMPORTING
VALUE(P_PERNR) LIKE PERNR-PERNR
VALUE(P_CHECK_DATE) LIKE SY-DATUM
TABLES
P_P0000 STRUCTURE P0000
P_P0001 STRUCTURE P0001
P_P0002 STRUCTURE P0002
P_P0004 STRUCTURE P0004
P_P0007 STRUCTURE P0007
P_P0008 STRUCTURE P0008
P_P0016 STRUCTURE P0016
P_P0041 STRUCTURE P0041
P_P2001 STRUCTURE P2001
P_ERROR STRUCTURE EDIMESSAGE

Do not change the data in the infotype tables

"P_ERROR" has the fields msgid, msgty, msgno, msgv1, msgv2, msgv3, and msgv4. This table should not be refreshed as it may contain "warning" messages that have not halted processing previously.

If an error happens in this function, then fill the record "P_ERROR" and append the record to the table. Do not perform any error handling in this function as it is used in payroll, dialog, and reporting (for example, statement "MESSAGE" etc.)

There is error handling provided. Passing back a value between 0 and 1440 minutes is valid. If two part-day absences in the same day cause more than 1440 minutes of entitlement in a day (due to this customer exit), the absence collision error message (HRPSGB_ABS 060) will be issued by the second absence.

The following is a simple demonstration of the coding that may or may not be necessary. Note that the type statements are necessary because the "MOVE" statement is not as useful as it first seems.

DATA: start_time TYPE p,
end_time TYPE p,
start_hhmmss TYPE t,
end_hhmmss TYPE t,
elapsed_time TYPE p.
*
CLEAR ab_mins.
*
MOVE ab-beguz TO start_hhmmss. "time in 00:00:00 format
MOVE ab-enduz TO end_hhmmss. "time in 00:00:00 format
MOVE start_hhmmss TO start_time. "time in seconds past midnight
MOVE end_hhmmss TO end_time. "time in seconds past midnight


elapsed_time = ( end_time - start_time ) / 60. "time in minutes with
"decimal places kept






BAL Application Log Documentation   Fill RESBD Structure from EBP Component Structure  
This documentation is copyright by SAP AG.

Length: 6211 Date: 20240523 Time: 190002     sap01-206 ( 90 ms )