ERPNext Foundation ERPNext Cloud User Manual Blog Discuss Frappé* Donate

Help Required in Preparation of salary component/salary structure

erpnext

#1

I am facing issue in preparation of salary for leave without pay i have tried all the things but still i m unable to create it,
I have applied lwp for a particular employee still when i m creating salary full month salary is being creating,
several time i have created salary structure is there issue with salary structure that i created Kindly help me to resolve this


or the issue is on salary structure


#2

I think “depends on payment days” is unchecked for salary components.

Go to salary components list and select a particular salary component> and then check/tick mark depends on payments days checkbox.

Hope this helps.


#3

I have done this but still facing same issue


#4

Did you try creating a Payroll Entry? If you are running the Preview Salary Slip option from Salary Slip, there was an issue with Preview last I tried it as well, but the Payroll entry or Salary Slip works well.


#5

@adil

Hi,

There are 2 aspects that you need to keep in mind for LWF, 1 is the attendance and 2 is leave application.

  1. Check whether you have updated the attendance of that employee. If he has been marked absent (let say for 2 days) then payment days considering June month would be 28 days (30 - 2). If you have checked “Depends on payment days”, then it will calculate salary as per payment days i.e. 28 days.

  2. In case of leave application, if a specific leave type is checked “Leave without pay” then an employee applying for that leave will not be paid and while generating salary slip those days (for which the leaves have been applied) will be marked as “LWF”. In other words, payment days would reduce and salary would be processed for only those days.

Hope this helps.

Regards,
Reema


#6

I have tried that too but in salary slip its showing LWP 11 days that i have applied but it is not calculating deductions accordingly


#7

I have updated attendance and applied LWP, it showing working days after LWP, or payment days but not calculating salary accordingly


her you can see that payment days are 20 but salary is calculating for full month
it should be 20days salary


#8

what is the exact salary assigned? Well I needed to show the actual leave without pay deduction so I created a separate component where I calculate salary of leaves so the earning part is complete salary and leave without pay are deducted from my component


#9

as i mentioned gross salary is 25k
she must get 20 days salary 16129
that is 25000/31*20


#10

Have you done any customisations?


#11

Maybe this feature is not available anymore in latest update? As there used to be an option of ‘depends on lwp’ but I always update my v11 and now there is no more such option. Maybe you have to create a separate deduction component for leave without pay.


#12

Screenshot%20from%202019-06-26%2011-24-26
I have made a filed of month days which have total days of month without weekends and additional holidays


#13

when used this formula it showing following error while creating Payroll entry


#14

where i supposed to define month days


#15

In my situation I needed month days but you can use working days or payment days. Actually when such situation arise that we have eid holidays so the working days are very less and hence the per day leave deduction is very high. So in my company the standard is that per day leave calculation will be based on only all the month days including holidays.
For that I updated salary slip and added a new field of month days and calculated the days of month through python library numpy.


#16

Hi,

So the option of “Depends on Lwp” is now “Depends on payment days”. It is just a terminology change.

Regards,
Reema


#17

I have been working our payroll successfully on a bimonthly or fortnightly basis, but had not used the attendance module and leave applications yet.

As we aim to switch our entire payroll procedure to ERPNext using salary slips that automatically track attendance and Leave Without Pay I have encountered some difficulty in calculating.

I understand that ERPNext begins with the calendar month, say June 2019 which has 30 days.

1. Working Days

It first calculates Working Days based on the Holiday List.
Let’s assume for our purposes that the Holiday list states that Sundays are non-working days, and this holiday list is properly configured in our employee doctype. This takes out the following Dates from June 2019: 2, 9, 16, 23, and 30. Total sundays = 5. Total holiday list-adjusted working days: 30 -5 = 25 Working Days. (Days of Month - Days listed as Holidays in Holiday List Assigned to Employees = Working Days)

2. Payment Days

If our example employee misses 2 working days, this means 25 - 2 = 23 Payment Days. (Working Days - Absences = Payment Days)

3. Payment Days Net of Days of Leave Without Payment

If our example employee also applies for a LWP of 3 days, not related to the 2 days employee was absent, the: 23 - 3 = 20 Payment Days ( Payment Days - Days of Leave Without Pay = Payment Days Net of Leave Without Pay Days)

Question

So far, so good. Now, the problem I have is the Payroll Frequency configuration in the Salary structure, must it be a Daily or can it be Fortnightly or Bimonthly? So far I have had no luck with Fortnightly.

EDIT

After some trial and error, I realized that when I was Amending a previous salary structure, it was not copying the formula to calculate the base, thus the error where it underestimated the salary to be paid. I erroneously thought it was a problem with the Payroll Frequency setting. However, I have confirmed that what ERPNext does is that it will calculate the formulas first and then will pro-rate or change the proportion of payment based on a formula where:

(amount of salary component per period / working days ) * payment days = amount of salary component for payment days.


#18

Hi,

Kindly find my reply below:

If Sunday is a weekly off and part of holiday list, then it will be paid and not minus from 30 days.

For this you will have to keep certain checks in mind:

  1. Before running the payroll, validate the attendance
  2. Check “Depends on payment days” in salary component

If this done then whatever payroll frequency you will select, it will keep in mind these 2 points. Like in your case payment days will be 30 - 2 (absent) - 3 (LWP) = 25 days, not deducting the 5 Sundays since they are paid.

Your right each salary component will be calculated like this.

Hope this helps.

Regards,
Reema


#19

Reema you are absolutely right. It is a paid day! This helped clarify my confusion about this topic a little more!


#20

Hi,

I am glad I could help, let me know if you need more clarification.

Regards,
Reema