-
Notifications
You must be signed in to change notification settings - Fork 7.9k
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
Use better description in pos_payment.js #42081
Use better description in pos_payment.js #42081
Conversation
Use Change Amount instead of Change and To Be Paid in pos_payment.js and be consistent with other strings
@@ -584,7 +584,7 @@ erpnext.PointOfSale.Payment = class { | |||
const remaining = grand_total - doc.paid_amount; | |||
const change = doc.change_amount || remaining <= 0 ? -1 * remaining : undefined; | |||
const currency = doc.currency; | |||
const label = change ? __("Change") : __("To Be Paid"); | |||
const label = change ? __("Change Amount") : __("Change Amount"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both the true and false branches of the ternary operator are the same.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes but logically thinking from sales person view it is right
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes but logically thinking from sales person view it is right
That's okay, I was talking about the way you fix it. It should be const label = __("Change Amount");
not const label = change ? __("Change Amount") : __("Change Amount");
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do new PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make the change in this PR only?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
This pull request has been automatically marked as inactive because it has not had recent activity. It will be closed within 3 days if no further activity occurs, but it only takes a comment to keep a contribution alive :) Also, even if it is closed, you can always reopen the PR when you're ready. Thank you for contributing. |
* Use better description in pos_payment.js Use Change Amount instead of Change and To Be Paid in pos_payment.js and be consistent with other strings * change_amount_pos_payment.js (cherry picked from commit 138ffc4)
* Use better description in pos_payment.js Use Change Amount instead of Change and To Be Paid in pos_payment.js and be consistent with other strings * change_amount_pos_payment.js (cherry picked from commit 138ffc4)
…-42081 Use better description in pos_payment.js (backport #42081)
…-42081 Use better description in pos_payment.js (backport #42081)
Use Change Amount instead of Change and To Be Paid in pos_payment.js and be consistent with other strings