Repository navigation
[pull] develop from frappe:develop - #446
Merged
Merged
Conversation
Salary Component's Accounts table gets a Liability Account field for Employer Contribution components: Account is debited as the expense (cost center wise) and Liability Account is credited, since employer contributions are payable to authorities and must not touch the Payroll Payable account. The JV is created after the salary accrual JV on payroll submission and carries a Payroll Entry reference on credit rows so cancelling the Payroll Entry cancels it as well.
When 'Process Payroll Accounting Entry based on Employee' is enabled in Payroll Settings, the employer contribution JV credits the liability account employee-wise with the employee set as party, mirroring the payable rows of the salary accrual JV. Expense debits stay aggregated cost center wise.
…r contribution JV Expense rows split by cost center percentage and the liability credit were rounded independently, so amounts like 0.01 split 50/50 produced unbalanced Journal Entries that failed submission. The last cost center now takes the rounding remainder so the expense splits always sum up to the amount credited against the liability.
Account lookups ran once per contribution row inside the loop; fetch the mappings for the distinct components upfront instead so payroll submission does not scale queries with salary slip rows.
feat: pass separate Journal Entry for employer contributions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )