We have a requirement for our company.
Our Sales Employees have Basic salary which is based on TARGET of sales for which payments have been received.
Employee : A
Sales Target: 1,00,000
Basic Salary: 10,000
For Payroll We need to consider sales for the month where invoices are already paid.
Sale 1 Invoice value: 6000, PAID
Sales 2 Invoice Value: 10000, PAID
Sales 3 Invoice Value 20000, PAID
Sale 4 Invoice Value 4000, PAID
Sales 5 Invoice Value 60000, NOT PAID
In above scenario, the salary should be calculated as follows:
Total sales for which Invoices are paid: 6000+10000+20000+4000=40000
Sales target for Employee A is 1,00,000
Employee A has reached only 40% of target in the month,
Employee A Basic Salary = 40% of 10,000 = 4,000/-
We would appreciate if we can get a way to make Basic salary on basis of Sales Invoices Paid for the month in which the Sales person is the Employee whom we need to pay at the end of month.