Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: AP AR filters from Party link #37268

Merged
merged 7 commits into from
Sep 28, 2023

Conversation

GursheenK
Copy link
Member

@GursheenK GursheenK commented Sep 27, 2023

Problem

The AP & AR reports consist of the Party Type filter which is a Link field and Party filter which is a Dynamic Link field. However, the set_route function does not auto-populate the values for these field types even when the filter values are set in the parameters. So when a Supplier / Customer document is opened and the View Accounts Payable or View Accounts Receivable button is clicked, the report shows the entries for all suppliers / customers instead of the selected one.

Screen.Recording.2023-09-27.at.2.14.45.PM.mov

Solution

  • Made the Party Type filter an Autocomplete field and the Party filter a MultiSelectList field similar to the GL Report.
  • Since party types with a specific account type should be shown as options for the filter, added a method to show only certain party types.
  • Fixed the Process SOA method to now send a list to the multiselect filter instead of a single value.

Closes #37258

no-docs

@github-actions github-actions bot added the needs-tests This PR needs automated unit-tests. label Sep 27, 2023
@GursheenK GursheenK added the backport version-14-hotfix backport to version 14 label Sep 27, 2023
@codecov
Copy link

codecov bot commented Sep 27, 2023

Codecov Report

Merging #37268 (2c7d6ae) into develop (62ea097) will increase coverage by 0.01%.
Report is 47 commits behind head on develop.
The diff coverage is 100.00%.

@@             Coverage Diff             @@
##           develop   #37268      +/-   ##
===========================================
+ Coverage    66.69%   66.70%   +0.01%     
===========================================
  Files          794      794              
  Lines        62497    62541      +44     
===========================================
+ Hits         41681    41721      +40     
- Misses       20816    20820       +4     
Files Coverage Δ
...ement_of_accounts/process_statement_of_accounts.py 58.54% <ø> (ø)
.../report/accounts_receivable/accounts_receivable.py 90.56% <100.00%> (ø)
erpnext/projects/doctype/project/project.py 50.00% <100.00%> (ø)

... and 9 files with indirect coverage changes

@ruthra-kumar ruthra-kumar self-assigned this Sep 27, 2023
@ruthra-kumar ruthra-kumar merged commit f160e49 into frappe:develop Sep 28, 2023
13 checks passed
deepeshgarg007 added a commit that referenced this pull request Sep 28, 2023
…-37268

fix: AP AR filters from Party link (backport #37268)
@vishdha
Copy link
Contributor

vishdha commented Oct 23, 2023

@GursheenK Impress with multiselect with customer. it will be good if this feature enabled for customer group too

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 20, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport version-14-hotfix backport to version 14 needs-tests This PR needs automated unit-tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

I can't print or see Accounts Receivable per Customer
3 participants