ESI Contributions in Global payroll for India

Common wisdom
Employee State Insurance (ESI) is a type of insurance scheme that addresses Indian employees whose gross wage is INR 15000 or lesser. Employee contributes 1.75% and Employer contributs 4.75 of the monthly gross wage.

Common questions

Question 1: When an employee receives an increment, can the Employer stop ESI deductions and contributions from that month onwards?

The answer is “No”. In the scheme of ESI, the whole financial year is split into two blocks – April to September and October to March.

When an employee has contributed to ESI atleast once in a block, the employee must continue to contribute to ESI for the rest of the block. Lets say, someone receives an increment, from 1-June onwards, that bumps their ESI gross from 14000 to 17000. Since the employee has contributed to ESI in April and May, he/she must continue to contribute to ESI until September.

Question 2: In that case, what is the wage based on which ESI should be calculated?

There is a common misconception that when ESI gross for an employee exceeds 15000 (the limit set by govt and revised from time to time), ESI deductions should be based on the limit. No, ESI should be deducted on the actual ESI gross regardless of the limit.

Going back to the example above, the employee’s ESI deduction in June will be 1.75% of 17000 and not 1.75% of 15000.

How is this handled in PeopleSoft’s Global Payroll for India?

ESI deduction is based on Generation control ESI GC ENROLL, which is based on ESI FM ENROLL GC. I have re-produced the formula and left a few comments also.

Lines 5 through 36 handle block 1, while lines 37 and later handle block 2.

Look out for AC[ESI_FYTDA] on line 27. Anytime that accumulator is greater than zero, the generation control turns true.

Similarly, look out for the historical rule HR[ESI HR 2ND SEG]. The historical rule computes total of ESI deductions made in block 2 (October to March). Anytime it turns out non-zero, the generation control is set to true.


IF AC[ESI GROSS WAGES] > 0 THEN

IF ( AR[ESI AR ENROLLMENT] = 1 AND FM[AGE60 FM] = 1 AND VR[ESI VR EFF STATUS] = 'A' ) THEN /* If enrolled in ESI and Aged < 60 */

IF FM[ESI FM 1ST SEG] = 1 THEN /* In block 1 - Period  b/w 1st April and 30th Sep*/

IF FM[ESI FM 1ST MTH SEG] = 1 THEN

IF AC[ESI GROSS WAGES] < VR[ESI VR GROSS CHECK] THEN /* ESI Gross Check = 15000*/

1 >> FM[ESI FM ENROLL GC]

ENDIF

ELSE

IF SY[LAST HIRE DT] >= SY[PERIOD BEGIN DATE] THEN /*New hire and first payroll*/

IF ( AC[ESI GROSS WAGES] < VR[ESI VR GROSS CHECK] ) THEN

1 >> FM[ESI FM ENROLL GC]

ENDIF

ELSE

IF ( AC[ESI GROSS WAGES] < VR[ESI VR GROSS CHECK] OR AC[ESI_FYTDA] > 0 ) THEN

1 >> FM[ESI FM ENROLL GC]

ENDIF

ENDIF

ENDIF

ELSE /* In block 2 - Period Begins after 30th Sep*/

IF FM[ESI FM 1ST MTH SEG] = 1 THEN

IF AC[ESI GROSS WAGES] < VR[ESI VR GROSS CHECK] THEN

1 >> FM[ESI FM ENROLL GC]

ENDIF

ELSE

IF SY[LAST HIRE DT] >= SY[PERIOD BEGIN DATE] THEN /* New hire and first payroll*/

IF ( AC[ESI GROSS WAGES] < VR[ESI VR GROSS CHECK] ) THEN

1 >> FM[ESI FM ENROLL GC]

ENDIF

ELSE

HR[ESI HR 2ND SEG] >> VR[GP TEMP001 NUM] /* Historical rule to identify ESI deductions in Block 2*/

IF ( AC[ESI GROSS WAGES] < VR[ESI VR GROSS CHECK] OR VR[ESI TOT2ND SEG VAL] > 0 ) THEN

1 >> FM[ESI FM ENROLL GC]

ENDIF

ENDIF

ENDIF

ENDIF

ENDIF

ELSE

0 >> FM[ESI FM ENROLL GC]

ENDIF

Sending emails from Openbravo workflows

Sometime ago, Openbravo made that big leap by integrating their wonderful ERP with a workflow engine. The Workflow Engine of choice was Activiti. You can download the module from here. Refer to the wiki page for more background.

The integration module available on forge is based on Activiti 5.8.

Its a world of goodness – Openbravo and Activiti together. Once you and your customers start experiencing the results, there is no going back. Workflows will climb their way up from a distantly relevant “Nice to Have” to an enriching “That’s easy, lets have that” position in your scheme of ERP implementation.

While discussing Openbravo workflows for an organization, a customer asked “Can I have an email sent at this point in the flow?”. Activiti makes it easy to send out emails through email tasks. There are a number of articles on the internet, so I am not delving into email tasks now.

They are an organization that have their email hosted on a google domain. For example, if the emails were sent out using gmail, the activiti.cfg.xml would look like this:

<property name=”mailServerPort” value=”587″ />
<property name=”mailServerHost” value=”tls://smtp.gmail.com:587″ />
<property name=”mailServerDefaultFrom” value=”sender@gmail.com” />
<property name=”mailServerUsername” value=”sender” />
<property name=”mailServerPassword” value=”*******” />
<property name=”mailServerUseTLS” value=”true” />

They are an organization that have their email hosted on a google domain.

When the workflow was fired, Activiti produced error messages and it was evident that it didn’t like the TLS part of config. It turns out that Activiti 5.8 doesn’t support useTLS parameter.

TLS is addressed in this patch. We applied the patch on top of Activiti 5.8 thats shipped with the integration module and that did the trick for us, and now emails go out from Openbravo.

Optimus HCM – Leave approval workflow

Optmius HCM, the Human Capital Management solution from Fugo, is built on the Openbravo ERP framework. Leave approval process is workflow enabled using Openbravo-Activiti integration module.

Watch the screencast from here