Skip to content

fix: modify voucher type based on account type (backport #3842)#4249

Merged
iamkhanraheel merged 2 commits intoversion-15-hotfixfrom
mergify/bp/version-15-hotfix/pr-3842
Mar 20, 2026
Merged

fix: modify voucher type based on account type (backport #3842)#4249
iamkhanraheel merged 2 commits intoversion-15-hotfixfrom
mergify/bp/version-15-hotfix/pr-3842

Conversation

@mergify
Copy link
Copy Markdown
Contributor

@mergify mergify Bot commented Mar 19, 2026

Incorrect voucher_type assignment

Payroll Entry was always creating Journal Entries with voucher_type = "Bank Entry" even when the selected payment_account is a Cash account.
The updated logic checks the account_type of payment_account and sets the voucher_type accordingly (Bank Entry for bank accounts, Cash Entry for cash accounts).

backport version-15-hotfix
backport version-16-hotfix

Summary by CodeRabbit

  • Bug Fixes

    • Payroll now recognizes both bank and cash payment entries when linking transactions, ensuring payments are correctly associated.
    • Payment handling selects the appropriate entry type (bank vs. cash) dynamically based on the payment account’s configuration.
  • Tests

    • Test coverage updated to validate multi-method payment aggregation and selection logic.

This is an automatic backport of pull request #3842 done by [Mergify](https://mergify.com).

@mergify mergify Bot requested a review from ruchamahabal as a code owner March 19, 2026 22:13
@iamkhanraheel iamkhanraheel merged commit 7c59fcf into version-15-hotfix Mar 20, 2026
8 checks passed
@iamkhanraheel iamkhanraheel deleted the mergify/bp/version-15-hotfix/pr-3842 branch March 20, 2026 00:58
@frappe-pr-bot
Copy link
Copy Markdown
Collaborator

🎉 This PR is included in version 15.58.5 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants