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: Payment Terms Status for Sales Order report show all payment terms from orders (not only when there is a payment terms template) #39331

Conversation

FHenry
Copy link
Contributor

@FHenry FHenry commented Jan 11, 2024

Please provide enough information so that others can review your pull request:

The report Payment Terms Status for Sales Order display payment schedule only for orders with Payment Terms template
It should display all payment terms schedule for order even if the is no template but also manually entered payments terms

Explain the details for making this change. What existing problem does the pull request solve?

Actually the filter
(so.payment_terms_template != "NULL")
is not correct, at least it have to be
(so.payment_terms_template.notnull())
If you really want this filter

Actually will compare NULL as a string :
tabSales Order.payment_terms_template <> "NULL"
as it should be :
NOT tabSales Order.payment_terms_template IS NULL

But any way, there is no need to filter incoming amount from orders with payment terms template, just payment term is enough. The payment Terms template is not use else where in the report

no-doc
no-test

Note to reviewer, if this PR is accepted, could you please add github label backport to version-15 and version-14 ?

…ent terms from order not only this comming from template
@github-actions github-actions bot added the needs-tests This PR needs automated unit-tests. label Jan 11, 2024
@ruthra-kumar ruthra-kumar self-assigned this Jan 23, 2024
Copy link

codecov bot commented Jan 24, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (64cb115) 60.15% compared to head (735576a) 60.15%.
Report is 1 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop   #39331   +/-   ##
========================================
  Coverage    60.15%   60.15%           
========================================
  Files          757      757           
  Lines        70696    70696           
========================================
+ Hits         42525    42526    +1     
+ Misses       28171    28170    -1     
Files Coverage Δ
...ales_order/payment_terms_status_for_sales_order.py 80.99% <ø> (ø)

... and 1 file with indirect coverage changes

@ruthra-kumar ruthra-kumar merged commit 4f1e729 into frappe:develop Jan 24, 2024
14 checks passed
ruthra-kumar added a commit that referenced this pull request Jan 24, 2024
…-39331

fix: Payment Terms Status for Sales Order report show all payment terms from orders (not only when there is a payment terms template) (backport #39331)
ruthra-kumar added a commit that referenced this pull request Jan 24, 2024
…-39331

fix: Payment Terms Status for Sales Order report show all payment terms from orders (not only when there is a payment terms template) (backport #39331)
@FHenry FHenry deleted the dev_fix_payment_terms_status_for_sales_order_report branch January 24, 2024 20:56
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 8, 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 backport version-15-hotfix needs-tests This PR needs automated unit-tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants