Entry code scripts for earning and paying out leave

This article describes a simple and common script and set up for entry codes used for earning leave that is paid out in the payroll period where the seafarer signs-off

Description

You will need two entry codes, one for earning leave and the other for paying out the earned leave.

Earned Leave Compensation

This entry code is set to calculate the earned leave amount every month and store it into an accumulator, but it will not be included in the wages that are paid out.

  1. Create the entry code with the number and name as wanted. Set the entry code with Allowance

  2. Make sure the option Transfer to History even if calculations are zero is ON.
    This ensures that the entry codes is stored in history, even if the entry code is not actually paying out an amount to the crew

  3. Link the entry code to the corresponding script

  4. Add the script
    In this sample, the monthly leave compensation is stored in line 2 in the pay scale. Make sure you update the script according to how your system is set up.

  5. On the Payslip tab, we include the field used in the script to display how much was earned in the applicable payroll period.

  6. Define two Accumulators, one for Earned Leave Compensation and one for Paid Leave Compensation

  7. Go to the tab Accumulators and add in the field used in the script, in this sample L67, into the Earned Leave Compensation accumulator as defined in the previous step.

Script for Earned Leave Compensation

//X2 = Line 2 from the pay scale
//P431 = Number of days in the payroll period
L67=X2/P431*L22

This entry code is set to Pay out the earned leave amount in the payroll period the person signs off. It will fetch the amount from the Earned Leave Compensation Accumulator.

  1. Create the entry code with the number and name as wanted. Set the entry code with Allowance

  2. Turn on the option “Remove From Pay Slip When Calculatedamount1 =0”
    The entry code will be auto-generated every month even if the person is not signing off. The script will ensure that the amount is calculated to 0 when it is not the sign-off payroll period. The option ensures that the entry code is not displayed in Entries and on the Payslip unless there is an amount to be paid out.

  3. Link the entry code to the corresponding script
    Make sure the priority is set to higher than the Earned Leave Compensation as if not the Leave earned in the month of sign-off will not be included.

  4. Add the script
    In this sample, the monthly leave compensation is stored in line 2 in the pay scale. Make sure you update the script according to how your system is set up.

  5. On the Payslip tab, we include the field used in the script to pay out the amount, which is always L61.

  6. Go to the tab Accumulators and add in the field used in the script, in this sample L61, into the Paid Leave Compensation accumulator as defined in the previous steps.

     

Script for Paid Leave Compensation

//P604d = Payroll Period End Date
//L168e = Real sign off date regardless vessel. Meaning that a vessel transfer will not be considered a sign-off.
IF L168e<P604d OR L168e=P604d THEN
L61=W304
ENDIF