SAP ABAP IMG Activity PAY_IN_EPF_956 (BAdI: Calculate VPF Contribution)
Hierarchy
SAP_HRCIN (Software Component) Sub component SAP_HRCIN of SAP_HR
   PY-IN (Application Component) India
     P40C (Package) HR customizing: India
IMG Activity
ID PAY_IN_EPF_956 BAdI: Calculate VPF Contribution  
Transaction Code S_L7D_24002474   (empty) 
Created on 20100722    
Customizing Attributes PAY_IN_EPF_956   BAdI: Calculate VPF Contribution 
Customizing Activity PAY_IN_EPF_956   BAdI: Calculate VPF Contribution 
Document
Document Class SIMG   Hypertext: Object Class - Class to which a document belongs.
Document Name HR_IN_PF_CONTRI    

Title

BAdI: Calculate VPF Contribution

Use

This Business Add-In is used in the Provident Fund (PY-IN) component.

This Add-In enables you to set the system to calculate Voluntary Provident Fund (VPF) contribution as per customer specific requirements. The Add-In uses the method .

In the standard system, a method is provided to calculate VPF contribution. However you can Customize this as per your requirements using the method VPF_CONTRI.

The BAdI has the following parameters:

  • Employee personnel number
  • Start date and end date and payment date.
  • Employee VPF Fix Amount
  • PF Table
  • Input Table
  • Country Grouping
  • VPF Table

Sample Code

DATA: pfbas_40epf TYPE t511p-betrg,

vpf_contri TYPE t511p-betrg,

vpf_lgart TYPE pc207-lgart,

ctype TYPE pin_ctype,

vpflm_tmp TYPE pin_vpflm,

vpf_max_contri TYPE t511p-betrg,

tmp_tstid TYPE pc2_in07-tstid.

DATA: wa_it LIKE LINE OF input_table,

wa_it1 LIKE LINE OF input_table,

wa_epf LIKE LINE OF epf.

DATA: wa_tmp_it type pc207.

DATA: tmp_it TYPE STANDARD TABLE OF pc207.

clear: pfbas_40epf, vpf_contri, vpf_lgart.

READ TABLE epf index 1 INTO wa_epf.

vpf_lgart = wa_epf-evpfw.

ctype = wa_epf-ctype.

SELECT SINGLE vpflm FROM t7inf3 INTO vpflm_tmp

WHERE ctype EQ wa_epf-ctype

AND begda LE wa_epf-endda

AND endda GE wa_epf-endda.

IF NOT vpflm_tmp IS INITIAL OR vpflm_tmp NE 100.

LOOP AT input_table INTO wa_it1 WHERE lgart = vpf_lgart.

vpf_contri = vpf_contri + wa_it1-betrg.

APPEND wa_it1 TO vpf_tab.

ENDLOOP.

CLEAR tmp_tstid.

LOOP AT epf INTO wa_epf.

READ TABLE input_table INTO wa_it WITH KEY lgart = '/3FB'

apznr = wa_epf-apznr

cntr1 = wa_epf-cntr1.

vpf_max_contri = vpf_max_contri + wa_it-betrg * vpflm_tmp / 100.

ENDLOOP.

IF vpf_contri GT vpf_max_contri.

wa_it1-betrg = vpf_max_contri.

modify vpf_tab index 1 from wa_it1.

ENDIF.

ENDIF.

Prerequisites

You should only carry out this step if both of the following points apply:

  • The SAP standard processes do not suit your needs
  • You are a competent ABAP/4 programmer

Default

In the standard system, the Business Add-In is not activated.

Activities

After calling up the IMG activity, a dialog box appears, in which the existing implementations are displayed. Choose Change, and proceed as follows:

  1. From the tab index, choose Interface.
  2. Place the cursor on the method, and double-click to enter method processing.
  3. Enter the coding for the implementation between the statements method if_ex_hr_in_cco_processing ~ <Name of method> and endmethod.
  4. Save and implement your coding. Return to the Edit Implementation screen.
  5. Save the entries on the Edit Implementation screen.

    Note: You can also change the implementation, and then activate it at a later time. In such a case, end the processing stage at this point.

  6. Choose Activate

    The coding you stored in the method will be run when the application program is executed.

Example

To display the sample code, choose Goto -> Sample Code -> Display.

See also

Business Attributes
ASAP Roadmap ID 257   Create User Exits 
Mandatory / Optional 2   Optional activity 
Critical / Non-Critical 2   Non-critical 
Country-Dependency I   Valid for countries specified 
Customizing Attributes Country Key Country Name
PAY_IN_EPF_956 IN India
Maintenance Objects
Maintenance object type E   Business Add-In - Definition 
History
Last changed by/on SAP  20100722 
SAP Release Created in 600