Ansicht
Dokumentation

HRPAYCA_B_YE_BOX_ADJ - BAdI definition for the Canada Year End report

HRPAYCA_B_YE_BOX_ADJ - BAdI definition for the Canada Year End report

ROGBILLS - Synchronize billing plans   Addresses (Business Address Services)  
This documentation is copyright by SAP AG.
SAP E-Book

This Business Add-In (BAdI) is used in component Payroll-CA(PY-CA), and enables you to implement customer code to change specific information that will be printed in the Year-end forms.

This BAdI has the same behavior and purpose of the ABAP forms that are already available to change information of the YE forms. These ABAP forms are configured with the Symbolic module name(T596F-SNAME) equal to KYER in the HR Subroutines(V_T596F) view.

This BAdI does not replace these forms, so you may choose to implement the BAdI instead of the ABAP forms or keep your implementation in the ABAP forms.

By implementing this BAdI, you may change the following information:

  • The custom sort field that can be printed in the YE forms.
  • Boxes 10 and 29 that will be printed in the T4 Statement of Remuneration Paid (slip).

The interface IF_HRPAYCA_B_YE_BOX_ADJUSTMENT comprises the following methods:

1. CHANGE_CUSTOM_FIELD: Method to fill in the field with the corresponding custom code to be printed in the YE forms.

2. CHANGE_EMPLOYMENT_CODE: Method to fill in employment code displayed in Box 29 of T4 form.

3. CHANGE_WORK_AREA: Method to fill in work area that is displayed in Box 10 of T4 form.

Parameters

The following parameters are called using the method of this BAdI:

  • IS_MAIN_DIR: Contains the header information for each form processed for each employee.

All methods receive the IS_MAIN_DIR structure as an importing parameter. This parameter contains the header information for each form processed for each employee. The structure contains, among other information, the following employee data:

  • Personnel number (PERNR)

  • Person ID (PERSONID), in case you have the Concurrent Employment (CE) functionality active

  • Business number (BUSNM)

  • Province/State (STATE)

1. CV_CUSTOM_FIELD: The custom sort field that will be printed in the form.

2. CV_EMPLOYMENT_CODE: The employment code to be printed in the Box 29 of the T4 form

3. CV_EMPLOYMENT_CODE: The work area to be printed in the Box 10 of the T4 form

The ABAP forms are called when you have configured the HR Subroutines(V_T596F) view with the Symbolic module name (T596F-SNAME) equal to KYER.

The BAdI will not replace the customer-implemented forms FORM assign_custom_field, FORM retrieve_emp_code and FORM adjust_wrkar. Thus, if you have already implemented them, these forms will not be impacted. The customer exit flow will be the following:

1. The report will first call the BAdI method

2. If the BAdI is not implemented, the corresponding form will be called

3. If the BAdI is implemented, but the method is not implemented, the corresponding form will be called

4. If the BAdI and the BAdI method are implemented, but you want to use the corresponding ABAP form implementation instead, raise the following exception in the BAdI method: RAISE EXCEPTION TYPE cx_sy_dyn_call_illegal_method. This way, the corresponding form will be called.

The following example shows how you can raise an exception as above mentioned in item 4:

METHOD IF_HRPAYCA_B_YE_BOX_ADJUSTMENT~change_custom_field.

RAISE EXCEPTION TYPE cx_sy_dyn_call_illegal_method.

ENDMETHOD.

As a result, the ABAP form assign_custom_field will be called. This has to be done for each BAdI method you want the form to be called instead.

The BAdI described here is optional. Therefore, only implement this BAdI if your enterprise has the need and desire to do so.

To implement Business Add-In (HRPAYCA_B_YE_BOX_ADJUSTMENT), follow these steps:

1. Execute this IMG step. On the subsequent screen, enter a name for the implementation you wish to create.

2. Choose Create. (Or, alternatively, Edit. The remainder of the documentation for this activity describes the steps to be performed when you create a new implementation.)

Caution

3. Enter a short text for the implementation in the Implementation namefield, then choose Continue.

4. On the subsequent screen, specify an Implementation short text, then choose the Interface tabstrip. The name of the implemented class fields are already found in this tabstrip.

5. Save your entries and assign the implementation to a package.

6. Place the cursor on the method you wish to process, then double-click to initiate method processing.

7. Enter the code for the implementation between the statements method ~ and endmethod.

8. Save and implement your code.

9. Return to the Edit Implementation screen, then save your entries there.

10. If you wish to activate the implementation you have created at a later date, then exit the Edit Implementationscreen without activating the implementation. Otherwise, choose Activate from this screen to activate the implementation for immediate use.






CL_GUI_FRONTEND_SERVICES - Frontend Services   BAL_S_LOG - Application Log: Log header data  
This documentation is copyright by SAP AG.

Length: 6453 Date: 20240523 Time: 192841     sap01-206 ( 117 ms )